summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Make QMapData::shared_null constBradley T. Hughes2011-09-262-8/+8
| | | | | | | | | | Similar to QVector, QByteArray and QString, keep the shared_null in shareable memory and never modify it. Change-Id: I062825684b79f2b01ec7ce65e0cf74f417b760b8 Reviewed-on: http://codereview.qt-project.org/4530 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Make QListData::shared_null constBradley T. Hughes2011-09-262-8/+9
| | | | | | | | | | Similar to QMap, QVector, QByteArray and QString, keep the shared_null in shareable memory and never modify it. Change-Id: I2b4bb8de564080021043f6ede6c903d567c686cf Reviewed-on: http://codereview.qt-project.org/4531 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Make QLinkedListData::shared_null constBradley T. Hughes2011-09-262-7/+8
| | | | | | | | | | Similar to QList, QMap, QVector, QByteArray and QString, keep the shared_null in shareable memory and never modify it. Change-Id: I70b484d528c397a9d205b1418b6dc920c69dc725 Reviewed-on: http://codereview.qt-project.org/4532 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Make QHashData::shared_null constBradley T. Hughes2011-09-262-6/+6
| | | | | | | | | | Similar to QLinkedList QList, QMap, QVector, QByteArray and QString, keep the shared_null in shareable memory and never modify it. Change-Id: Ia8b72ef0288575bed658153d9d54434580988bda Reviewed-on: http://codereview.qt-project.org/4533 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* don't calculate hash when the map is empty and we are not insertingOswald Buddenhagen2011-09-261-3/+6
| | | | | | | | | | | | the alternative would be splitting the function into two separate overloads. that might result in better branch prediction, but will create a bit more code. Change-Id: Ia2c685bbb34a9681c71f2249d073dd960368209a Reviewed-on: http://codereview.qt-project.org/5332 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Doc: Fixed \since declarations.David Boddie2011-09-261-2/+2
| | | | | | | | | | (cherry picked from commit 358e018dbb4b4dbdbfc702a6d462f113a1357e1e) (cherry picked from commit 16355187f69d4431b79b05201b36729c8e5102fe) Change-Id: Idb18570df01c7463e0dc0f78fd05f80372afa64f Reviewed-on: http://codereview.qt-project.org/1983 Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com> Reviewed-by: Peter Yard <peter.yard@nokia.com>
* Doc: Clarified the range of return values from QLineF::angle().David Boddie2011-09-261-2/+3
| | | | | | | | | | | | Task-number: QTBUG-20197 (cherry picked from commit 86608d537eabc3cf7e1d1ddd1d0a2f90ccc2de2a) (cherry picked from commit 8a6dc154ef1fa71e85f02d011d6cbeb63e2ca3bb) Change-Id: I40cfba4ee45f61428b00d4044640f600c462d564 Reviewed-on: http://codereview.qt-project.org/1984 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com> Reviewed-by: Peter Yard <peter.yard@nokia.com>
* Doc: Moved general notes about character conversion.David Boddie2011-09-261-10/+13
| | | | | | | | | | | Task-number: QTBUG-20411 (cherry picked from commit b3922d06680c04324cecd0e0219d02c52b8cf7fd) Change-Id: If2730fa0d8abd6a14070bc19c8c307dbb61ca111 Reviewed-on: http://codereview.qt-project.org/1985 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com> Reviewed-by: Peter Yard <peter.yard@nokia.com>
* Implement QTEST_GUILESS_MAINJan Kundrát2011-09-262-1/+25
| | | | | | | | | | | | Add support for test cases which require an event loop, but do not need GUI up and running. Such cases are best accommodated by code similar to QTEST_MAIN, but using QCoreApplication instead of QApplication. Change-Id: I04ce82d26b80a4edeba6bf7604a7f8d974232a11 Merge-request: 919 Reviewed-on: http://codereview.qt-project.org/5427 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
* Use the right callback in QObject::disconnect()Olivier Goffart2011-09-231-1/+1
| | | | | | | Change-Id: Idf2f725dd859aa5c960e5889678cac0e139e44b0 Reviewed-on: http://codereview.qt-project.org/5475 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Make sure cursor position doesn't exceed line endJiang Jiang2011-09-231-0/+3
| | | | | | | | | | | | | | If we have trailing spaces at the end of a line, cursor will disappear because the position we returned exceeds line end, thus the widget border. By limiting it within line.width we can make sure it always visible, which is more consistent to the behavior in common platforms. Reviewed-by: Eskil (cherry picked from commit c750afe0e0f043389d30850070889946e4c6e8af) Change-Id: Ifc60b718369639bbb6f5afb35c29a6eb0dccd219 Reviewed-on: http://codereview.qt-project.org/5458 Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
* Fix QString and QByteArray reserve() and squeeze()Bradley T. Hughes2011-09-232-4/+42
| | | | | | | | | | | | | | | | | These functions should not take care not to unconditionally set the capacityReserved private member, since the d may be referencing the const shared_null or shared_empty which live in read-only memory. The squeeze() methods check for ref > 1 instead of ref != 1 to prevent detaching from the shared_null/shared_empty unnecessarily; the shared_null/shared_empty ref count is -1, meaning squeeze() will never detach from it. Change-Id: Id3f1725a6f08b3a462343640a47bbe78f08ca7e7 Rubberstamped-by: Lars Knoll Reviewed-on: http://codereview.qt-project.org/5454 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* QByteArray's shared_null and shared_empty should be constBradley T. Hughes2011-09-232-7/+7
| | | | | | | | | | | | QByteArray::squeeze() needs to make sure to detach if the data is shared, otherwise it would end up crashing when squeeze() is called on a QByteArray using the shared_null or shared_empty. Change-Id: I89c178659d8c7448681304f050fd69e17b2387de Reviewed-on: http://codereview.qt-project.org/4528 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Remove Q_GLOBAL_STATIC_WITH_INITIALIZER from QtWidgetsLars Knoll2011-09-233-4/+22
| | | | | | | Change-Id: Iecad85fbbfabe41c3a332be2ee0ce3a643db7731 Reviewed-on: http://codereview.qt-project.org/5025 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* Implemented QWidget's move() vs setGeometry() distinction in QWindow.Samuel Rødal2011-09-235-8/+91
| | | | | | | | | | | | | | QWidget's move() sets the position of the window including the window frame, unlike setGeometry(). There was no equivalent for this in QWindow, so several QWidget auto-tests were failing. Now we add setFramePos() to achieve the same purpose in QWindow. This fixes tst_QWidget::windowState(), which uses move(). Change-Id: I9a3e558bd615a8f0234cc3dd94fbb2bf5ecbc148 Reviewed-on: http://codereview.qt-project.org/5405 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Patch toward fixing tst_QWidget::windowState().Samuel Rødal2011-09-231-8/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | In QWidget::setWindowState() there was some code to emulate window states when they're not supported by the backend, by hiding the window on minimize or using the screen geometry and the frameless window hint to manually try to make a window fullscreen. However, some of this code was being run even when the backend does support setting window states, specifically calling setParent(0) to force a re-creation of the platform window and calling show(). These led to the window getting the wrong position after being minimized or fullscreen and going back to the normal state. Apart from storing the normal geometry of a widget when going away from the normal state we shouldn't do any magic when the call to QPlatformWindow::setWindowState() succeeds. tst_QWidget::windowState() still fails due to calling move() to set the position of the widget including the frame, when QWindow currently only supports setting the position of the widget excluding the frame. Change-Id: I1c1a337d3c15f14c1c842bd1e347f94e6b67d7eb Reviewed-on: http://codereview.qt-project.org/5367 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Don't flood expose events in the xcb plugin.Samuel Rødal2011-09-232-1/+13
| | | | | | | | | | | | The X server sends a series of expose events, where the count member specifies how many expose events are remaining in the current series. By merging them into an expose region we can send a single expose event to the lighthouse interface. Change-Id: If73c9972fe02c5e4137e8742aaaf5679ccea5a09 Reviewed-on: http://codereview.qt-project.org/5366 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Only set frame margins as dirty when we get a configure notify event.Samuel Rødal2011-09-231-5/+2
| | | | | | | | | | | It's dangerous to set them as dirty in anticipation of a configure notify event, as if frameMargins() is called before the event is received the computed values are bogus. Change-Id: Ib6db975fba5fcb13a2511e4716cbb5ca79265c34 Reviewed-on: http://codereview.qt-project.org/5365 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Fixed geometry issues.Samuel Rødal2011-09-235-14/+19
| | | | | | | | | | | We need to compare against the window's currently known geometry to know when to send resize and move events. Also make sure at least one resize event is sent, instead of sending one before each expose. Change-Id: Id7ebe4c1c0e723af9198c668a0c736d64efdbf3e Reviewed-on: http://codereview.qt-project.org/5364 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Accessible ComboBox: remove virt children, add actions.Frederik Gladhorn2011-09-233-117/+65
| | | | | | | | | | Simplify the combobox implementation by removing child logic. Instead have an option to open the combobox. Change-Id: I1bb517d0d064aefa28594b8fa957b8b2c9d48e88 Reviewed-on: http://codereview.qt-project.org/5032 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
* Add autotest for QInputPanelJoona Petrell2011-09-232-9/+24
| | | | | | | Change-Id: I8ac28d93f610cd3eb69087d2c961a5aab6c47e1e Reviewed-on: http://codereview.qt-project.org/5394 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Don't call ref() in QByteArray::QByteArray()Bradley T. Hughes2011-09-231-1/+1
| | | | | | | | | | The call is unnecessary; it does nothing since the shared_null ref count is negative. Change-Id: I0d0c35a554e4fc5b734a25dab06f04bee7a9ae24 Reviewed-on: http://codereview.qt-project.org/4637 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Support adding application fonts with QFontconfigDatabaseJiang Jiang2011-09-2310-22/+113
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QFontDatabaseQPA should be able to reinitialize database and reregister all the fonts when an application font is added, because it will trigger db->invalidate(). Add cloneWithSize support to QFontEngineBox so that even no usable font is found in QFontDatabase, QRawFont::setPixelSize can still work (without making the result rawfont invalid). Register application fonts with QFontconfigDatabase, the code is adapted from QFontDatabaseX11. Reenable QRawFont tests for QPA, these usages are now supported in QPA. Fix QStaticText tests, raster in QPA does support transformations. Translate the text before ZAxix rotation so that it will be visible in canvas. Add back fixedPitch support to QPA, and fix QFontDatabase tests. Fix QGlyphRun tests, ignore non-existence glyphs in alphaMap locking. Fix QFontMetrics tests. Task-number: QTBUG-21415, QTBUG-20754, QTBUG-20977, QTBUG-20976, QTBUG-20760, QTBUG-20759 Change-Id: I24aea7d6ec6b2ac6342134d1f2591327c23a692b Reviewed-on: http://codereview.qt-project.org/5384 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
* Avoid crash in handleTouchEvent and remove superfluous mapping.Laszlo Agocs2011-09-231-8/+2
| | | | | | | | | | | | | | | | | | | 252d1b34b26779cbc1ac269f4af7fdb1f27038ef introduces a mapFromGlobal call in QWindowSystemInterface::handleTouchEvent. This has two issues: It ignores the fact that the tlw parameter can be null, resulting in an instant crash with the touch support of some platforms, and the mapping itself is unneccessary because QGuiApplication::processTouchEvent() will perform the same, the rect set via setRect() is basically ignored due to the touchPoint.d.rect = ... just before sending the final event to the widget in qguiapplication.cpp. Using setScreenRect instead of setRect is a valid fix from the previous patch, but the parts for the mapping need to be removed. Change-Id: I0bb40c7d647fb062106b151e5987f9970d6ab2c8 Reviewed-on: http://codereview.qt-project.org/5448 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Bjørn Erik Nilsen <bjorn.nilsen@nokia.com>
* Fix preedit text on XCBEskil Abrahamsen Blomfeldt2011-09-231-1/+1
| | | | | | | | | | indexOfMethod() requires a full signature, not just a method name. Change-Id: Icb15ab46cab61b35f5d56e8e94b71f5e3b72f97a Reviewed-on: http://codereview.qt-project.org/5386 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Page flipping API for QPlatformScreenPaul Olav Tvete2011-09-232-0/+51
| | | | | | | | | | | Adding a page flipping API for platform plugins. This enables Wayland compositors to show full-screen client windows directly without copying any data - if supported by the platform. Change-Id: I19abe366434140f9e20a0655fe7cd41ea9264fca Reviewed-on: http://codereview.qt-project.org/5385 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Accessible SpinBox remove dead code.Frederik Gladhorn2011-09-232-144/+5
| | | | | | | Change-Id: I8f3110a1683af98af605982277a618aa0ba97a64 Reviewed-on: http://codereview.qt-project.org/4822 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
* workaround XCB-ICCCM 3.8 breakage, second instanceOswald Buddenhagen2011-09-231-0/+2
| | | | | | | | Change-Id: Ic456f6ca9d845f50506b41d71bb5d2b83239a37e Reviewed-on: http://codereview.qt-project.org/5333 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Allow tests to log to multiple destinationsJason McDonald2011-09-233-64/+200
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Each destination and the format of output to write there is specified by adding "-o filename,format" to the command-line. The special filename "-" indicates that the log output is written to the standard output stream, though standard output can be used as a destination at most once. The old-style testlib output options are still supported, but can only be used to specify one logging destination, as before. If no logging options are given on the command-line, a plain text log will go to the console, as before. To log to the console in plain text and to the file "test_output" in xunit format, one would invoke a test in the following way: tst_foo -o test_output,xunitxml -o -,txt This commit also enhances the selftests to test with multiple loggers, but negative tests (e.g. bad combinations of command-line options) are left for future task QTBUG-21567. Task-number: QTBUG-20615 Change-Id: If91e752bc7001657e15e427aba9d25ab0a29a0b0 Reviewed-on: http://codereview.qt-project.org/4125 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Cocoa: Enable native menus.Morten Sorvig2011-09-222-4/+7
| | | | | | | | | | Fix menu duplication bug: make QCocoaMenu::addAction do nothing before the native menu has ben created. Change-Id: Ifca192421f2073264de9f5faeb053008ecb8532e Reviewed-on: http://codereview.qt-project.org/5135 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Allocate 16-byte aligned memory independent of platform for raster pool.Samuel Rødal2011-09-221-37/+17
| | | | | | | | | | | | | Fixes crash on MIPS (see original merge request https://qt.gitorious.org/qt/qt/merge_requests/1366). Reviewed-by: Olivier Goffart (cherry picked from commit 786b85b13bc884a8b7eab59c43d6c393863fc470) Change-Id: Ia7731d3d670c0c4dccab861e5085b03a6bf6f4f0 Reviewed-on: http://codereview.qt-project.org/4562 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Accessible Slider: Remove virtual children.Frederik Gladhorn2011-09-212-127/+3
| | | | | | | Change-Id: I58eca7d807b046b312117f9dbec6e2e36b5332cf Reviewed-on: http://codereview.qt-project.org/4820 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
* Export QTextImageHandler and add accessor for imageEskil Abrahamsen Blomfeldt2011-09-212-3/+11
| | | | | | | | | | | | | To allow optimizations in the scene graph, we export the private QTextImageHandler class and add a function which will fetch a given image when required, or return the cached image in the document resources. Task-number: QTBUG-20917 Change-Id: If45e51b0d9a267bc198623165e7a2cc1fb2b961f Reviewed-on: http://codereview.qt-project.org/5227 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
* testlib: Separate the gui- and widgets-specific apiKent Hansen2011-09-213-174/+159
| | | | | | | | | | | | Group the widgets-specific ("legacy") api under as few ifdefs as possible. (The diff can look confusing; rest assured that this change "only" moves entire functions around in the files.) Change-Id: I27bdec7d1c96d0b040dc22a8fed17e4e47766276 Reviewed-on: http://codereview.qt-project.org/5290 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Matthew Cattell <matthew.cattell@nokia.com>
* Fix QApplication::startDragDistance()Kevin Simons2011-09-211-1/+1
| | | | | | | Change-Id: I1b95e25892935b2b6287b8fed719479e37dbcad5 Reviewed-on: http://codereview.qt-project.org/5308 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* merge translate() overloadsOswald Buddenhagen2011-09-212-25/+5
| | | | | | | | Change-Id: I58f0d2c2ec6da751860a90096c49c662658643c1 Reviewed-on: http://codereview.qt-project.org/5164 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com> Reviewed-by: hjk <qthjk@ovi.com>
* Accessible Scrollbar: Remove virtual children, value interfaceFrederik Gladhorn2011-09-212-124/+2
| | | | | | | Change-Id: I3a8e74130eb79d289143cb7ac7b8c47cdd3db90c Reviewed-on: http://codereview.qt-project.org/4819 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
* Fixes to the Xdnd code in xcbLars Knoll2011-09-212-61/+63
| | | | | | | | | | Make sure we move the drag pixmap when required, and readd some commented out code from Qt 4.x. Change-Id: Ib4302b394f4ac7b966d0146267651b9c3860c62b Reviewed-on: http://codereview.qt-project.org/5262 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Fix support for drag pixmapsLars Knoll2011-09-212-53/+57
| | | | | | | | | | | Re-add the support for drag pixmaps to qdnd. Use the new WindowTransparentForMouseEvents flag for the window that shows the drag pixmap. Change-Id: I4b594085c161475988b9be0ffdc02c75fcc37f66 Reviewed-on: http://codereview.qt-project.org/5261 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Add Qt::WindowTransparentForMouseEventsLars Knoll2011-09-213-0/+43
| | | | | | | | | | | Add a flag for output only windows that are transparent for mouse events and implement it for the xcb backend. Change-Id: I24afdb6b27de34bcdf0c061a5a4987ac2880e4ae Reviewed-on: http://codereview.qt-project.org/5260 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Create the window when neededLars Knoll2011-09-211-1/+6
| | | | | | | | | | | We need to create the XWindow here to avoid crashes, when resizing the backing store before creating the window. Change-Id: Ib8d9efca3552e5a91f5f63a9262449080ae301e5 Reviewed-on: http://codereview.qt-project.org/5259 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Return the correct geometryLars Knoll2011-09-211-0/+2
| | | | | | | | | | | | | When the platform window is created, it is the authorative source for geometry information. It would however be better if we could completely avoid duplicated places for the geometry data. Change-Id: Id90b24b9c40acb57f3d11b8b927292c06bac335e Reviewed-on: http://codereview.qt-project.org/5258 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* CompileJan-Arve Saether2011-09-211-1/+2
| | | | | | | Change-Id: I27c2fabf1f4b0fdb9a1c3fd238b92f46a339a721 Reviewed-on: http://codereview.qt-project.org/5209 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Check argument count before accessing argument.Frederik Gladhorn2011-09-211-2/+2
| | | | | | | | | | | | | Also use QList::at instead of operator[]. Fixes: QTBUG-21403 Reviewed-by: Gabi (cherry picked from commit 6997b836f445908cf53c1c96a69e3eb7ba535706) Change-Id: I5d9de189e931b2b55fbd7baab0baad94adae352b Reviewed-on: http://codereview.qt-project.org/4782 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Gabriel de Dietrich <gabriel.dietrich-de@nokia.com>
* Remove testlib's dependency on gui and widgetsKent Hansen2011-09-211-1/+1
| | | | | | | | | | | | | | Commit 37d76a679878d7c07f8a2cb17f7bda46f6582572 made testlib depend on gui and widgets. It shouldn't. Changing the includes was enough. It's the application (e.g. autotest) that uses the gui/widgets features that should link against gui/widgets. Change-Id: If80d30a7eca2cac78cb5c6e5d29c82a06fb9f1dd Reviewed-on: http://codereview.qt-project.org/5095 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jo Asplin <jo.asplin@nokia.com> Reviewed-by: Matthew Cattell <matthew.cattell@nokia.com>
* testlib: Remove widgets dependency when only using guiKent Hansen2011-09-215-1/+53
| | | | | | | | | | | There's api in testlib that should only be available if the application links against widgets. Change-Id: I22e382c6710690866ed8ffed81bae27b548dc830 Reviewed-on: http://codereview.qt-project.org/5094 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jo Asplin <jo.asplin@nokia.com> Reviewed-by: Matthew Cattell <matthew.cattell@nokia.com>
* Implemented key filter support on platform input contextPekka Vuorela2011-09-203-3/+17
| | | | | | | | | | | As previously with QInputContext, now supporting filterEvent() interface. Usage only on XCB so far. Change-Id: I8e5972626552bda32318fe060017d0217bb79a94 Reviewed-on: http://codereview.qt-project.org/5240 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Cocoa: Adjust touch point rectangle by -0.5.Bjørn Erik Nilsen2011-09-201-1/+8
| | | | | | | | | | | The actual touch point is supposed to be in the center of the rectangle, and since the rectangle is 1x1 it means we have to subtract 0.5 from x and y. Change-Id: Ica4aba26dbe61328c8e7cbdcf8b02c96e2f41a40 Reviewed-on: http://codereview.qt-project.org/5256 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Bjørn Erik Nilsen <bjorn.nilsen@nokia.com>
* Cocoa: Update the geometry whenever the window moves.Bjørn Erik Nilsen2011-09-201-1/+10
| | | | | | | Change-Id: I3d47d62aaa0b4ccc88159ba9b6d1a3ebd42fedf5 Reviewed-on: http://codereview.qt-project.org/5255 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Bjørn Erik Nilsen <bjorn.nilsen@nokia.com>
* Cocoa: Add helper functions for NSPoint <-> QPoint(F) conversion.Bjørn Erik Nilsen2011-09-202-2/+19
| | | | | | | | | | ... and use [NSEvent mouseLocation] as global mouse position rather than relying on QCursor::pos() (which is buggy at the moment). Change-Id: Ieb8000089d0d824bed89abd8b2add9e28273f227 Reviewed-on: http://codereview.qt-project.org/5254 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Bjørn Erik Nilsen <bjorn.nilsen@nokia.com>