diff options
Diffstat (limited to 'src/gui/dialogs')
63 files changed, 134 insertions, 100 deletions
diff --git a/src/gui/dialogs/qabstractpagesetupdialog.cpp b/src/gui/dialogs/qabstractpagesetupdialog.cpp index 2f44b41..080ddea 100644 --- a/src/gui/dialogs/qabstractpagesetupdialog.cpp +++ b/src/gui/dialogs/qabstractpagesetupdialog.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qabstractpagesetupdialog.h b/src/gui/dialogs/qabstractpagesetupdialog.h index 406a32c..ac3ffa5 100644 --- a/src/gui/dialogs/qabstractpagesetupdialog.h +++ b/src/gui/dialogs/qabstractpagesetupdialog.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qabstractpagesetupdialog_p.h b/src/gui/dialogs/qabstractpagesetupdialog_p.h index e6e0121..3dbfdd5 100644 --- a/src/gui/dialogs/qabstractpagesetupdialog_p.h +++ b/src/gui/dialogs/qabstractpagesetupdialog_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qabstractprintdialog.cpp b/src/gui/dialogs/qabstractprintdialog.cpp index 641419f..3317018 100644 --- a/src/gui/dialogs/qabstractprintdialog.cpp +++ b/src/gui/dialogs/qabstractprintdialog.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qabstractprintdialog.h b/src/gui/dialogs/qabstractprintdialog.h index 82e3df8..02e7b0e 100644 --- a/src/gui/dialogs/qabstractprintdialog.h +++ b/src/gui/dialogs/qabstractprintdialog.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qabstractprintdialog_p.h b/src/gui/dialogs/qabstractprintdialog_p.h index 5ed35df..4de34a2 100644 --- a/src/gui/dialogs/qabstractprintdialog_p.h +++ b/src/gui/dialogs/qabstractprintdialog_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qcolordialog.cpp b/src/gui/dialogs/qcolordialog.cpp index a66a979..94a54fe 100644 --- a/src/gui/dialogs/qcolordialog.cpp +++ b/src/gui/dialogs/qcolordialog.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qcolordialog.h b/src/gui/dialogs/qcolordialog.h index 0803506..80a893d 100644 --- a/src/gui/dialogs/qcolordialog.h +++ b/src/gui/dialogs/qcolordialog.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qcolordialog_mac.mm b/src/gui/dialogs/qcolordialog_mac.mm index 82cfa24..a9c70d3 100644 --- a/src/gui/dialogs/qcolordialog_mac.mm +++ b/src/gui/dialogs/qcolordialog_mac.mm @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qcolordialog_p.h b/src/gui/dialogs/qcolordialog_p.h index 4bae898..243e727 100644 --- a/src/gui/dialogs/qcolordialog_p.h +++ b/src/gui/dialogs/qcolordialog_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qcolordialog_symbian.cpp b/src/gui/dialogs/qcolordialog_symbian.cpp index 8f73f7c..3dbb5c1 100644 --- a/src/gui/dialogs/qcolordialog_symbian.cpp +++ b/src/gui/dialogs/qcolordialog_symbian.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qdialog.cpp b/src/gui/dialogs/qdialog.cpp index 16ea045..e44c38c 100644 --- a/src/gui/dialogs/qdialog.cpp +++ b/src/gui/dialogs/qdialog.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** @@ -899,9 +899,21 @@ bool QDialog::symbianAdjustedPosition() { #if defined(Q_WS_S60) QPoint p; - const bool doS60Positioning = !(isFullScreen()||isMaximized()); - if (doS60Positioning) { - QPoint oldPos = pos(); + QPoint oldPos = pos(); + if (isFullScreen()) { + p.setX(0); + p.setY(0); + } else if (isMaximized()) { + TRect statusPaneRect = TRect(); + if (S60->screenHeightInPixels > S60->screenWidthInPixels) { + AknLayoutUtils::LayoutMetricsRect(AknLayoutUtils::EStatusPane, statusPaneRect); + } else { + AknLayoutUtils::LayoutMetricsRect(AknLayoutUtils::EStaconTop, statusPaneRect); + } + + p.setX(0); + p.setY(statusPaneRect.Height()); + } else { // naive way to deduce screen orientation if (S60->screenHeightInPixels > S60->screenWidthInPixels) { int cbaHeight; @@ -937,10 +949,10 @@ bool QDialog::symbianAdjustedPosition() p.setX(qMax(0,S60->screenWidthInPixels - width())); } } - if (oldPos != p || p.y() < 0) - move(p); } - return doS60Positioning; + if (oldPos != p || p.y() < 0) + move(p); + return true; #else // TODO - check positioning requirement for Symbian, non-s60 return false; diff --git a/src/gui/dialogs/qdialog.h b/src/gui/dialogs/qdialog.h index b2ba93c..ee23b7b 100644 --- a/src/gui/dialogs/qdialog.h +++ b/src/gui/dialogs/qdialog.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qdialog_p.h b/src/gui/dialogs/qdialog_p.h index 8088c85..a2a948e 100644 --- a/src/gui/dialogs/qdialog_p.h +++ b/src/gui/dialogs/qdialog_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qdialogsbinarycompat_win.cpp b/src/gui/dialogs/qdialogsbinarycompat_win.cpp index 56e31c2..beec2cd 100644 --- a/src/gui/dialogs/qdialogsbinarycompat_win.cpp +++ b/src/gui/dialogs/qdialogsbinarycompat_win.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qerrormessage.cpp b/src/gui/dialogs/qerrormessage.cpp index 7be7481..6d474cc 100644 --- a/src/gui/dialogs/qerrormessage.cpp +++ b/src/gui/dialogs/qerrormessage.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qerrormessage.h b/src/gui/dialogs/qerrormessage.h index 535bad7..500482c 100644 --- a/src/gui/dialogs/qerrormessage.h +++ b/src/gui/dialogs/qerrormessage.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfiledialog.cpp b/src/gui/dialogs/qfiledialog.cpp index f3f7469..5ff8d1e 100644 --- a/src/gui/dialogs/qfiledialog.cpp +++ b/src/gui/dialogs/qfiledialog.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfiledialog.h b/src/gui/dialogs/qfiledialog.h index 16cb317..fabb575 100644 --- a/src/gui/dialogs/qfiledialog.h +++ b/src/gui/dialogs/qfiledialog.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfiledialog.ui b/src/gui/dialogs/qfiledialog.ui index 1f35abb..dcb0811 100644 --- a/src/gui/dialogs/qfiledialog.ui +++ b/src/gui/dialogs/qfiledialog.ui @@ -1,7 +1,7 @@ <ui version="4.0" > <comment>********************************************************************* ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfiledialog_embedded.ui b/src/gui/dialogs/qfiledialog_embedded.ui index 10c9463..e8de400 100644 --- a/src/gui/dialogs/qfiledialog_embedded.ui +++ b/src/gui/dialogs/qfiledialog_embedded.ui @@ -1,7 +1,7 @@ <ui version="4.0" > <comment>********************************************************************* ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfiledialog_mac.mm b/src/gui/dialogs/qfiledialog_mac.mm index 1e13113..cc53858 100644 --- a/src/gui/dialogs/qfiledialog_mac.mm +++ b/src/gui/dialogs/qfiledialog_mac.mm @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfiledialog_p.h b/src/gui/dialogs/qfiledialog_p.h index 661bf1f..882acdd 100644 --- a/src/gui/dialogs/qfiledialog_p.h +++ b/src/gui/dialogs/qfiledialog_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfiledialog_symbian.cpp b/src/gui/dialogs/qfiledialog_symbian.cpp index 1f70305..e7197bd 100644 --- a/src/gui/dialogs/qfiledialog_symbian.cpp +++ b/src/gui/dialogs/qfiledialog_symbian.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** @@ -64,7 +64,7 @@ public: filterList.clear(); if (filter.left(2) == QLatin1String("*.")) { //Filter has only extensions - filterList << filter.split(" "); + filterList << filter.split(QLatin1String(" ")); return; } else { //Extensions are in parenthesis and there may be several filters @@ -75,7 +75,7 @@ public: return; } } - QRegExp rx("\\(([^\\)]*)\\)"); + QRegExp rx(QLatin1String("\\(([^\\)]*)\\)")); int pos = 0; while ((pos = rx.indexIn(filter, pos)) != -1) { filterList << rx.cap(1).split(QLatin1String(" ")); @@ -119,36 +119,49 @@ static QString launchSymbianDialog(const QString dialogCaption, const QString st { QString selection; #if defined(Q_WS_S60) && defined(SYMBIAN_VERSION_SYMBIAN3) - QT_TRAP_THROWING( - TFileName startFolder; - if (!startDirectory.isEmpty()) { - QString dir = QDir::toNativeSeparators(startDirectory); + TFileName startFolder; + if (!startDirectory.isEmpty()) { + QString dir = QDir::toNativeSeparators(QFileDialogPrivate::workingDirectory(startDirectory)); + startFolder = qt_QString2TPtrC(dir); + } + TInt types = AknCommonDialogsDynMem::EMemoryTypeMMCExternal| + AknCommonDialogsDynMem::EMemoryTypeInternalMassStorage| + AknCommonDialogsDynMem::EMemoryTypePhone; + + TPtrC titlePtr(qt_QString2TPtrC(dialogCaption)); + TFileName target; + bool select = false; + int tryCount = 2; + while (tryCount--) { + TInt err(KErrNone); + TRAP(err, + if (dialogMode == DialogOpen) { + CExtensionFilter* extensionFilter = new (ELeave) CExtensionFilter; + CleanupStack::PushL(extensionFilter); + extensionFilter->setFilter(filter); + select = AknCommonDialogsDynMem::RunSelectDlgLD(types, target, + startFolder, NULL, NULL, titlePtr, extensionFilter); + CleanupStack::Pop(extensionFilter); + } else if (dialogMode == DialogSave) { + select = AknCommonDialogsDynMem::RunSaveDlgLD(types, target, + startFolder, NULL, NULL, titlePtr); + } else if (dialogMode == DialogFolder) { + select = AknCommonDialogsDynMem::RunFolderSelectDlgLD(types, target, startFolder, + 0, 0, titlePtr, NULL, NULL); + } + ); + + if (err == KErrNone) { + tryCount = 0; + } else { + // Symbian native file dialog doesn't allow accessing files outside C:/Data + // It will always leave in that case, so default into QDir::rootPath() in error cases. + QString dir = QDir::toNativeSeparators(QDir::rootPath()); startFolder = qt_QString2TPtrC(dir); } - TInt types = AknCommonDialogsDynMem::EMemoryTypeMMCExternal| - AknCommonDialogsDynMem::EMemoryTypeInternalMassStorage| - AknCommonDialogsDynMem::EMemoryTypePhone; - - TPtrC titlePtr(qt_QString2TPtrC(dialogCaption)); - TFileName target; - bool select = false; - if (dialogMode == DialogOpen) { - CExtensionFilter* extensionFilter = new (ELeave) CExtensionFilter; - CleanupStack::PushL(extensionFilter); - extensionFilter->setFilter(filter); - select = AknCommonDialogsDynMem::RunSelectDlgLD(types, target, - startFolder, NULL, NULL, titlePtr, extensionFilter); - CleanupStack::Pop(extensionFilter); - } else if (dialogMode == DialogSave) { - select = AknCommonDialogsDynMem::RunSaveDlgLD(types, target, - startFolder, NULL, NULL, titlePtr); - } else if (dialogMode == DialogFolder) { - select = AknCommonDialogsDynMem::RunFolderSelectDlgLD(types, target, startFolder, - 0, 0, titlePtr, NULL, NULL); - } - if (select) - selection.append(qt_TDesC2QString(target)); - ); + } + if (select) + selection.append(qt_TDesC2QString(target)); #endif return selection; } diff --git a/src/gui/dialogs/qfiledialog_win.cpp b/src/gui/dialogs/qfiledialog_win.cpp index 5b192b4..9b68adb 100644 --- a/src/gui/dialogs/qfiledialog_win.cpp +++ b/src/gui/dialogs/qfiledialog_win.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfiledialog_win_p.h b/src/gui/dialogs/qfiledialog_win_p.h index 7079925..7580f0a 100644 --- a/src/gui/dialogs/qfiledialog_win_p.h +++ b/src/gui/dialogs/qfiledialog_win_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfileinfogatherer.cpp b/src/gui/dialogs/qfileinfogatherer.cpp index af0506f..12e77b1 100644 --- a/src/gui/dialogs/qfileinfogatherer.cpp +++ b/src/gui/dialogs/qfileinfogatherer.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfileinfogatherer_p.h b/src/gui/dialogs/qfileinfogatherer_p.h index 8681eb5..3fb4d90 100644 --- a/src/gui/dialogs/qfileinfogatherer_p.h +++ b/src/gui/dialogs/qfileinfogatherer_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfilesystemmodel.cpp b/src/gui/dialogs/qfilesystemmodel.cpp index 8a9f8ae..8bd7fe3 100644 --- a/src/gui/dialogs/qfilesystemmodel.cpp +++ b/src/gui/dialogs/qfilesystemmodel.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfilesystemmodel.h b/src/gui/dialogs/qfilesystemmodel.h index d8178c7..fe8cf4d 100644 --- a/src/gui/dialogs/qfilesystemmodel.h +++ b/src/gui/dialogs/qfilesystemmodel.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfilesystemmodel_p.h b/src/gui/dialogs/qfilesystemmodel_p.h index 03e0bfb..e83bbd1 100644 --- a/src/gui/dialogs/qfilesystemmodel_p.h +++ b/src/gui/dialogs/qfilesystemmodel_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfontdialog.cpp b/src/gui/dialogs/qfontdialog.cpp index b159fa7..b58021d 100644 --- a/src/gui/dialogs/qfontdialog.cpp +++ b/src/gui/dialogs/qfontdialog.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfontdialog.h b/src/gui/dialogs/qfontdialog.h index 6035a3a..a09f16d 100644 --- a/src/gui/dialogs/qfontdialog.h +++ b/src/gui/dialogs/qfontdialog.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfontdialog_mac.mm b/src/gui/dialogs/qfontdialog_mac.mm index 9c63dfa..87187fc 100644 --- a/src/gui/dialogs/qfontdialog_mac.mm +++ b/src/gui/dialogs/qfontdialog_mac.mm @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** @@ -116,6 +116,7 @@ const int StyleMask = NSTitledWindowMask | NSClosableWindowMask | NSResizableWin - (void)showModelessPanel; - (void)showWindowModalSheet:(QWidget *)docWidget; - (void)runApplicationModalPanel; +- (BOOL)isAppModal; - (void)changeFont:(id)sender; - (void)changeAttributes:(id)sender; - (BOOL)windowShouldClose:(id)window; @@ -226,6 +227,7 @@ static QFont qfontForCocoaFont(NSFont *cocoaFont, const QFont &resolveFont) QBoolBlocker nativeDialogOnTop(QApplicationPrivate::native_modal_dialog_active); mAppModal = true; NSWindow *ourPanel = [mStolenContentView window]; + [ourPanel setReleasedWhenClosed:NO]; [NSApp runModalForWindow:ourPanel]; QAbstractEventDispatcher::instance()->interrupt(); @@ -235,6 +237,11 @@ static QFont qfontForCocoaFont(NSFont *cocoaFont, const QFont &resolveFont) mPriv->fontDialog()->reject(); } +- (BOOL)isAppModal +{ + return mAppModal; +} + - (void)showWindowModalSheet:(QWidget *)docWidget { #ifdef QT_MAC_USE_COCOA @@ -485,6 +492,8 @@ void QFontDialogPrivate::closeCocoaFontPanel() QT_MANGLE_NAMESPACE(QCocoaFontPanelDelegate) *theDelegate = static_cast<QT_MANGLE_NAMESPACE(QCocoaFontPanelDelegate) *>(delegate); NSWindow *ourPanel = [theDelegate actualPanel]; [ourPanel close]; + if ([theDelegate isAppModal]) + [ourPanel release]; [theDelegate cleanUpAfterMyself]; [theDelegate release]; this->delegate = 0; diff --git a/src/gui/dialogs/qfontdialog_p.h b/src/gui/dialogs/qfontdialog_p.h index 8676be3..3179b89 100644 --- a/src/gui/dialogs/qfontdialog_p.h +++ b/src/gui/dialogs/qfontdialog_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qfscompleter_p.h b/src/gui/dialogs/qfscompleter_p.h index 917e176..26a6698 100644 --- a/src/gui/dialogs/qfscompleter_p.h +++ b/src/gui/dialogs/qfscompleter_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qinputdialog.cpp b/src/gui/dialogs/qinputdialog.cpp index a29376a..1947a08 100644 --- a/src/gui/dialogs/qinputdialog.cpp +++ b/src/gui/dialogs/qinputdialog.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qinputdialog.h b/src/gui/dialogs/qinputdialog.h index 02868c1..f3fbda6 100644 --- a/src/gui/dialogs/qinputdialog.h +++ b/src/gui/dialogs/qinputdialog.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qmessagebox.cpp b/src/gui/dialogs/qmessagebox.cpp index 2f8b9e2..dd06445 100644 --- a/src/gui/dialogs/qmessagebox.cpp +++ b/src/gui/dialogs/qmessagebox.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** @@ -1761,7 +1761,7 @@ void QMessageBox::aboutQt(QWidget *parent, const QString &title) "to comply with the terms of the GNU GPL version 3.0.</p>" "<p>Please see <a href=\"http://qt.nokia.com/products/licensing\">qt.nokia.com/products/licensing</a> " "for an overview of Qt licensing.</p>" - "<p>Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).</p>" + "<p>Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).</p>" "<p>Qt is a Nokia product. See <a href=\"http://qt.nokia.com/\">qt.nokia.com</a> " "for more information.</p>" ); diff --git a/src/gui/dialogs/qmessagebox.h b/src/gui/dialogs/qmessagebox.h index f1ff6cc..37ddb38 100644 --- a/src/gui/dialogs/qmessagebox.h +++ b/src/gui/dialogs/qmessagebox.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qnspanelproxy_mac.mm b/src/gui/dialogs/qnspanelproxy_mac.mm index 0bd5c63..3078888 100644 --- a/src/gui/dialogs/qnspanelproxy_mac.mm +++ b/src/gui/dialogs/qnspanelproxy_mac.mm @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qpagesetupdialog.cpp b/src/gui/dialogs/qpagesetupdialog.cpp index 4f8c258..4037e1c 100644 --- a/src/gui/dialogs/qpagesetupdialog.cpp +++ b/src/gui/dialogs/qpagesetupdialog.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qpagesetupdialog.h b/src/gui/dialogs/qpagesetupdialog.h index b84758c..184af25 100644 --- a/src/gui/dialogs/qpagesetupdialog.h +++ b/src/gui/dialogs/qpagesetupdialog.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qpagesetupdialog_mac.mm b/src/gui/dialogs/qpagesetupdialog_mac.mm index 0302be4..48a44a0 100644 --- a/src/gui/dialogs/qpagesetupdialog_mac.mm +++ b/src/gui/dialogs/qpagesetupdialog_mac.mm @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qpagesetupdialog_unix.cpp b/src/gui/dialogs/qpagesetupdialog_unix.cpp index e24cabe..a4e0927 100644 --- a/src/gui/dialogs/qpagesetupdialog_unix.cpp +++ b/src/gui/dialogs/qpagesetupdialog_unix.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qpagesetupdialog_unix_p.h b/src/gui/dialogs/qpagesetupdialog_unix_p.h index 1ffab99..fea70b6 100644 --- a/src/gui/dialogs/qpagesetupdialog_unix_p.h +++ b/src/gui/dialogs/qpagesetupdialog_unix_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qpagesetupdialog_win.cpp b/src/gui/dialogs/qpagesetupdialog_win.cpp index fed4bc8..d74da7c 100644 --- a/src/gui/dialogs/qpagesetupdialog_win.cpp +++ b/src/gui/dialogs/qpagesetupdialog_win.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qprintdialog.h b/src/gui/dialogs/qprintdialog.h index 94177ea..0543160 100644 --- a/src/gui/dialogs/qprintdialog.h +++ b/src/gui/dialogs/qprintdialog.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qprintdialog.qdoc b/src/gui/dialogs/qprintdialog.qdoc index b75fe2e..0fff9dd 100644 --- a/src/gui/dialogs/qprintdialog.qdoc +++ b/src/gui/dialogs/qprintdialog.qdoc @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qprintdialog_mac.mm b/src/gui/dialogs/qprintdialog_mac.mm index 82e4db5..ed60b10 100644 --- a/src/gui/dialogs/qprintdialog_mac.mm +++ b/src/gui/dialogs/qprintdialog_mac.mm @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qprintdialog_qws.cpp b/src/gui/dialogs/qprintdialog_qws.cpp index b071427..373b986 100644 --- a/src/gui/dialogs/qprintdialog_qws.cpp +++ b/src/gui/dialogs/qprintdialog_qws.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qprintdialog_unix.cpp b/src/gui/dialogs/qprintdialog_unix.cpp index 5d0bcac..5b5c49d 100644 --- a/src/gui/dialogs/qprintdialog_unix.cpp +++ b/src/gui/dialogs/qprintdialog_unix.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qprintdialog_win.cpp b/src/gui/dialogs/qprintdialog_win.cpp index 38c8759..4f6866b 100644 --- a/src/gui/dialogs/qprintdialog_win.cpp +++ b/src/gui/dialogs/qprintdialog_win.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qprintpreviewdialog.cpp b/src/gui/dialogs/qprintpreviewdialog.cpp index d74742a..eb597fb 100644 --- a/src/gui/dialogs/qprintpreviewdialog.cpp +++ b/src/gui/dialogs/qprintpreviewdialog.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qprintpreviewdialog.h b/src/gui/dialogs/qprintpreviewdialog.h index a9d5052..a49455b 100644 --- a/src/gui/dialogs/qprintpreviewdialog.h +++ b/src/gui/dialogs/qprintpreviewdialog.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qprogressdialog.cpp b/src/gui/dialogs/qprogressdialog.cpp index d64c847..a3fff9b 100644 --- a/src/gui/dialogs/qprogressdialog.cpp +++ b/src/gui/dialogs/qprogressdialog.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qprogressdialog.h b/src/gui/dialogs/qprogressdialog.h index 16afea8..21a40c1 100644 --- a/src/gui/dialogs/qprogressdialog.h +++ b/src/gui/dialogs/qprogressdialog.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qsidebar.cpp b/src/gui/dialogs/qsidebar.cpp index 8262ddf..2869e12 100644 --- a/src/gui/dialogs/qsidebar.cpp +++ b/src/gui/dialogs/qsidebar.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qsidebar_p.h b/src/gui/dialogs/qsidebar_p.h index 126b61a..188f4d7 100644 --- a/src/gui/dialogs/qsidebar_p.h +++ b/src/gui/dialogs/qsidebar_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qwizard.cpp b/src/gui/dialogs/qwizard.cpp index 8607529..ce5118f 100644 --- a/src/gui/dialogs/qwizard.cpp +++ b/src/gui/dialogs/qwizard.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qwizard.h b/src/gui/dialogs/qwizard.h index b146147..148a592 100644 --- a/src/gui/dialogs/qwizard.h +++ b/src/gui/dialogs/qwizard.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qwizard_win.cpp b/src/gui/dialogs/qwizard_win.cpp index 5fca8f2..3480c68 100644 --- a/src/gui/dialogs/qwizard_win.cpp +++ b/src/gui/dialogs/qwizard_win.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/gui/dialogs/qwizard_win_p.h b/src/gui/dialogs/qwizard_win_p.h index caf018d..b76f082 100644 --- a/src/gui/dialogs/qwizard_win_p.h +++ b/src/gui/dialogs/qwizard_win_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** |