[vlc-commits] [Git][videolan/vlc][master] 2 commits: macosx: Add a border around the visual effect view for the library window controls bar
Jean-Baptiste Kempf (@jbk)
gitlab at videolan.org
Mon Dec 8 06:57:13 UTC 2025
Jean-Baptiste Kempf pushed to branch master at VideoLAN / VLC
Commits:
d64189d5 by Claudio Cambra at 2025-12-08T07:30:48+01:00
macosx: Add a border around the visual effect view for the library window controls bar
Signed-off-by: Claudio Cambra <developer at claudiocambra.com>
- - - - -
3c8a6495 by Claudio Cambra at 2025-12-08T07:30:48+01:00
macosx: Update separator colour in controls bar in dark/light switch
Signed-off-by: Claudio Cambra <developer at claudiocambra.com>
- - - - -
1 changed file:
- modules/gui/macosx/windows/controlsbar/VLCMainWindowControlsBar.m
Changes:
=====================================
modules/gui/macosx/windows/controlsbar/VLCMainWindowControlsBar.m
=====================================
@@ -81,6 +81,8 @@
self.visualEffectView.wantsLayer = YES;
self.visualEffectView.layer.cornerRadius = VLCLibraryUIUnits.cornerRadius;
self.visualEffectView.layer.masksToBounds = YES;
+ self.visualEffectView.layer.borderWidth = VLCLibraryUIUnits.borderThickness;
+ self.visualEffectView.layer.borderColor = NSColor.VLCSubtleBorderColor.CGColor;
}
_playQueueController = VLCMain.sharedInstance.playQueueController;
@@ -127,6 +129,29 @@
[self.trailingTimeField setAlignment: NSCenterTextAlignment];
[self.thumbnailTrackingView setViewToHide:_openMainVideoViewButtonOverlay];
+
+ if (@available(macOS 10.14, *)) {
+ [NSApplication.sharedApplication addObserver:self
+ forKeyPath:@"effectiveAppearance"
+ options:NSKeyValueObservingOptionNew
+ context:nil];
+ }
+}
+
+- (void)observeValueForKeyPath:(NSString *)keyPath
+ ofObject:(id)object
+ change:(NSDictionary<NSKeyValueChangeKey,id> *)change
+ context:(void *)context
+{
+ if (@available(macOS 26.0, *)) {
+ return;
+ } else if (@available(macOS 10.14, *)) {
+ NSAppearance * const appearance = change[NSKeyValueChangeNewKey];
+ const BOOL isDark = [appearance.name isEqualToString:NSAppearanceNameDarkAqua] ||
+ [appearance.name isEqualToString:NSAppearanceNameVibrantDark];
+ self.visualEffectView.layer.borderColor = isDark ?
+ NSColor.VLCDarkSubtleBorderColor.CGColor : NSColor.VLCLightSubtleBorderColor.CGColor;
+ }
}
#pragma mark -
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/54ab5bdc6d808fd1d1ef5f18f34d51d1e7459693...3c8a6495afea3e50e037fc8af456ebe57ccf82ad
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/54ab5bdc6d808fd1d1ef5f18f34d51d1e7459693...3c8a6495afea3e50e037fc8af456ebe57ccf82ad
You're receiving this email because of your account on code.videolan.org.
VideoLAN code repository instance
More information about the vlc-commits
mailing list