Permalink
Browse files

Added background transparency live update when using QC

  • Loading branch information...
1 parent bbc5e15 commit 7cf4294ff23839bfc77c12a3da736ecf65df84cf @ddlsmurf ddlsmurf committed Dec 7, 2010
Showing with 9 additions and 0 deletions.
  1. +9 −0 src/Visor.m
View
@@ -651,6 +651,7 @@ - (id) init {
[udc addObserver:self forKeyPath:@"values.VisorPosition" options:0 context:nil];
[udc addObserver:self forKeyPath:@"values.VisorHideOnEscape" options:0 context:nil];
[udc addObserver:self forKeyPath:@"values.VisorUseBackgroundAnimation" options:0 context:nil];
+ [[[self class] getVisorProfile] addObserver:self forKeyPath:@"BackgroundColor" options:0 context:@"Update bkg"];
if ([ud boolForKey:@"VisorUseBackgroundAnimation"]) {
[self background];
@@ -1216,6 +1217,14 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N
if ([keyPath isEqualToString:@"values.VisorUseBackgroundAnimation"]) {
[self updateBackgroundFrame];
}
+ if (background != nil &&
+ !isHidden &&
+ [keyPath isEqualToString:@"BackgroundColor"] &&
+ context != nil &&
+ [context isEqualToString:@"Update bkg"]) {
+ float bkgAlpha = [self getVisorProfileBackgroundAlpha];
+ [background setAlphaValue:bkgAlpha];
+ }
}
- (void)updateHotKeyRegistration {

0 comments on commit 7cf4294

Please sign in to comment.