macOS: Update core surface size when config changes

pull/9525/head
Daniel Wennberg 2025-11-08 23:12:34 -08:00
parent 2592b96f6d
commit e3ff49e653
1 changed files with 7 additions and 1 deletions

View File

@ -129,7 +129,7 @@ class SurfaceScrollView: NSView {
surfaceView.$derivedConfig surfaceView.$derivedConfig
.sink { [weak self] _ in .sink { [weak self] _ in
DispatchQueue.main.async { [weak self] in DispatchQueue.main.async { [weak self] in
self?.synchronizeAppearance() self?.handleConfigChange()
} }
} }
.store(in: &cancellables) .store(in: &cancellables)
@ -232,6 +232,12 @@ class SurfaceScrollView: NSView {
private func handleScrollerStyleChange() { private func handleScrollerStyleChange() {
synchronizeCoreSurface() synchronizeCoreSurface()
} }
/// Handles config changes
private func handleConfigChange() {
synchronizeAppearance()
synchronizeCoreSurface()
}
/// Handles live scroll events (user actively dragging the scrollbar). /// Handles live scroll events (user actively dragging the scrollbar).
/// ///