diff options
-rw-r--r-- | config.tests/unix/stl/stltest.cpp | 2 | ||||
-rw-r--r-- | src/gui/styles/qmacstyle_mac.mm | 4 | ||||
-rw-r--r-- | src/gui/widgets/qmenu_mac.mm | 6 | ||||
-rw-r--r-- | src/script/bridge/qscriptqobject.cpp | 1 | ||||
-rw-r--r-- | tools/designer/src/lib/shared/qtresourceview.cpp | 2 |
5 files changed, 10 insertions, 5 deletions
diff --git a/config.tests/unix/stl/stltest.cpp b/config.tests/unix/stl/stltest.cpp index ff9b8f9..382f5cb 100644 --- a/config.tests/unix/stl/stltest.cpp +++ b/config.tests/unix/stl/stltest.cpp @@ -69,7 +69,7 @@ class DummyIterator public: T *i; typedef std::random_access_iterator_tag iterator_category; - typedef ptrdiff_t difference_type; + typedef std::ptrdiff_t difference_type; typedef T value_type; typedef T *pointer; typedef T &reference; diff --git a/src/gui/styles/qmacstyle_mac.mm b/src/gui/styles/qmacstyle_mac.mm index 7097291..074dd89 100644 --- a/src/gui/styles/qmacstyle_mac.mm +++ b/src/gui/styles/qmacstyle_mac.mm @@ -434,13 +434,13 @@ static inline bool isTreeView(const QWidget *widget) QString qt_mac_removeMnemonics(const QString &original) { - // copied from qt_format_text (to be bug-for-bug compatible). QString returnText(original.size(), 0); int finalDest = 0; int currPos = 0; int l = original.length(); while (l) { - if (original.at(currPos) == QLatin1Char('&')) { + if (original.at(currPos) == QLatin1Char('&') + && (l == 1 || original.at(currPos + 1) != QLatin1Char('&'))) { ++currPos; --l; if (l == 0) diff --git a/src/gui/widgets/qmenu_mac.mm b/src/gui/widgets/qmenu_mac.mm index 9a14ce6..6a0eb53 100644 --- a/src/gui/widgets/qmenu_mac.mm +++ b/src/gui/widgets/qmenu_mac.mm @@ -1391,7 +1391,11 @@ QMenuPrivate::QMacMenuPrivate::syncAction(QMacMenuAction *action) } else { [item setTitle: qt_mac_QStringToNSString(finalString)]; } - [item setTitle:qt_mac_QStringToNSString(qt_mac_removeMnemonics(text))]; + + if (action->action->menuRole() == QAction::AboutRole || action->action->menuRole() == QAction::QuitRole) + [item setTitle:qt_mac_QStringToNSString(text)]; + else + [item setTitle:qt_mac_QStringToNSString(qt_mac_removeMnemonics(text))]; // Cocoa Enabled [item setEnabled: action->action->isEnabled()]; diff --git a/src/script/bridge/qscriptqobject.cpp b/src/script/bridge/qscriptqobject.cpp index 83a811b..0477454 100644 --- a/src/script/bridge/qscriptqobject.cpp +++ b/src/script/bridge/qscriptqobject.cpp @@ -2074,6 +2074,7 @@ void QObjectConnectionManager::execute(int slotIndex, void **argv) JSC::JSValue slot; JSC::JSValue senderWrapper; int signalIndex = -1; + QScript::APIShim shim(engine); for (int i = 0; i < connections.size(); ++i) { const QVector<QObjectConnection> &cs = connections.at(i); for (int j = 0; j < cs.size(); ++j) { diff --git a/tools/designer/src/lib/shared/qtresourceview.cpp b/tools/designer/src/lib/shared/qtresourceview.cpp index 3c7010c..18fd07b 100644 --- a/tools/designer/src/lib/shared/qtresourceview.cpp +++ b/tools/designer/src/lib/shared/qtresourceview.cpp @@ -421,7 +421,7 @@ void QtResourceViewPrivate::filterOutResources() // 3) we hide these items which has pathToVisible value false. const bool matchAll = m_filterPattern.isEmpty(); - const QString root(QLatin1Char(':')); + const QString root(QLatin1String(":/")); QQueue<QString> pathQueue; pathQueue.enqueue(root); |