summaryrefslogtreecommitdiffstats
path: root/macosx/HBController.m
diff options
context:
space:
mode:
authorDamiano Galassi <[email protected]>2019-08-12 19:31:04 +0200
committerDamiano Galassi <[email protected]>2019-08-12 19:31:04 +0200
commitd5cfa90ad9ac1f822ee2a7bf27416ca2ec44ff65 (patch)
tree1db4c5c6731ed7ed62505feaaae412fac298f60b /macosx/HBController.m
parent07283807608eb4af4385d3a02adf3c30be313d9e (diff)
MacGui: fix some UI syncronization issues caused by moving things to another process.
Diffstat (limited to 'macosx/HBController.m')
-rw-r--r--macosx/HBController.m9
1 files changed, 5 insertions, 4 deletions
diff --git a/macosx/HBController.m b/macosx/HBController.m
index 6fed7ebd9..dab3d55db 100644
--- a/macosx/HBController.m
+++ b/macosx/HBController.m
@@ -278,10 +278,6 @@ static void *HBControllerScanCoreContext = &HBControllerScanCoreContext;
options:NSKeyValueObservingOptionNew | NSKeyValueObservingOptionInitial
context:HBControllerScanCoreContext];
- [NSNotificationCenter.defaultCenter addObserverForName:HBQueueDidChangeStateNotification object:_queue queue:NSOperationQueue.mainQueue usingBlock:^(NSNotification * _Nonnull note) {
- [self updateQueueUI];
- }];
-
[NSNotificationCenter.defaultCenter addObserverForName:HBQueueDidStartNotification object:_queue queue:NSOperationQueue.mainQueue usingBlock:^(NSNotification * _Nonnull note) {
self.bottomConstrain.animator.constant = 0;
self->fRipIndicator.hidden = NO;
@@ -314,6 +310,11 @@ static void *HBControllerScanCoreContext = &HBControllerScanCoreContext;
}
}];
+ [NSNotificationCenter.defaultCenter addObserverForName:HBQueueDidChangeStateNotification object:_queue queue:NSOperationQueue.mainQueue usingBlock:^(NSNotification * _Nonnull note) {
+ [self updateQueueUI];
+ }];
+ [self updateQueueUI];
+
self.presetsMenuBuilder = [[HBPresetsMenuBuilder alloc] initWithMenu:self.presetsPopup.menu
action:@selector(selectPresetFromMenu:)
size:[NSFont smallSystemFontSize]