diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-04-23 17:01:30 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-04-23 17:01:30 (GMT) |
commit | 27f96458ba40dcbf5db4df0b0e553ca5799a13c4 (patch) | |
tree | 51903070ae0fa3afa89dce2e128f9e8e5fbb6f0e | |
parent | 15088d236924bccee787953e04214f87392e8e55 (diff) | |
parent | 466d7562a40eb0c2cf72f57fce0bc5e9b0de37c2 (diff) | |
download | Qt-27f96458ba40dcbf5db4df0b0e553ca5799a13c4.zip Qt-27f96458ba40dcbf5db4df0b0e553ca5799a13c4.tar.gz Qt-27f96458ba40dcbf5db4df0b0e553ca5799a13c4.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1:
qdoc: Removed nested <ul> elements from the TOC
Diacritic input broken, duplicate the base glypha (on Mac OS X carbon)
Cocoa: quiting the app from the menubar may cause a crash
-rw-r--r-- | src/gui/kernel/qkeymapper_mac.cpp | 13 | ||||
-rw-r--r-- | src/gui/widgets/qmenu_mac.mm | 2 | ||||
-rw-r--r-- | tools/qdoc3/htmlgenerator.cpp | 43 |
3 files changed, 42 insertions, 16 deletions
diff --git a/src/gui/kernel/qkeymapper_mac.cpp b/src/gui/kernel/qkeymapper_mac.cpp index f259654..a7145d4 100644 --- a/src/gui/kernel/qkeymapper_mac.cpp +++ b/src/gui/kernel/qkeymapper_mac.cpp @@ -756,14 +756,23 @@ bool QKeyMapperPrivate::translateKeyEvent(QWidget *widget, EventHandlerCallRef e return true; } - if (qApp->inputContext() && qApp->inputContext()->isComposing()) { + QInputContext *currentContext = qApp->inputContext(); + if (currentContext && currentContext->isComposing()) { if (ekind == kEventRawKeyDown) { - QMacInputContext *context = qobject_cast<QMacInputContext*>(qApp->inputContext()); + QMacInputContext *context = qobject_cast<QMacInputContext*>(currentContext); if (context) context->setLastKeydownEvent(event); } return false; } + // Once we process the key down , we dont need to send the saved event again from + // kEventTextInputUnicodeForKeyEvent, so clear it. + if (currentContext && ekind == kEventRawKeyDown) { + QMacInputContext *context = qobject_cast<QMacInputContext*>(currentContext); + if (context) + context->setLastKeydownEvent(0); + } + //get modifiers Qt::KeyboardModifiers modifiers; int qtKey; diff --git a/src/gui/widgets/qmenu_mac.mm b/src/gui/widgets/qmenu_mac.mm index 7645c23..e8400d6 100644 --- a/src/gui/widgets/qmenu_mac.mm +++ b/src/gui/widgets/qmenu_mac.mm @@ -1831,7 +1831,7 @@ void QMenuBarPrivate::macDestroyMenuBar() menubars()->remove(tlw); mac_menubar = 0; - if (qt_mac_current_menubar.qmenubar == q) { + if (!qt_mac_current_menubar.qmenubar || qt_mac_current_menubar.qmenubar == q) { #ifdef QT_MAC_USE_COCOA QT_MANGLE_NAMESPACE(QCocoaMenuLoader) *loader = getMenuLoader(); [loader removeActionsFromAppMenu]; diff --git a/tools/qdoc3/htmlgenerator.cpp b/tools/qdoc3/htmlgenerator.cpp index 9a5ffca..6b7d350 100644 --- a/tools/qdoc3/htmlgenerator.cpp +++ b/tools/qdoc3/htmlgenerator.cpp @@ -1923,18 +1923,30 @@ void HtmlGenerator::generateTableOfContents(const Node *node, inLink = true; out() << "<div class=\"toc\">\n"; - out() << "<h3>Table of Contents</h3>\n"; + out() << "<h3>Contents</h3>\n"; sectionNumber.append("1"); - out() << "<ul class=\"level" << sectionNumber.size() << "\">\n"; + out() << "<ul>\n"; if (node->subType() == Node::Module) { if (moduleNamespaceMap.contains(node->name())) { - out() << "<li><a href=\"#" << registerRef("namespaces") << "\">Namespaces</a></li>\n"; + out() << "<li class=\"level" + << sectionNumber.size() + << "\"><a href=\"#" + << registerRef("namespaces") + << "\">Namespaces</a></li>\n"; } if (moduleClassMap.contains(node->name())) { - out() << "<li><a href=\"#" << registerRef("classes") << "\">Classes</a></li>\n"; - } - out() << "<li><a href=\"#" << registerRef("details") << "\">Detailed Description</a></li>\n"; + out() << "<li class=\"level" + << sectionNumber.size() + << "\"><a href=\"#" + << registerRef("classes") + << "\">Classes</a></li>\n"; + } + out() << "<li class=\"level" + << sectionNumber.size() + << "\"><a href=\"#" + << registerRef("details") + << "\">Detailed Description</a></li>\n"; for (int i = 0; i < toc.size(); ++i) { if (toc.at(i)->string().toInt() == 1) { detailsBase = 1; @@ -1946,14 +1958,20 @@ void HtmlGenerator::generateTableOfContents(const Node *node, QList<Section>::ConstIterator s = sections->begin(); while (s != sections->end()) { if (!s->members.isEmpty() || !s->reimpMembers.isEmpty()) { - out() << "<li><a href=\"#" + out() << "<li class=\"level" + << sectionNumber.size() + << "\"><a href=\"#" << registerRef((*s).pluralMember) << "\">" << (*s).name << "</a></li>\n"; } ++s; } - out() << "<li><a href=\"#" << registerRef("details") << "\">Detailed Description</a></li>\n"; + out() << "<li class=\"level" + << sectionNumber.size() + << "\"><a href=\"#" + << registerRef("details") + << "\">Detailed Description</a></li>\n"; for (int i = 0; i < toc.size(); ++i) { if (toc.at(i)->string().toInt() == 1) { detailsBase = 1; @@ -1968,12 +1986,10 @@ void HtmlGenerator::generateTableOfContents(const Node *node, if (sectionNumber.size() < nextLevel) { do { sectionNumber.append("1"); - out() << "<ul class=\"level" << sectionNumber.size() << "\">\n"; } while (sectionNumber.size() < nextLevel); } else { while (sectionNumber.size() > nextLevel) { - out() << "</ul>\n"; sectionNumber.removeLast(); } sectionNumber.last() = QString::number(sectionNumber.last().toInt() + 1); @@ -1981,19 +1997,20 @@ void HtmlGenerator::generateTableOfContents(const Node *node, int numAtoms; Text headingText = Text::sectionHeading(atom); QString s = headingText.toString(); - out() << "<li>"; + out() << "<li class=\"level" + << sectionNumber.size() + << "\">"; out() << "<a href=\"" << "#" - //<< registerRef(s) << Doc::canonicalTitle(s) << "\">"; generateAtomList(headingText.firstAtom(), node, marker, true, numAtoms); out() << "</a></li>\n"; } while (!sectionNumber.isEmpty()) { - out() << "</ul>\n"; sectionNumber.removeLast(); } + out() << "</ul>\n"; out() << "</div>\n"; inContents = false; inLink = false; |