Skip to content

Commit

Permalink
Mixer: remove KVO observer of selected application because it might d…
Browse files Browse the repository at this point in the history
…isappear after list reload.
  • Loading branch information
trunkmaster committed May 23, 2019
1 parent 65cf691 commit 9dc9411
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion Applications/Preferences/Modules/Sound/Mixer.m
Original file line number Diff line number Diff line change
Expand Up @@ -422,8 +422,13 @@ - (void)reloadAppBrowser
NSMatrix *matrix;
NSCell *cell;

// Stop tracking SNDStream because it may disappear after reload
if (selectedApp != nil) {
[self stopObserveStream:selectedApp];
selectedApp = nil;
}

[appBrowser reloadColumn:0];
[appBrowser setTitle:@"Streams" ofColumn:0];

matrix = [appBrowser matrixInColumn:0];
if ([matrix numberOfRows] > 0 && selected == nil) {
Expand All @@ -438,6 +443,7 @@ - (void)reloadAppBrowser
}
}
}

[self browserClick:appBrowser];
}

Expand Down

0 comments on commit 9dc9411

Please sign in to comment.