mirror of
https://github.com/transmission/transmission
synced 2024-12-26 17:47:37 +00:00
#6050: Get rid of calls to deprecated convertScreenToBase: API (patch by mattrajca)
This commit is contained in:
parent
bfbf81cea1
commit
52ca481033
4 changed files with 4 additions and 4 deletions
|
@ -149,7 +149,7 @@
|
|||
NSRect realRect = [self rectForTitleWithString: titleString inBounds: cellFrame];
|
||||
|
||||
if ([titleString size].width > NSWidth(realRect)
|
||||
&& NSMouseInRect([view convertPoint: [[view window] convertScreenToBase: [NSEvent mouseLocation]] fromView: nil], realRect, [view isFlipped]))
|
||||
&& NSMouseInRect([view convertPoint: [[view window] mouseLocationOutsideOfEventStream] fromView: nil], realRect, [view isFlipped]))
|
||||
{
|
||||
realRect.size.width = [titleString size].width;
|
||||
return NSInsetRect(realRect, -PADDING_EXPANSION_FRAME, -PADDING_EXPANSION_FRAME);
|
||||
|
|
|
@ -96,7 +96,7 @@
|
|||
if (visibleRows.length == 0)
|
||||
return;
|
||||
|
||||
NSPoint mouseLocation = [self convertPoint: [[self window] convertScreenToBase: [NSEvent mouseLocation]] fromView: nil];
|
||||
NSPoint mouseLocation = [self convertPoint: [[self window] mouseLocationOutsideOfEventStream] fromView: nil];
|
||||
|
||||
for (NSInteger row = visibleRows.location, col = [self columnWithIdentifier: @"Priority"]; row < NSMaxRange(visibleRows); row++)
|
||||
{
|
||||
|
|
|
@ -525,7 +525,7 @@
|
|||
NSAssert([titleString size].width >= NSWidth(realRect), @"Full rect width should not be less than the used title rect width!");
|
||||
|
||||
if ([titleString size].width > NSWidth(realRect)
|
||||
&& NSMouseInRect([view convertPoint: [[view window] convertScreenToBase: [NSEvent mouseLocation]] fromView: nil], realRect, [view isFlipped]))
|
||||
&& NSMouseInRect([view convertPoint: [[view window] mouseLocationOutsideOfEventStream] fromView: nil], realRect, [view isFlipped]))
|
||||
{
|
||||
realRect.size.width = [titleString size].width;
|
||||
return NSInsetRect(realRect, -PADDING_EXPANSION_FRAME, -PADDING_EXPANSION_FRAME);
|
||||
|
|
|
@ -234,7 +234,7 @@
|
|||
if (rows.length == 0)
|
||||
return;
|
||||
|
||||
NSPoint mouseLocation = [self convertPoint: [[self window] convertScreenToBase: [NSEvent mouseLocation]] fromView: nil];
|
||||
NSPoint mouseLocation = [self convertPoint: [[self window] mouseLocationOutsideOfEventStream] fromView: nil];
|
||||
for (NSUInteger row = rows.location; row < NSMaxRange(rows); row++)
|
||||
{
|
||||
if (![[self itemAtRow: row] isKindOfClass: [Torrent class]])
|
||||
|
|
Loading…
Reference in a new issue