Commit 5d011500 authored by Felix Paul Kühne's avatar Felix Paul Kühne

* forward-port [17501] and [17500]

parent 3d27df46
...@@ -178,24 +178,18 @@ ...@@ -178,24 +178,18 @@
/* three little ugly helpers */ /* three little ugly helpers */
- (void)repeatOne - (void)repeatOne
{ {
[o_btn_repeat setImage: [[NSImage alloc] initWithContentsOfFile: [o_btn_repeat setImage: [NSImage imageNamed:@"repeat_single_embedded_blue"]];
[[NSBundle mainBundle] pathForImageResource:@"repeat_single_embedded_blue.png"]]]; [o_btn_repeat setAlternateImage: [NSImage imageNamed:@"repeat_embedded_blue"]];
[o_btn_repeat setAlternateImage: [[NSImage alloc] initWithContentsOfFile:
[[NSBundle mainBundle] pathForImageResource:@"repeat_embedded_blue.png"]]];
} }
- (void)repeatAll - (void)repeatAll
{ {
[o_btn_repeat setImage: [[NSImage alloc] initWithContentsOfFile: [o_btn_repeat setImage: [NSImage imageNamed:@"repeat_embedded_blue"]];
[[NSBundle mainBundle] pathForImageResource:@"repeat_embedded_blue.png"]]]; [o_btn_repeat setAlternateImage: [NSImage imageNamed:@"repeat_embedded"]];
[o_btn_repeat setAlternateImage: [[NSImage alloc] initWithContentsOfFile:
[[NSBundle mainBundle] pathForImageResource:@"repeat_embedded.png"]]];
} }
- (void)repeatOff - (void)repeatOff
{ {
[o_btn_repeat setImage: [[NSImage alloc] initWithContentsOfFile: [o_btn_repeat setImage: [NSImage imageNamed:@"repeat_embedded"]];
[[NSBundle mainBundle] pathForImageResource:@"repeat_embedded.png"]]]; [o_btn_repeat setAlternateImage: [NSImage imageNamed:@"repeat_single_embedded_blue"]];
[o_btn_repeat setAlternateImage: [[NSImage alloc] initWithContentsOfFile:
[[NSBundle mainBundle] pathForImageResource:@"repeat_single_embedded_blue.png"]]];
} }
- (void)shuffle - (void)shuffle
{ {
...@@ -215,9 +209,6 @@ ...@@ -215,9 +209,6 @@
var_Get( p_playlist, "repeat", &repeating ); var_Get( p_playlist, "repeat", &repeating );
var_Get( p_playlist, "loop", &looping ); var_Get( p_playlist, "loop", &looping );
[[o_btn_repeat image] release];
[[o_btn_repeat alternateImage] release];
if( !repeating.b_bool && !looping.b_bool ) if( !repeating.b_bool && !looping.b_bool )
{ {
/* was: no repeating at all, switching to Repeat One */ /* was: no repeating at all, switching to Repeat One */
......
...@@ -48,7 +48,6 @@ ...@@ -48,7 +48,6 @@
- (void)focus:(NSTimer *)timer; - (void)focus:(NSTimer *)timer;
- (void)unfocus:(NSTimer *)timer; - (void)unfocus:(NSTimer *)timer;
- (void)mouseEntered:(NSEvent *)theEvent;
- (void)mouseExited:(NSEvent *)theEvent; - (void)mouseExited:(NSEvent *)theEvent;
- (void)fadeIn; - (void)fadeIn;
......
...@@ -181,7 +181,7 @@ ...@@ -181,7 +181,7 @@
- (void)fadeOut - (void)fadeOut
{ {
if( ( [self alphaValue] > 0.0 ) && !NSPointInRect( [NSEvent mouseLocation], [self frame] ) ) if( ( [self alphaValue] > 0.0 ) )
{ {
if (![self fadeTimer]) if (![self fadeTimer])
[self setFadeTimer:[NSTimer scheduledTimerWithTimeInterval:0.1 target:self selector:@selector(unfocus:) userInfo:[NSNumber numberWithShort:0] repeats:YES]]; [self setFadeTimer:[NSTimer scheduledTimerWithTimeInterval:0.1 target:self selector:@selector(unfocus:) userInfo:[NSNumber numberWithShort:0] repeats:YES]];
...@@ -369,7 +369,6 @@ ...@@ -369,7 +369,6 @@
- (void)setPlay - (void)setPlay
{ {
NSBundle *bundle = [NSBundle mainBundle];
NSImage *image; NSImage *image;
image = [NSImage imageNamed:@"fs_play"]; image = [NSImage imageNamed:@"fs_play"];
[o_play setImage:image]; [o_play setImage:image];
...@@ -379,7 +378,6 @@ ...@@ -379,7 +378,6 @@
- (void)setPause - (void)setPause
{ {
NSBundle *bundle = [NSBundle mainBundle];
NSImage *image; NSImage *image;
image = [NSImage imageNamed:@"fs_pause"]; image = [NSImage imageNamed:@"fs_pause"];
[o_play setImage:image]; [o_play setImage:image];
...@@ -481,7 +479,6 @@ ...@@ -481,7 +479,6 @@
@implementation VLCFSTimeSlider @implementation VLCFSTimeSlider
- (void)drawKnobInRect:(NSRect)knobRect - (void)drawKnobInRect:(NSRect)knobRect
{ {
NSBundle *bundle = [NSBundle mainBundle];
NSRect image_rect; NSRect image_rect;
NSImage *img = [NSImage imageNamed:@"fs_time_slider_knob_highlight"]; NSImage *img = [NSImage imageNamed:@"fs_time_slider_knob_highlight"];
image_rect.size = [img size]; image_rect.size = [img size];
...@@ -515,7 +512,6 @@ ...@@ -515,7 +512,6 @@
@implementation VLCFSVolumeSlider @implementation VLCFSVolumeSlider
- (void)drawKnobInRect:(NSRect) knobRect - (void)drawKnobInRect:(NSRect) knobRect
{ {
NSBundle *bundle = [NSBundle mainBundle];
NSRect image_rect; NSRect image_rect;
NSImage *img = [NSImage imageNamed:@"fs_volume_slider_knob"]; NSImage *img = [NSImage imageNamed:@"fs_volume_slider_knob"];
image_rect.size = [img size]; image_rect.size = [img size];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment