mirror of
https://github.com/joeblau/COSTouchVisualizer.git
synced 2024-09-11 12:36:58 +03:00
Merge pull request #9 from ReneLindhorst/master
Flag to disable the morphing of a stationary view spot
This commit is contained in:
commit
e4bd488add
2
Classes/COSTouchVisualizerWindow.h
Normal file → Executable file
2
Classes/COSTouchVisualizerWindow.h
Normal file → Executable file
@ -23,4 +23,6 @@
|
||||
@property (nonatomic, strong) UIColor *rippleStrokeColor;
|
||||
@property (nonatomic, strong) UIColor *rippleFillColor;
|
||||
|
||||
@property (nonatomic) BOOL stationaryMorphEnabled; // default: YES
|
||||
|
||||
@end
|
||||
|
8
Classes/COSTouchVisualizerWindow.m
Normal file → Executable file
8
Classes/COSTouchVisualizerWindow.m
Normal file → Executable file
@ -93,7 +93,9 @@
|
||||
|
||||
self.rippleAlpha = 0.2;
|
||||
self.rippleFadeDuration = 0.2;
|
||||
|
||||
|
||||
self.stationaryMorphEnabled = YES;
|
||||
|
||||
[[NSNotificationCenter defaultCenter] addObserver:self
|
||||
selector:@selector(screenConnect:)
|
||||
name:UIScreenDidConnectNotification
|
||||
@ -239,7 +241,9 @@
|
||||
touchView = [[COSTouchSpotView alloc] initWithImage:self.touchImage];
|
||||
[self.overlayWindow.rootViewController.view addSubview:touchView];
|
||||
|
||||
self.timer = [NSTimer scheduledTimerWithTimeInterval:0.6 target:self selector:@selector(performMorph:) userInfo:touchView repeats:YES];
|
||||
if (self.stationaryMorphEnabled) {
|
||||
self.timer = [NSTimer scheduledTimerWithTimeInterval:0.6 target:self selector:@selector(performMorph:) userInfo:touchView repeats:YES];
|
||||
}
|
||||
}
|
||||
|
||||
if (![touchView isFadingOut]) {
|
||||
|
Loading…
Reference in New Issue
Block a user