~ubuntu-branches/ubuntu/wily/mpv/wily

« back to all changes in this revision

Viewing changes to video/out/cocoa/events_view.m

  • Committer: Package Import Robot
  • Author(s): Artur Rona
  • Date: 2015-02-08 11:38:05 UTC
  • mfrom: (28.1.4 vivid-proposed)
  • Revision ID: package-import@ubuntu.com-20150208113805-hb7kk68170y002es
Tags: 0.7.3-1ubuntu1
* Merge from Debian unstable.  Remaining changes:
  - debian/rules:
    + Disable altivec on ppc64el again, as it FTBFS with it.

Show diffs side-by-side

added added

removed removed

Lines of Context:
25
25
#include "events_view.h"
26
26
 
27
27
@interface MpvEventsView()
 
28
@property(nonatomic, assign) BOOL clearing;
28
29
@property(nonatomic, assign) BOOL hasMouseDown;
29
30
@property(nonatomic, retain) NSTrackingArea *tracker;
30
31
- (void)signalMousePosition;
36
37
@end
37
38
 
38
39
@implementation MpvEventsView
 
40
@synthesize clearing = _clearing;
39
41
@synthesize adapter = _adapter;
40
42
@synthesize tracker = _tracker;
41
43
@synthesize hasMouseDown = _mouse_down;
90
92
    }
91
93
}
92
94
 
 
95
- (void)clear
 
96
{
 
97
    if ([self isInFullScreenMode]) {
 
98
        self.clearing = YES;
 
99
        [self exitFullScreenModeWithOptions:nil];
 
100
    }
 
101
}
 
102
 
93
103
// mpv uses flipped coordinates, because X11 uses those. So let's just use them
94
104
// as well without having to do any coordinate conversion of mouse positions.
95
105
- (BOOL)isFlipped { return YES; }
177
187
- (void)setFrameSize:(NSSize)size
178
188
{
179
189
    [super setFrameSize:size];
 
190
 
 
191
    if (self.clearing)
 
192
        return;
 
193
 
180
194
    [self signalMousePosition];
181
195
}
182
196