summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
...
* Fix helper function call in QWindowsVistaStyle::pixelMetric().Friedemann Kleint2014-10-221-1/+1
| | | | | | | | Task-number: QTBUG-41944 Task-number: QTBUG-40277 Change-Id: I1da9ffddce8edfcaa87d27058ed73ac7ec63d081 Reviewed-by: Adam Light <aclight@gmail.com> Reviewed-by: Alessandro Portale <alessandro.portale@digia.com>
* Windows: Implement Qt::WA_ShowWithoutActivating.Friedemann Kleint2014-10-222-3/+8
| | | | | | | | | | Set dynamic property for all platforms and query it in QWindowsWindow::show_sys(). Task-number: QTBUG-19194 Task-number: QTBUG-34504 Change-Id: I4199a2ed835d3de928405d470a81c54da93cc768 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* Fix height of combo popup when the list view has non-zero spacing.Friedemann Kleint2014-10-222-5/+23
| | | | | | | | | | | | QListView::spacing() is the space around the item (layout margin), so the effective spacing is twice as big. This differs conceptionally from QTableView, which has a spacing of 1 and a line on top/bottom. Split up QComboBoxPrivateContainer::spacing() into functions return spacing and top/bottom margins to reflect this. Task-number: QTBUG-37865 Change-Id: I1ff812e7856e00a53f1119ef3304956cbb7cbfca Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* eglfs: Do not flush input events when updating the cursorLaszlo Agocs2014-10-221-1/+1
| | | | | | | Task-number: QTBUG-42079 Change-Id: Ica806a090db74b4a1c34421334a28d7efd002b35 Reviewed-by: Jonathan Liu <net147@gmail.com> Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* QPA: Flush window system events with flags.Morten Johan Sørvig2014-10-224-10/+13
| | | | | | | | | | | Add a QEventLoop::ProcessEventsFlags argument to flushWindowSystemEvents(). This gives the platform plugins more control over which events to flush. Task-number: QTBUG-39842 Change-Id: Id9c01948b22e297b22503d38ec4e726f9f880fd5 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com> Reviewed-by: Jonathan Liu <net147@gmail.com>
* Correctly apply miter limits when stroking linesLars Knoll2014-10-211-0/+2
| | | | | | | | | | | The PDF generator was in many cases not correctly applying miter limits to the generated strokes leading to drawing artifacts for very sharp edges. Task-number: QTBUG-37903 Change-Id: Ie93b0f4a56775729105a375ba3bcdb5b58993433 Reviewed-by: Gunnar Sletta <gunnar@sletta.org> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Produce more correct clip path for QGraphicsShapeItemLars Knoll2014-10-211-1/+1
| | | | | | | | | | | If no pen is set on the item, we can completely ignore the pen for the creation of the items shape. This both speeds up the creation of the shape and applying it as a clip mask as well as creating more correct results. Task-number: QTBUG-32846 Change-Id: I5f6f690256c71309713d8f746e67599af3088dd7 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* OS X: Retina displays and blurry QToolButtonTimur Pocheptsov2014-10-211-0/+2
| | | | | | | | | | | | Checkable QToolButton has a special pixmap in the background, painted with a 'smooth pixmaps' hint. This hint also affects how an icon on a toolbutton itself is painted later. The difference can be quite visible on a Retina display, so this patch makes the toolbutton's image always look the same in checked/unchecked state. Task-number: QTBUG-35162 Change-Id: I2adc8006371fa10d89d4b77da6b3aa168aa5abc8 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* OS X - unified toolbar and AA_NativeWindowsTimur Pocheptsov2014-10-211-1/+17
| | | | | | | | | | | | | | | | | | | | In some cases QToolBar creates a child window (a child borderless NSWindow) placed on top of the toolbar's main window. As a result it's not possible to drag this main window using its toolbar - the window "jumps" on the screen. The reason is quite subtle - QNSView -handleMouseEvent: uses [NSEvent mouseLocation] and this location is invalid: - we have an NSWindow (parent) - we have a child NSWindow ([parent addChildWindow:child ....] - we handle drag event in a child window - we move a parent window as a result of drag event - Cocoa also moves a child window for us - when handling the next drag event, location [NSEvent mouseLocation] differs from the real event's location. Task-number: QTBUG-40106 Change-Id: Ic68cb92ab4233a1e0746b478820c1e33fd37a462 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* OS X - maximize app's window from the Dock or using cmd-tabTimur Pocheptsov2014-10-211-1/+1
| | | | | | | | | | | | | | | | | | | | On OS X it's possible to maximize app's window by clicking on an app's icon in the Dock. Another trick is to use cmd-tab to select an app +, while still holding the 'cmd' key, press the 'option' key - this should also maximize a window. None of these works at the moment, and to enable these features app delegate should return YES from the -applicationShouldHandleRepopen:hasVisibleWindows:. method. Task-number: QTBUG-40084 Change-Id: I33ba9e74d55d41d23deb429612519b746d461d9e Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Set correct transient parent in q_createNativeChildrenAndSetParent().Friedemann Kleint2014-10-211-5/+5
| | | | | | | | | | | Fix warning: void QWindow::setTransientParent(QWindow*) ... must be a top level window. which occurred for example when parenting a QMenu onto a native child widget. Task-number: QTBUG-41898 Change-Id: Icc25fb2108bd68b2d9c0e551949b90fc7a82d358 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Add better mobile connections to QtBearer NetworkManager backend.Lorn Potter2014-10-213-9/+142
| | | | | | | Task-number: QTBUG-41807 Change-Id: Ifb5904d4887111416b4bb1a32d6d056029186f5c Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
* update QtBearer NetworkManager backend APILorn Potter2014-10-215-85/+80
| | | | | | | Task-number: QTBUG-41747 Change-Id: Idb4afea0215b94957a11895c7db97a72ae680804 Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
* Fix ShortcutOverride for QtQuick on OSXJosh Faust2014-10-201-2/+10
| | | | | | | | | | tryShortcutOverride on OSX gets called via QWindowSystemInterface::tryHandleShortcutEvent. This change fixes that to use the QWindow's focus object. Task-number: QTBUG-32928 Change-Id: I51beb774e1fb91e0d8e2c12d087176d917357311 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
* logging: Fix qCleanupFuncinfo to not mangle Objective-C message namesTor Arne Vestbø2014-10-201-2/+3
| | | | | | Change-Id: I823566ba72668c611d225aa92c4d09a53cabe8fc Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com> Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Add a hint on application window positioning with QProcess::starthjk2014-10-201-0/+7
| | | | | | | | Task-number: QTBUG-30999 Change-Id: I65c80917c9bad067bb7d8e69e2431dd1c4886b08 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
* Doc: add info about letter spacing type to function descLeena Miettinen2014-10-201-1/+2
| | | | | | Task-number: QTBUG-41222 Change-Id: I18168dfa503feac07ee1b7bc349b9f14b7351518 Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
* Doc: removed unnecessary textLeena Miettinen2014-10-201-2/+2
| | | | | | | | | Added some commas. Task-number: QTBUG-41928 Change-Id: I52ad75f895f41b109f0496863930ffaa1650447c Reviewed-by: Martin Smith <martin.smith@digia.com> Reviewed-by: Nico Vertriest <nico.vertriest@digia.com>
* Always report focusObjectChanged on QWidget::clearFocus()Tor Arne Vestbø2014-10-201-4/+13
| | | | | | | | | | | | | The focusObject() of a QWidgetWindow is based on the focusWidget() of the top level widget of the window, which is resolved through the focus_child chain of the widget. This is not the same thing as the focusWidget of the application. The hasFocus() function of a QWidget queries the latter, so we can't put the focusObjectChanged signal inside hasFocus() when we unconditionally clear the focus_child chain (and hence the focusObject) earlier in the function. Change-Id: Iae39da5d6031d22b21e9dc9f18e5fe6e6fd11a5c Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
* Clear specific QWindow::focusObject() on QWindowPrivate::clearFocusObject()Tor Arne Vestbø2014-10-201-2/+4
| | | | | | | | | | The focusObject of a QWidgetWindow is the focusWidget() of the top level widget, so when clearing the focus object of the window we should clear focus of the same focusWidget, not the application-wide focus widget, which may live in another window. Change-Id: Ib9162418865c225e23aac7987e119b3b651983eb Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* iOS: Don't auto-activate popup windows unless they are standaloneTor Arne Vestbø2014-10-203-11/+28
| | | | | | | | | | | | We try to emulate a traditional window manager by activating windows on touch press (before delivering the event), and on showing/hiding windows, but this logic should not apply to popup windows (including tooltips and tool windows), as they are in most cases already active through their parent or transient parent, and should not steal keyboard focus and bring the virtual keyboard down. Change-Id: If10082bd48cdf1a9e1c41d8809066e86dafd7ffc Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
* iOS: Remove unused and duplicated functions from QIOSWindowTor Arne Vestbø2014-10-202-4/+1
| | | | | | Change-Id: I29a2345bddc9ec9577bdc398e4df9914406e5367 QIOSWindow::windowType() is the same as window()->type() Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
* iOS: Fade out statusbar when scrolling view due to VKBTor Arne Vestbø2014-10-203-41/+52
| | | | | Change-Id: I86923a2b2aa2d17d79ba3a11cabf37e615eaf4cc Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
* iOS: Move UIView helpers to once placeTor Arne Vestbø2014-10-202-6/+3
| | | | | Change-Id: I9e20d23ad813503ea5c6bef3303ebc0f6b9e99cd Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
* Remove old Trolltech feature string from QXmlSimpleReader docsAlex Blasche2014-10-201-17/+0
| | | | | | | | | This makes it even more unlikely that anybody uses them. Change-Id: I6b3a3902687a7fcde2d771617837f738001eeb0a Task-number: QTBUG-25023 Reviewed-by: Topi Reiniö <topi.reinio@digia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Android: deadlock avoidancePaul Olav Tvete2014-10-206-1/+125
| | | | | | | | | | | | | This change adds deadlock protection to all places where we lock one thread while waiting for the other to do something. If we detect that the other thread is going to block, we abort the operation. This could cause unexpected problems, such as painting errors, text input errors, or even crashes, but the alternative is a guaranteed deadlock. Task-number: QTBUG-41369 Change-Id: I2627a955cfafc4bce54eb9d0d38e19b768b06956 Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* Delay showing keyboard until application is activePaul Olav Tvete2014-10-202-0/+15
| | | | | | | | | | Android starts asking lots of questions when the software keyboard pops up, so let's wait until the application is initialized. This works around a deadlock on startup. Task-number: QTBUG-41369 Change-Id: I1c79e32d08c7cc11748ec55efbff3bc25e40f4b2 Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* Correct QPainter::clipPath() documentation.Mitch Curtis2014-10-201-2/+1
| | | | | Change-Id: Ie8ea01eee23e28378eadca0e87dc89fd62aec14f Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* Remove QOpenGLContextPrivate::globalShareContextJocelyn Turcotte2014-10-202-13/+0
| | | | | | | | This has previously been replaced with qt_gl_global_share_context and all using code has been ported to the new name at this point. Change-Id: I13832f583456891dd057a7b414f45ec3e83f5698 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Fix QOpenGLWindow tests when devicePixelRatio != 1Jørgen Lind2014-10-201-7/+10
| | | | | Change-Id: I83d71de8b9d735cd649a6c514e41a9ff23625005 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* QEasingCurve: fix mem leak in operator>>Marc Mutz2014-10-191-0/+2
| | | | | | | | | The code ignored that the QEasingCurve passed in to op>> might already have a QEasingCurveFunction set, overwriting it with a new pointer without deleting the old. Change-Id: Ic14cf7e4b97c7c8c7edb64cde08fbf22c07ac8f3 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* qdatetime.h: include correct headerMarc Mutz2014-10-191-1/+1
| | | | | | | QExplicitlySharedDataPointer is defined in qshareddata.h, not qsharedpointer.h. Change-Id: If81f6615681068a8e8c38817044ea3a0433c42ab Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Android: Update Ministro's requirements.BogDan Vatra2014-10-192-2/+2
| | | | | | Task-number: QTBUG-41968 Change-Id: Ia0c204dd87b9de3cbb7bb388099c435b855ad4d5 Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* Widgets: only update IM if the widget is the current focus objectRichard Moe Gustavsen2014-10-191-4/+6
| | | | | | | | | | | | | | | QInputMethod works on focusObject, not focusWidget. These two are not always the same, and sometimes the focusObject is also NULL. In either case, we should not tell QInputMethod to commit, reset or otherwise emit signals based on the internal state of widgets that are not the focus object. This led to a crash on iOS, since we got a call to cursorRectangleChanged when focus object was NULL, which the code didn't (and shouldn't need to) take into account. Change-Id: I54e40d7ec35210ba6599a78c5a8c7f982a1c3dbb Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* Add qHash(QSslError) overloadMarc Mutz2014-10-193-5/+15
| | | | | | | | | | | | | | | | qsslsocket_winrt.cpp defined it locally, which runs the risk of clashes with a potential user-defined qHash(QSslError), so make it public. Also included both .error() and .certificate() in the hash, as both of these are used to determine equality (the WinRT version only used .error()). [ChangeLog][QtNetwork][QSslError] Can now be used in QSet/QHash. Change-Id: Ieb7995bed491ff011d4be9dad544248b56fd4f73 Reviewed-by: Oliver Wolff <oliver.wolff@digia.com> Reviewed-by: Andrew Knight <andrew.knight@digia.com>
* Add qHash(QSslCertificate) overloadMarc Mutz2014-10-195-5/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | qsslsocket_winrt.cpp defined it locally, which runs the risk of clashes with a potential user-defined qHash(QSslCertificate), so make it public. Also, the implementation in qsslsocket_winrt.cpp simply hashed the handle(), which violates the principle that equal instances must hash to the same value. Also, for some platforms, the implementation returns nullptr unconditionally, which, while not violating the above-mentioned principle, will make all users of the hash have worst-case complexity. To calculate a meaningful hash, therefore, the certificate needs to be inspected deeper than just the handle. For OpenSSL, we use X509::sha1_hash, which also X509_cmp uses internally to determine inequality (it checks more stuff, but if X059::sha1_hash is different, X509_cmp() returns non-zero, which is sufficient for the purposes of qHash()). sha1_hash may not be up-to-date, though, so we call X509_cmp to make it valid. Ugh. For WinRT/Qt, we use the DER encoding, as that is the native storage format used in QSslCertificate. This is not equivalent to the implementation used in qsslsocket_winrt.cpp before, but since handle() == handle() => toDer() == toDer(), it should not be a problem. [ChangeLog][QtNetwork][QSslCertificate] Can now be used as a key in QSet/QHash. Change-Id: I10858fe648c70fc9535af6913dd3b7f3b2cf0eba Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* QSizePolicy: remind to mark as Q_PRIMITIVE_TYPE in Qt 6Marc Mutz2014-10-191-0/+4
| | | | | Change-Id: I1f18b4cd99f37aadf199e70d3acade9c8f5f9799 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* iOS: ensure we have a valid focusObject before sending it IM eventsRichard Moe Gustavsen2014-10-191-1/+1
| | | | | | | | | | | Should not really happen, but since we don't store the focus object given to us, we should do a check. A crash was seen from this when running the "Application" example for widgets. Change-Id: I9c4121766d7028a4eceede7d7b15c8c53d34e16e Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* iOS: ignore sender of actions for edit menuRichard Moe Gustavsen2014-10-191-1/+2
| | | | | | | | | The reason is that the sender is sometimes 'NULL', so we cannot rely on it. But the current test with our prefix should suffice. Change-Id: Ie58bf062cbade08feda622bda753d63e1d811a8d Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* CoreText font database: Use dynamic type on iOS to resolve theme fontsRichard Moe Gustavsen2014-10-191-5/+45
| | | | | | | | | Use Dynamic Type to resolve theme fonts, so that we get the correct font sizes and styling based on user preferences in Settings app. Change-Id: I2222199a5ba21badb2e3696993eee503e720c476 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* iOS: ensure edit menu works on iOS6Richard Moe Gustavsen2014-10-191-3/+8
| | | | | | | | | Method "- (id)targetForAction:(SEL)action withSender:(id)sender" is only available from iOS7. So change implementation to use whats available on iOS 6. Change-Id: I4e21495073364e83ef396dfab47a7ea2a23bbead Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* OS X: Emit QClipboard::dataChanged when activating applicationDyami Caliri2014-10-182-3/+21
| | | | | | | | | | The QClipboard documentation states that on OS X it will emit dataChanged() when activating the application, if the system clipboard had changed. It wasn't doing this in Qt5. Task-number: QTBUG-34941 Change-Id: I7f34e757876757691f0a6c94dd2ae76a60146291 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* Merge "Merge remote-tracking branch 'origin/5.3' into 5.4" into refs/staging/5.4Gabriel de Dietrich2014-10-186-22/+52
|\
| * Merge remote-tracking branch 'origin/5.3' into 5.4Frederik Gladhorn2014-10-146-22/+52
| |\ | | | | | | | | | Change-Id: Ic01820f2390e419a5b286643e7351e85ae032473
| | * Fix QtBearer connman backend report correctly on lte networkLorn Potter2014-10-131-1/+1
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-41813 Change-Id: I977facc2ee59571d24e60ac9d5d41e957403b344 Reviewed-by: Richard J. Moore <rich@kde.org>
| | * QMacStyle: Fix QPushButton with menu appearance on 10.10Gabriel de Dietrich2014-10-132-16/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As usual, this includes small and mini control sizes. Flat and oversized buttons will fall back to the HITheme rendering for now. Task-number: QTBUG-40833 Change-Id: I08d67c48b2e72681af4dc4a37ea498f7aac1dca0 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
| | * QAbstractItemView: fix CTRL+A select all behaviorMaximilian Hrabowski2014-10-131-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The check for Qt::Key_A to handle selectAll was changed to directly compare to QKeySequence::SelectAll as this will only match Ctrl. The former implementation also triggered when e.g. Shift was pressed. Added a check that selectAll is only called when selection is not disabled, i.e. selectionMode=NoSelection. Added a unit test for selectAll(). Task-number: QTBUG-26687 Change-Id: I721e7ab590b55d7d754b3b74ef01756fa5aa1315 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
| | * QMacStyle: save context state before changing to avoid crashDyami Caliri2014-10-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | qt_drawFocusRingOnPath was saving the graphics state after setting a new context. This leads to zombie NSBitmapGraphicsContext access with QFileDialog. Task-number: QTBUG-41879 Change-Id: I7fc7d959d2b0f01cb3491d639023083f1b46d175 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
| | * Initialize QFileSystemMetaData::size_ data memberGiuseppe D'Angelo2014-10-131-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There's a code path which reads that member before it got anything assigned to it, triggering undefined behavior. The code path goes as follows: 1. an instance is created in QFSFileEngineIterator::advance 2. the instance is passed to QFileSystemIterator::advance, which fills in only some members (not size_) 3. the instance is passed to QFileInfoPrivate which does a deep copy, reading an uninitialized size_ Change-Id: I6835ee701a83b63ca4bad6235feeb6a23566fcd3 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * XCB: silence warnings about possibly undefined shiftsGiuseppe D'Angelo2014-10-061-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The code shifts "1" by a uint32 number. If that number is >= 32, we're triggering undefined behavior, and Coverity rightfully complains about that. Add some asserts to silence those warnings. Change-Id: Ib91085a279b0a2b7ad37afad05ec1d764c0496b1 Reviewed-by: Uli Schlachter <psychon@znc.in> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>