/* ActiveGS, Copyright 2004-2016 Olivier Goguel, https://github.com/ogoguel/ActiveGS Based on Kegs, Copyright 2004 Kent Dickey, https://kegs.sourceforge.net This code is covered by the GNU GPL licence */ #import #import "emulatorView.h" struct orientationVar { float scale; CGPoint p; } ; typedef struct orientationVar orientationVar; @interface zoomEmulatorView : UIScrollView { float dpiRatio; CGSize viewSize; CGPoint initialPoint; double initialTimer; int mouseDown; int zoomDisabled; orientationVar orientationVars[4]; float kbdScale; UIPanGestureRecognizer* panGR; UIPinchGestureRecognizer* pinchGR; CGPoint lastMousePos; BOOL allowInput; BOOL startNewPhase; @public UIImageView* _crt ; emulatorView * _ew ; UITouch* _useTouch; UITouch* _secondTouch; int curOrientation; } @property (retain,nonatomic) emulatorView* ew ; @property (retain,nonatomic) UIImageView* crt ; @property (retain,nonatomic) UITouch* useTouch ; @property (retain,nonatomic) UITouch* secondTouch ; -(void)updateFrame:(CGRect)frame kbdRect:(CGRect)kbdRect; -(void)updateScreen:(CGRect)frame ratio:(float)ratio; - (void)switchOrientation:(int)orientation; -(void)disableZoom; -(void)enableZoom; -(void)enableInput; -(void)disableInput; -(void)mouseUp; -(void)mouseDown; -(void)setRatioToOne; -(CGPoint)rotateTouch:(UITouch*) _touch; - (id)initWithFrame:(CGRect)frame ratio:(float)ratio; @end