Changeset 846 for trunk/src/gui/widgets/qmainwindowlayout_mac.mm
- Timestamp:
- May 5, 2011, 5:36:53 AM (14 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:mergeinfo changed
/branches/vendor/nokia/qt/4.7.2 (added) merged: 845 /branches/vendor/nokia/qt/current merged: 844 /branches/vendor/nokia/qt/4.6.3 removed
- Property svn:mergeinfo changed
-
trunk/src/gui/widgets/qmainwindowlayout_mac.mm
r769 r846 1 1 /**************************************************************************** 2 2 ** 3 ** Copyright (C) 201 0Nokia Corporation and/or its subsidiary(-ies).3 ** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). 4 4 ** All rights reserved. 5 5 ** Contact: Nokia Corporation (qt-info@nokia.com) … … 49 49 #else 50 50 #include <private/qcocoatoolbardelegate_mac_p.h> 51 #import <private/qcocoawindowdelegate_mac_p.h> 51 52 #endif 52 53 … … 338 339 339 340 layoutState.mainWindow->setUpdatesEnabled(false); // reduces a little bit of flicker, not all though 341 #if defined(QT_MAC_USE_COCOA) 342 QMacCocoaAutoReleasePool pool; 343 NSView *cView = [qt_mac_window_for(layoutState.mainWindow) contentView]; 344 if (useMacToolbar) { 345 [cView setPostsFrameChangedNotifications:YES]; 346 [[NSNotificationCenter defaultCenter] addObserver: [QT_MANGLE_NAMESPACE(QCocoaWindowDelegate) sharedDelegate] 347 selector: @selector(syncContentViewFrame:) 348 name: NSViewFrameDidChangeNotification 349 object: cView]; 350 } 351 #endif 340 352 if (!useMacToolbar) { 341 353 macWindowToolbarShow(layoutState.mainWindow, false); … … 357 369 syncUnifiedToolbarVisibility(); 358 370 } 371 #if defined(QT_MAC_USE_COCOA) 372 if (!useMacToolbar) { 373 [cView setPostsFrameChangedNotifications:NO]; 374 [[NSNotificationCenter defaultCenter] removeObserver: [QT_MANGLE_NAMESPACE(QCocoaWindowDelegate) sharedDelegate] 375 name: NSViewFrameDidChangeNotification 376 object: cView]; 377 } 378 #endif 359 379 layoutState.mainWindow->setUpdatesEnabled(true); 360 380 } … … 411 431 [macToolbar setDisplayMode:NSToolbarDisplayModeIconOnly]; 412 432 [macToolbar setSizeMode:NSToolbarSizeModeRegular]; 413 [macToolbar setDelegate:[[Q CocoaToolBarDelegatealloc] initWithMainWindowLayout:this]];433 [macToolbar setDelegate:[[QT_MANGLE_NAMESPACE(QCocoaToolBarDelegate) alloc] initWithMainWindowLayout:this]]; 414 434 [window setToolbar:macToolbar]; 415 435 [macToolbar release];
Note:
See TracChangeset
for help on using the changeset viewer.