Cocoa integration - suppress excessive dragginUpdated messages
Our abstract item views are using a timer before starting autoscroll. Constant dragginUpdated (re)starts this timer again and again and it actually never times out (== no autoscroll). It looks like a bug in Cocoa since 10.11, they test: respondsToSelector:@selector(wantsPeriodicDraggingUpdated:) with ':' at the end, though they need a method without parameters; as a result QTBUG-32761 was re-introduced. Let's make them happy and respond to this selector also (never gets called actually). Change-Id: I3b7bb0a455124f84c97fc350f69486bf0fc5d5fc Task-number: QTBUG-32761 Reviewed-by: Jake Petroules <jake.petroules@theqtcompany.com>
This commit is contained in:
parent
94f5ed11a1
commit
22d075fef0
@ -1898,6 +1898,18 @@ static QPoint mapWindowCoordinates(QWindow *source, QWindow *target, QPoint poin
|
||||
return NO;
|
||||
}
|
||||
|
||||
|
||||
- (BOOL)wantsPeriodicDraggingUpdates:(void *)dummy
|
||||
{
|
||||
// This method never gets called. It's a workaround for Apple's
|
||||
// bug: they first respondsToSelector : @selector(wantsPeriodicDraggingUpdates:)
|
||||
// (note ':') and then call -wantsPeriodicDraggingUpdate (without colon).
|
||||
// So, let's make them happy.
|
||||
Q_UNUSED(dummy);
|
||||
|
||||
return NO;
|
||||
}
|
||||
|
||||
- (void)updateCursorFromDragResponse:(QPlatformDragQtResponse)response drag:(QCocoaDrag *)drag
|
||||
{
|
||||
const QPixmap pixmapCursor = drag->currentDrag()->dragCursor(response.acceptedAction());
|
||||
|
Loading…
x
Reference in New Issue
Block a user