Changeset 846 for trunk/src/gui/widgets/qdialogbuttonbox.cpp
- 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/qdialogbuttonbox.cpp
r769 r846 1 1 /**************************************************************************** 2 2 ** 3 ** Copyright (C) 201 0Nokia Corporation and/or its subsidiary(-ies).3 ** Copyright (C) 201 Nokia Corporation and/or its subsidiary(-ies). 4 4 ** All rights reserved. 5 5 ** Contact: Nokia Corporation ([email protected]) … … 104 104 105 105 Currently the buttons are laid out in the following way if the button box is horizontal: 106 \table 100%106 \table 107 107 \row \o \inlineimage buttonbox-gnomelayout-horizontal.png GnomeLayout Horizontal 108 108 \o Button box laid out in horizontal GnomeLayout … … 117 117 The buttons are laid out the following way if the button box is vertical: 118 118 119 \table 100% 119 \table 120 \row \o GnomeLayout 121 \o KdeLayout 122 \o MacLayout 123 \o WinLayout 120 124 \row \o \inlineimage buttonbox-gnomelayout-vertical.png GnomeLayout Vertical 121 \o Button box laid out in vertical GnomeLayout 122 \row \o \inlineimage buttonbox-kdelayout-vertical.png KdeLayout Vertical 123 \o Button box laid out in vertical KdeLayout 124 \row \o \inlineimage buttonbox-maclayout-vertical.png MacLayout Vertical 125 \o Button box laid out in vertical MacLayout 126 \row \o \inlineimage buttonbox-winlayout-vertical.png WinLayout Vertical 127 \o Button box laid out in vertical WinLayout 125 \o \inlineimage buttonbox-kdelayout-vertical.png KdeLayout Vertical 126 \o \inlineimage buttonbox-maclayout-vertical.png MacLayout Vertical 127 \o \inlineimage buttonbox-winlayout-vertical.png WinLayout Vertical 128 128 \endtable 129 129 130 130 Additionally, button boxes that contain only buttons with ActionRole or 131 HelpRole can be considered modeless and have an alternate look on the mac: 132 133 \table 100% 134 \row \o \inlineimage buttonbox-mac-modeless-horizontal.png Screenshot of modeless horizontal MacLayout 135 \o modeless horizontal MacLayout 136 \row \o \inlineimage buttonbox-mac-modeless-vertical.png Screenshot of modeless vertical MacLayout 137 \o modeless vertical MacLayout 131 HelpRole can be considered modeless and have an alternate look on Mac OS X: 132 133 \table 134 \row \o modeless horizontal MacLayout 135 \o \inlineimage buttonbox-mac-modeless-horizontal.png Screenshot of modeless horizontal MacLayout 138 136 \endtable 139 137 … … 261 259 }; 262 260 261 263 262 class QDialogButtonEnabledProxy : public QObject 264 263 { … … 284 283 QAction *target; 285 284 }; 286 285 #endif 287 286 288 287 class QDialogButtonBoxPrivate : public QWidgetPrivate … … 317 316 void retranslateStrings(); 318 317 const char *standardButtonText(QDialogButtonBox::StandardButton sbutton) const; 319 #if def QT_SOFTKEYS_ENABLED318 #if 320 319 QAction *createSoftKey(QAbstractButton *button, QDialogButtonBox::ButtonRole role); 321 320 #endif … … 574 573 QObject::connect(button, SIGNAL(destroyed()), q, SLOT(_q_handleButtonDestroyed())); 575 574 buttonLists[role].append(button); 576 #if def QT_SOFTKEYS_ENABLED575 #if 577 576 QAction *action = createSoftKey(button, role); 578 577 softKeyActions.insert(button, action); … … 583 582 } 584 583 585 #if def QT_SOFTKEYS_ENABLED584 #if 586 585 QAction* QDialogButtonBoxPrivate::createSoftKey(QAbstractButton *button, QDialogButtonBox::ButtonRole role) 587 586 { … … 721 720 QPushButton *button = it.key(); 722 721 button->setText(QDialogButtonBox::tr(buttonText)); 723 #if def QT_SOFTKEYS_ENABLED722 #if 724 723 QAction *action = softKeyActions.value(button, 0); 725 724 if (action) … … 1000 999 } 1001 1000 } 1002 #if def QT_SOFTKEYS_ENABLED1001 #if 1003 1002 QAction *action = d->softKeyActions.value(button, 0); 1004 1003 if (action) { … … 1246 1245 d->retranslateStrings(); 1247 1246 } 1248 #if def QT_SOFTKEYS_ENABLED1247 #if 1249 1248 else if (event->type() == QEvent::ParentChange) { 1250 1249 QWidget *dialog = 0;
Note:
See TracChangeset
for help on using the changeset viewer.