Skip to content
Snippets Groups Projects
Commit 185d8522 authored by Claudio Cambra's avatar Claudio Cambra Committed by Jean-Baptiste Kempf
Browse files

macosx: Tint images for activated shuffle and repeat to VLCAccentColor


Signed-off-by: default avatarClaudio Cambra <developer@claudiocambra.com>
parent 1d73e8f9
No related branches found
No related tags found
1 merge request!3665macosx: Colour all accented UI items consistently
Pipeline #342342 passed with stage
in 12 minutes and 21 seconds
......@@ -24,9 +24,10 @@
#import "VLCLibraryDataTypes.h"
#import "extensions/NSString+Helpers.h"
#import "extensions/NSFont+VLCAdditions.h"
#import "extensions/NSColor+VLCAdditions.h"
#import "extensions/NSImage+VLCAdditions.h"
#import "extensions/NSFont+VLCAdditions.h"
#import "extensions/NSString+Helpers.h"
#import "extensions/NSView+VLCAdditions.h"
#import "main/VLCMain.h"
......@@ -325,7 +326,7 @@ static void addShadow(NSImageView *__unsafe_unretained imageView)
if (_playlistController.playbackOrder == VLC_PLAYLIST_PLAYBACK_ORDER_NORMAL) {
self.shufflePlaylistButton.image = [NSImage imageNamed:@"shuffleOff"];
} else {
self.shufflePlaylistButton.image = [NSImage imageNamed:@"shuffleOn"];
self.shufflePlaylistButton.image = [[NSImage imageNamed:@"shuffleOn"] imageTintedWithColor:[NSColor VLCAccentColor]];
}
}
......@@ -351,10 +352,10 @@ static void addShadow(NSImageView *__unsafe_unretained imageView)
enum vlc_playlist_playback_repeat currentRepeatState = _playlistController.playbackRepeat;
switch (currentRepeatState) {
case VLC_PLAYLIST_PLAYBACK_REPEAT_ALL:
self.repeatPlaylistButton.image = [NSImage imageNamed:@"repeatAll"];
self.repeatPlaylistButton.image = [[NSImage imageNamed:@"repeatAll"] imageTintedWithColor:[NSColor VLCAccentColor]];
break;
case VLC_PLAYLIST_PLAYBACK_REPEAT_CURRENT:
self.repeatPlaylistButton.image = [NSImage imageNamed:@"repeatOne"];
self.repeatPlaylistButton.image = [[NSImage imageNamed:@"repeatOne"] imageTintedWithColor:[NSColor VLCAccentColor]];
break;
default:
......
......@@ -25,6 +25,7 @@
#import "VLCControlsBarCommon.h"
#import "extensions/NSColor+VLCAdditions.h"
#import "extensions/NSImage+VLCAdditions.h"
#import "extensions/NSString+Helpers.h"
#import "library/VLCInputItem.h"
......@@ -86,12 +87,12 @@
name:VLCPlaybackRepeatChanged
object:nil];
_repeatAllImage = [NSImage imageNamed:@"repeatAll"];
_repeatAllImage = [[NSImage imageNamed:@"repeatAll"] imageTintedWithColor:[NSColor VLCAccentColor]];
_repeatOffImage = [NSImage imageNamed:@"repeatOff"];
_repeatOneImage = [NSImage imageNamed:@"repeatOne"];
_repeatOneImage = [[NSImage imageNamed:@"repeatOne"] imageTintedWithColor:[NSColor VLCAccentColor]];
_shuffleOffImage = [NSImage imageNamed:@"shuffleOff"];
_shuffleOnImage = [NSImage imageNamed:@"shuffleOn"];
_shuffleOnImage = [[NSImage imageNamed:@"shuffleOn"] imageTintedWithColor:[NSColor VLCAccentColor]];
self.repeatButton.action = @selector(repeatAction:);
self.shuffleButton.action = @selector(shuffleAction:);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment