Skip to content

Commit 9524aea

Browse files
Simone ManganelliSimone Manganelli
Simone Manganelli
authored and
Simone Manganelli
committed
gear image now is always drawn, unless the 'drawGearImageOnlyOnMouseOver' key is set to YES in com.github.rentzsch.clicktoflash.plist
1 parent 8463078 commit 9524aea

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

Plugin/Plugin.m

+7-2
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ of this software and associated documentation files (the "Software"), to deal
4747
static NSString *sAutoLoadInvisibleFlashViewsKey = @"autoLoadInvisibleViews";
4848
static NSString *sPluginEnabled = @"pluginEnabled";
4949
static NSString *sApplicationWhitelist = @"applicationWhitelist";
50+
static NSString *sDrawGearImageOnlyOnMouseOverHiddenPref = @"drawGearImageOnlyOnMouseOver";
5051

5152
BOOL usingMATrackingArea = NO;
5253

@@ -869,8 +870,12 @@ - (void) _drawBackground
869870
[ self _drawBadgeWithPressed: mouseIsDown && mouseInside ];
870871

871872
// Draw the gear icon
872-
if( mouseInside && !mouseIsDown )
873-
[ self _drawGearIcon ];
873+
if ([[CTFUserDefaultsController standardUserDefaults] boolForKey:sDrawGearImageOnlyOnMouseOverHiddenPref]) {
874+
if( mouseInside && !mouseIsDown )
875+
[ self _drawGearIcon ];
876+
} else {
877+
[ self _drawGearIcon ];
878+
}
874879
}
875880

876881
- (void) _addTrackingAreaForCTF

0 commit comments

Comments
 (0)