aboutsummaryrefslogtreecommitdiffstats
path: root/src/quicktemplates2
Commit message (Collapse)AuthorAgeFilesLines
* RangeSlider: update GIFs and replace PNGs with themMitch Curtis2016-10-061-11/+0
| | | | | | Change-Id: Iafc4c1b088cfa51aee7bf1a91c165b74bf2da599 Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* ScrollBar: replace PNGs with GIFsMitch Curtis2016-10-061-2/+2
| | | | | | Change-Id: I0c0f23b88c0ce36d43bc31321371508ec63c2903 Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* QQuickAbstractButton: fix typo in apidocFrederik Schwarzer2016-10-041-1/+1
| | | | | | Change-Id: I14ed47112eac986c42ed571e1cbb4ca4782c4026 Reviewed-by: J-P Nurmi <jpnurmi@qt.io> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Menu: fix broken doc link to contentChildrenMitch Curtis2016-10-031-1/+1
| | | | | Change-Id: Idd00aa61fdec8153747387cb984b70595dae1b3f Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Doc: add a TabBar example with explicitly sized tabsJ-P Nurmi2016-10-031-3/+14
| | | | | | Task-number: QTBUG-55129 Change-Id: I0770996f741b431f9b003810df94fab8416b4cd3 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* StackView: allow loading remote URLsJ-P Nurmi2016-10-031-0/+10
| | | | | | Task-number: QTBUG-55749 Change-Id: I369e0113492547f312c8f1b540f5faa506a75a25 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* QQuickPopupPrivate: unbreak ubsan buildMarc Mutz2016-10-022-1/+6
| | | | | | | | | | | | | | The tst_drawer test uses members of the class, but it was not (autotest-) exported. That's no problem as long as the function called is inline, or a data member is accessed, but in a UBSan build, the typeid of a poly- morphic class is checked on each access, so the typeinfo object must be exported. Fix by autotest-exporting the class and defining the dtor out-of-line to pin the typeinfo and vtabe to a single TU. Change-Id: I1524e63a330dbdb0ae1ceb60263b589734bfd3aa Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Fix ComboBox to scroll to the highlighted itemJ-P Nurmi2016-10-021-4/+11
| | | | | | Change-Id: I57fefd8ba47796118e71902c6882e9918d462920 Tasl-number: QTBUG-55030 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Fix QQuickToolTip's delay and visibilityJ-P Nurmi2016-10-024-36/+23
| | | | | | | | | | | | | | | | | | | | The imperative open() and close() methods used to be the only ways to open and close popups, but the visible-property was later made writable to allow declarative visibility bindings. Since then, it is no longer sufficient for QQuickToolTip to overshadow open() and close() in QML, because setting the visible-property would bypass these overshadowed method. There was a bit of duplicate code between setVisible(), open(), and close(). This change moves the logic to one place by changing open() and close() to call setVisible(). Furthermore, setVisible() has been made virtual to make it possible for QQuickToolTip to apply its delay properly. QQuickToolTip needs to control the delay and timeout timers before the effective visibility is applied on the popup. Task-number: QTBUG-55572 Change-Id: I5a109157f9ec5d0db145e710426665a9a8d7e870 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Popup: don't steal focus on close from another opening popupJ-P Nurmi2016-10-021-6/+8
| | | | | | | | | In the Gallery example, the settings dialog does not get focus (or to be exact, loses it immediately), because the closing menu incorrectly transfers focus back to the tool button that opened the menu. Change-Id: I5328d8e825de9a977619688dc4478e6592db654f Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Fix QQuickControl::setFocusReason()J-P Nurmi2016-10-021-1/+1
| | | | | | | | | | | There is a little behavior change in focus handling in Qt Quick after qdeclarative commit e7da97b. The order of QQuickItem::focusOutEvent() and QQuickItem::ItemActiveFocusHasChanged have changed. Now we need to emit visualFocusChanged() in setFocusReason() when losing visual focus to ensure that bindigs to visualFocus get re-evaluated as appropriate. Change-Id: I52e728c7df751a54b36f353415b2666cfedc73ad Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Cancel exit transition when the same tooltip is shown againMitch Curtis2016-09-302-3/+6
| | | | | | | Task-number: QTBUG-54206 Task-number: QTBUG-54532 Change-Id: I7e4d993e3b1e30d7d7956629604f948dd1c85e32 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* CheckBox: add GIFs to documentationMitch Curtis2016-09-301-11/+6
| | | | | | | | | - Replace the state table in the detailed description with a GIF. - Add a GIF for the tri-state documentation. Change-Id: I00f3835edad6eb454d06847ab342ce0eeb30156b Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Button: add GIFs for flat & highlighted docsMitch Curtis2016-09-301-11/+4
| | | | | | | | | This also removes the state table in the detailed description, since we have GIFs now. Change-Id: I4503b67478051eb872f46127da6718092d77d4ff Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* TabBar: re-layout as appropriate in tab button size changesJ-P Nurmi2016-09-303-5/+19
| | | | | | | Auto-tested by the next change. Change-Id: I28ff7e82c0255b93d23cff7cbe111406d525f24b Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* TabBar: fix mixing of fixed and implicitly resized tabsJ-P Nurmi2016-09-301-5/+17
| | | | | | | | | | Don't calculate the implicit item width based on the total width of the whole control, but based on the available width that is left after subtracting the items that have an explicit width and won't be resized. Change-Id: Iae18dd9c9756b6f2afa143baab7d2501ce9d4697 Task-number: QTBUG-56265 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Fix crash when flicking a ListView-based TumblerMitch Curtis2016-09-301-4/+31
| | | | | | | | | | | | | | This only happens in 5.7, and seemingly only when the delegate uses attached properties (like displacement). Other fixes required and/or relevant to the patch: - Fixed some instances of displacementChanged possibly not being emitted. - Use QPointer for the attached object's Tumbler pointer, as it was being accessed while null after this patch. Change-Id: I7d881d815faf57f1a8bc0ea8e73a7331523d2f9b Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Don't execute disabled transitionsMarco Martin2016-09-281-1/+1
| | | | | | | | | | | | | If an enter or exit transition for a Drawer is disabled, don't execute it at all when the drawer gets opened or closed. This besides being more semantically correct, makes possible to control manually the opening of a Drawer, for instance to implement an external handle with which is possible to drag the drawer open or close. If a Transition is disabled, is up to the caller to set correctly the position value. Change-Id: I5a0d96e3b7c948725dff2068f9d0a7ab1d3847e9 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Fix QQuickToolTipAttached parentJ-P Nurmi2016-09-282-4/+4
| | | | | | | | The parent must not be a null item. Change-Id: Ide71a69e8cde8114542fa97570e0e5f5d724a884 Task-number: QTBUG-56243 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* SpinBox: don't call valueFromText when non-editableJ-P Nurmi2016-09-281-2/+2
| | | | | | | | | | If there are custom values like 00:00:00 for time and valueFromText is not implemented, tab navigation sets the value to 0, because the default implementation cannot evaluate it. Change-Id: I0384a2015b2c2a4dc2ee0e57f1ece410c339838e Task-number: QTBUG-56215 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Popup: fix some of the documentation review findingsMitch Curtis2016-09-271-7/+79
| | | | | | Change-Id: I69b60faab1588a45e005ba721c9796680bad6ac1 Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Fix a crash in StackView::pop()J-P Nurmi2016-09-262-36/+26
| | | | | | | | | | | | | | | | | If an item is still activating (from a previous pop) when it gets already popped out, we must not set the deactivating status before calling prepareTransition(). This method cancels and finishes the ongoing activation transition, and if the status says that the item was deactivating, the item gets destroyed in the middle of preparing for the deactivation transition. Let prepareTransition() cancel any ongoing transition first, and then set the status after the preparation. The cleanest way is to pass the target status to startTransition() and completeTransition(). Task-number: QTBUG-56158 Change-Id: Id52752200b650ea9f84659bbf43431f8a8b22f1e Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* PageIndicator: fix documentation review findingsMitch Curtis2016-09-231-1/+30
| | | | | | Change-Id: Ie684aeeeb5c9a57d8904e2526403aba1b85ce465 Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Pane: fix documentation review findingsMitch Curtis2016-09-231-12/+62
| | | | | | Change-Id: I59b40f68aa1f2985bfc15de26f587df6a88c09eb Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Fix nested popupsJ-P Nurmi2016-09-231-3/+13
| | | | | | Task-number: QTBUG-56136 Change-Id: I3ed7fae09c342c2c456b94fc0cfed781d8edf6aa Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Fix QQuickOverlay::childMouseEventFilter() to release the grabber popupJ-P Nurmi2016-09-231-0/+1
| | | | | | Change-Id: Id9d844d1fc75f4d254abaf1681747b7b521e881b Task-number: QTBUG-56131 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Drawer: allow interaction outside modal background dimmingJ-P Nurmi2016-09-231-2/+5
| | | | | | | | | If a drawer is positioned below a toolbar, for instance, it must be possible to interact with the buttons in the toolbar while the drawer is open (without the drawer closing due to the interaction). Change-Id: I5e07f66ad997ba6cf991a26fc6849ec51c9c0a22 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Control: add example snippets for background, contentItem and fontMitch Curtis2016-09-211-0/+41
| | | | | | Change-Id: I0968454452dcf17093ef27af8770fd5018780160 Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Page: fix documentation review findingsMitch Curtis2016-09-211-2/+45
| | | | | | Change-Id: Ia63c5d34ccb239fb45c7445a4354e6594bfce812 Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* MenuItem: fix documentation review findingsMitch Curtis2016-09-211-13/+22
| | | | | | Change-Id: Iff356498b438e0f4373efce0131634439b5e6240 Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Menu: fix documentation review findingsMitch Curtis2016-09-211-6/+36
| | | | | | Change-Id: I1ae17f1e6241b46b6d2f321451fd4fd017032486 Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* QQuickDrawer: allow resizing and positioningJ-P Nurmi2016-09-215-32/+131
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make QQuickDrawer re-use QQuickPopup's reposition() implementation. This way QQuickDrawer gains support for proper positioning and margins "for free". Now it is possible to place Drawer below the window header, for instance: import QtQuick 2.0 import QtQuick.Controls 2.0 ApplicationWindow { id: window visible: true header: ToolBar { } Drawer { y: header.height width: window.width * 0.6 height: window.height - header.height } } [ChangeLog][Controls][Drawer] Made it possible to control the vertical position of a horizontal drawer, and vice versa. This allows placing a drawer below a header/toolbar, for instance. Task-number: QTBUG-55360 Change-Id: I63621195efeefa2ea88935d676771b392e0a4030 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Drawer: reparent to the overlay by defaultJ-P Nurmi2016-09-211-0/+22
| | | | | | | | | | | | | | Drawer is a special type of popup that always resides at one of the window edges. Therefore it makes sense for drawers to operate on window coordinates. Re-parenting drawers to the window overlay achieves that. Now that the window overlay is guaranteed to always exist and the ApplicationWindow.overlay attached property works even with plain QML Window, we can reliably use it as a parent for Drawer. Task-number: QTBUG-53168 Change-Id: I37c727001350217ea1d2d9c52d73b4cae44d7c8d Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Make ApplicationWindow.overlay attached property work with QML WindowJ-P Nurmi2016-09-211-39/+49
| | | | | | | | | Since 14dd934c, we're using QQuickOverlay even with plain QML Window. Now that the overlay is guaranteed to always exist, we can make the attached property to give a reliable access to the overlay. Change-Id: I707fc52f6dfc7a0dbc9a3467646fb5feb36b9572 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Fix QQuickPopup::resetWidth/Height()J-P Nurmi2016-09-211-0/+10
| | | | | | | | | | When reseting the explicit size of a popup, the popup items geometry does not necessarily change. However, it affects the positioning of the popup whether it has explicit size or not. For that reason we must ensure that the popup gets repositioned as appropriate. Change-Id: I2dcd895eb7a1adc9c6a804bed4731edac1d550ec Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* QQuickPopup: fix negative marginsJ-P Nurmi2016-09-211-1/+4
| | | | | | | | | | | | | The documentation states: A popup with negative margins is not pushed within the bounds of the enclosing window. Therefore QQuickPopupPrivate::reposition() must not subtract negative margins to calculate the available bounds. Change-Id: I626772970bf3d5d9eefbb13811ea1003a85bcf0b Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Move resizeOverlay() to QQuickPopupPrivateJ-P Nurmi2016-09-214-13/+13
| | | | | | | | | | | | | | This is a preparation step for making drawers movable. Drawer must be later able to resize the overlay to fit the area of the window that is covered by the drawer. For example, if the Drawer is below the header, it can resize the overlay so that it won't be on top of the header. Change-Id: I2cfd025a31f3a517575f3dbf9b972dcd6957715c Task-number: QTBUG-53168 Task-number: QTBUG-55360 Task-number: QTBUG-53609 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Control: elaborate on the documentation for various propertiesMitch Curtis2016-09-201-6/+45
| | | | | | Change-Id: I48f1a9cf56e6b92ef34e954259e64d090bb445ca Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Control: explain diagram and make it a linkable sectionMitch Curtis2016-09-201-0/+22
| | | | | | Change-Id: I6e0d2349bdc909e61048356d76dc877e33fad5ff Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Control: link to "Control Layout" section in relevant placesMitch Curtis2016-09-201-7/+7
| | | | | | Change-Id: I82ec57bca3dffc19400f90eba13985df4be103de Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Switch/Delegate: improve dragging behaviorJ-P Nurmi2016-09-202-4/+20
| | | | | | | | | Don't start dragging the handle unless the initial press was at the indicator, or the drag has reached the indicator area. This prevents unnatural jumps when dragging far outside the indicator. Change-Id: I2b31b319a347ab489f2de5c044e42d908827b425 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* QQuickSwitchDelegate: make the handle draggableJ-P Nurmi2016-09-192-12/+52
| | | | | | | | | Sync the implementation with QQuickSwitch to make it behave exactly the same way. Change-Id: I59d08f68f87d8776e4012da880ac57a99950dfe8 Task-number: QTBUG-55686 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* QQuickSwitch: fix event handlingJ-P Nurmi2016-09-192-91/+38
| | | | | | | | | | | | Switch implemented custom event handling for the indicator, and used QQuickAbstractButton's event handling for the background. This lead to inconsistent signals depending on whether interacting with the handle or the background. This change gets rid of the child mouse event filter for the indicator and makes QQuickSwitch fully utilize the base class event handlers. Change-Id: I773e2eb939cbbf4bc9086cdf2b34e876597ea08e Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* QQuickSwitch: utilize checkStateSet()J-P Nurmi2016-09-192-8/+8
| | | | | | | | | | QQuickAbstractButton::checkStateSet() did not exist when QQuickSwitch was originally implemented. QQuickSwitch no longer has to establish a signal-slot connection, but can just override the virtual to update the position when the checked state changes. Change-Id: Ic18f13bcd7b0fe9fe657c41094b4d1db5cbb2e5a Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Fix Switch to stay pressed as appropriateJ-P Nurmi2016-09-193-3/+6
| | | | | | | | | | Switch is a special type of button that should stay pressed (similarly to Slider) even if the finger slips outside the bounds of the control. It was doing that only when dragged from the handle, not when dragged from the background. Change-Id: I462c66cfe2e67fc3c95215ffeafe3e5771174418 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Fix Popup to respect explicit sizeJ-P Nurmi2016-09-192-3/+11
| | | | | | | | | [ChangeLog][Controls][Popup] Fixed to respect explicitly set width and height. Task-number: QTBUG-56025 Change-Id: I7c8b0dcf59459a313c4c52eda44de45f1ab648ea Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Drawer: fix drag to close from the outside on touchJ-P Nurmi2016-09-191-1/+5
| | | | | | | | | | | | | | | Set mouseGrabberPopup in QQuickOverlay::childMouseEventFilter() the same way it is set in QQuickOverlay::mousePressEvent() to ensure that the consequent mouse move events are routed to the appropriate popup. This worked with "genuine" mouse move events that were caught by the same child mouse event filter and that way routed to the appropriate popup, but not with "synthesized" mouse move events that are caught by QQuickOverlay::mousePressEvent() instead. Change-Id: Ic59afd85e55c13ebec482bc4dc534accd1f92b2c Task-number: QTBUG-56010 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Dial: clarify the documentation for some propertiesMitch Curtis2016-09-191-2/+15
| | | | | | | | | | - Document the range of the angle property - Fix handle's property type - Explain stepSize more thoroughly Change-Id: I72ce8b493b3faf49d7f155ac802109bd9bdb4089 Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Container: rephrase paragraph about declaring childrenMitch Curtis2016-09-191-2/+4
| | | | | | | | The more common use case is static declaration of children. Change-Id: Ie1c7b44ae9e738e02f89957b27f6111a1e798736 Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Button: fix autoRepeat and checkable documentation review findingsMitch Curtis2016-09-191-2/+15
| | | | | | Change-Id: Ic8c90c284863077681ee1d143a366138cd550825 Task-number: QTBUG-55904 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>