summaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
...
| * TableView: correct event.accepted in key handlersLiang Qi2014-10-092-0/+124
| | | | | | | | | | | | | | | | Autotest is included. Task-number: QTBUG-41444 Change-Id: Ia3120b62a58361fbb13cd06e9c17b0e511cecace Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* | Fix SpinBox auto test - missing destroy()J-P Nurmi2015-01-061-0/+1
| | | | | | | | | | Change-Id: Ib48b36e7c655dd7fdf048b1eb608d105b834ff3f Reviewed-by: Caroline Chao <caroline.chao@theqtcompany.com>
* | Add autotest for baselinesJan Arve Saether2015-01-062-0/+112
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The heuristic of finding the visual baseline is based on analyzing the rendered pixmap. This is not pretty, but we really need to have a test for baselines in order to not cause future regressions whenever things are changed in the styles. This is the reason why we choose to use a string of 'L's, since the letter has a distinctive baseline. If it turns out that the heuristic gives too many false positives, this approach should be reconsidered. Change-Id: Ic8de576244fa032617ff7546ddbe20dc6910c7bf Reviewed-by: Caroline Chao <caroline.chao@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-10-098-1/+417
|\| | | | | | | Change-Id: Icc27c3f8638601b43daac37ce4a6d9678476996a
| * Controls: Fixed support for Keys attached property on TableViewLiang Qi2014-10-082-0/+91
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | By forwarding key events from the internal control. The key events from internal are Keys.forwardTo TableView, then user could customize their own behavior. Autotest are included. [ChangeLog][TableView] Fixed support for Keys attached property, by forwarding key events from the internal control. Change-Id: Ic59273ae2589bf6d1a0ccf5babf8fd1741376e6c Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
| * ApplicationWindow: top level items must get focus when they ask for it.Mitch Curtis2014-10-022-0/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, the following Item will not receive any key events: import QtQuick 2.2 import QtQuick.Controls 1.2 ApplicationWindow { visible: true width: 200 height: 200 Item { focus: true anchors.fill: parent Keys.onLeftPressed: textItem.text = "Left" Keys.onRightPressed: textItem.text = "Right" Keys.onPressed: { if (event.key === Qt.Key_Home) { textItem.text = "Home"; } else if (event.key === Qt.Key_End) { textItem.text = "End"; } } Text { id: textItem anchors.centerIn: parent } } } Using Window instead of ApplicationWindow does, however. ApplicationWindow can behave the same if we ensure that the panel has focus set to true. When the panel has focus, the contentItem can receive focus. [ChangeLog][ApplicationWindow] Top level items now receive focus when their focus property is set to true, in the same way that top level items of Window do. Change-Id: I16ef1632fc6df1989015e62e8683b6cd7c5be8a6 Reviewed-by: J-P Nurmi <jpnurmi@digia.com> Reviewed-by: Liang Qi <liang.qi@digia.com>
| * import tst_dialogs from qtdeclarativeJ-P Nurmi2014-09-224-1/+245
| | | | | | | | | | Change-Id: I3e3ee93de9f89aa2b674ac91f92aae93e3756167 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-09-1919-305/+295
|\| | | | | | | | | | | | | | | | | | | | | Conflicts: src/controls/Styles/iOS/ComboBoxStyle.qml src/controls/Styles/iOS/SpinBoxStyle.qml src/controls/Styles/iOS/TextAreaStyle.qml src/controls/Styles/iOS/TextFieldStyle.qml src/controls/Styles/iOS/iOS.pro Change-Id: Ib31ead16807a952a39aaa611b27ad89d4f86c60c
| * SpinBox: intermediate values outside the range are invalid.Mitch Curtis2014-09-191-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | When the maximumValue is 100 and the user enters 200, the input will be considered "Intermediate" by QQuickSpinBoxValidator and the value set to 20 when the input is confirmed. This is not how QSpinBox behaves; it prevents any more digits from being entered after the second one. Change-Id: I72490894d0073babda6ed00a0ba081a7ee686fe7 Task-number: QTBUG-40567 Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
| * Merge "Merge remote-tracking branch 'origin/5.3' into 5.4" into refs/staging/5.4Frederik Gladhorn2014-09-181-0/+29
| |\
| | * Merge remote-tracking branch 'origin/5.3' into 5.4Frederik Gladhorn2014-09-161-0/+29
| | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/controls/Styles/Base/ComboBoxStyle.qml Change-Id: Iaf45bc77be0bd80d21af49a5663dc9fba3caa0da
| | | * TableView: fix tab navigationJ-P Nurmi2014-09-101-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-41202 Change-Id: I13c420dd1443c152053ac331da7bfe5a9fbc9603 Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
| | | * tst_tableview: cleanup test items to avoid side effects in later testsJ-P Nurmi2014-09-101-0/+5
| | | | | | | | | | | | | | | | | | | | Change-Id: I2027a4576529accb623045d4ce63c76af723c5e9 Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
| * | | Remove sleep(4000) from SpinBox auto test.Mitch Curtis2014-09-171-1/+0
| |/ / | | | | | | | | | | | | | | | | | | | | | This slows down the test significantly, and judging from the lines above and below this one, it wasn't necessary. Change-Id: Iaef85b4940740193fb65e5fa4ce89f576d292bcb Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
| * | Do not crash when removing children from hidden layoutsJan Arve Saether2014-09-031-0/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The problem was that the proxy items (QQuickGridLayoutItem) that was added to the layout was not removed when a child item got deleted from a hidden layout. The proxy item therefore ended up having a dangling pointer to the deleted item. The solution is to also update the layout with a new list of items even when the layout is hidden. This will also fix a problem with that size hints was not correct when layouts were hidden. Note that the test included has an expected failure. This is because the case it tests is not very common and the problem is shared with positioners. The problem stems from the fact that a layouts implicit size should change when a child item is changed from implicitly hidden to explicitly hidden. Unfortuntately, QQuickItem does not notify about such changes. This is a problem independent of this crash patch fix, and I would like to address that in a separate commit. Change-Id: I67ac28b9d08208432559622c9cd412e24b197b32 Task-number: QTBUG-39045 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
| * | Update license headers and add new license filesAntti Kokko2014-08-2516-304/+176
| | | | | | | | | | | | | | | | | | | | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 & LICENSE.GPLv2 - Removed LICENSE.GPL Change-Id: I470909ba0980db33ab551790d619c59a35978590 Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
* | | Do not shrink application window height to 0Jan Arve Saether2014-08-281-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The binding was always evaluated to 0 if __noImplicitHeightGiven was true. The solution is to move the condition to the Binding element, which will then cause it to not be triggered when it was previously be evaluated to 0. Task-number: QTBUG-38469 Change-Id: I6ff80e44069978ee9685ea2fbe52afc52425cbdc Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com> Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
* | | Include potential toolBar+menuBar+statusBar when calculating heightJan Arve Saether2014-08-281-0/+32
| | | | | | | | | | | | | | | | | | Change-Id: Id005e81656f1fc2085360240bfd30342c0e7954b Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com> Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
* | | StackView itself should not anchor to parentJan Arve Saether2014-08-271-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | This should be up to the application developer to decide. Task-number: QTBUG-38469 Change-Id: I4da0ef0e9c7469c3451e64f9a53e1d1dfbb89b0e Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
* | | Children of ContentItem must be visible in order to be evaluated.Jan Arve Saether2014-08-271-0/+24
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-38469 Change-Id: Ie097c0b59f3453de63cc3c997773289fbafde48f Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
* | | QtQuick.Controls TextField: add remove() functionLiang Qi2014-08-231-0/+16
|/ / | | | | | | | | | | | | | | | | | | | | Autotest is included. [ChangeLog][QtQuick.Controls] TextField: add remove() function Task-number: QTBUG-40735 Change-Id: If73ec284da6d0306a7f01d001f2b762a9369f61d Reviewed-by: Mitch Curtis <mitch.curtis@digia.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Add scollBarPolicy properties to scrollviewDavid Edmundson2014-07-221-0/+36
| | | | | | | | | | | | | | | | This adds horizontal and vertical scrollbar policies allowing one to pernamently show or hide the scrollbars like in QAbstractScrollArea. Change-Id: I4989dbf2225ab34741b5a2811d7c6ff52880e0c3 Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
* | Merge remote-tracking branch 'origin/5.3' into devJ-P Nurmi2014-07-194-4/+4
|\| | | | | | | Change-Id: Icc15fe685e94dd043979b6b9c6a624f18f2d1e4c
| * Centralize determination of "no desktop" configurationsJ-P Nurmi2014-07-184-4/+4
| | | | | | | | | | | | Change-Id: I030012f48668db4f01737ef92fdb7e6e0426e025 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Liang Qi <liang.qi@digia.com>
* | ComboBox: add support for selection handlesJ-P Nurmi2014-07-181-0/+27
| | | | | | | | | | | | Task-number: QTBUG-38934 Change-Id: I0d7bfc821ff345e76d1ae89818f6a5e0120695f5 Reviewed-by: Liang Qi <liang.qi@digia.com>
* | SpinBox: add support for selection handlesJ-P Nurmi2014-07-181-0/+16
| | | | | | | | | | | | Task-number: QTBUG-38934 Change-Id: I8f23d20a24977f1787dcd451b48b22326959e3bc Reviewed-by: Liang Qi <liang.qi@digia.com>
* | Add styleData.hasSelection for text selection handlesJ-P Nurmi2014-07-181-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | Text selection handles typically look different based on whether the editor has selection or not (one handle for moving the cursor vs. two handles for selecting text). SpinBox and ComboBox do not have suitable properties for testing whether the control has selection or not, so styleData.hasSelection is introduced to abstract and expose that information. Task-number: QTBUG-38934 Change-Id: I362b5790f5d487e5ba258e42d1b801a5cce76770 Reviewed-by: Liang Qi <liang.qi@digia.com>
* | Fix Calendar::clicked() signal emissionJ-P Nurmi2014-07-161-1/+1
| | | | | | | | | | | | | | Emit only when releasing over the same date than was pressed. Change-Id: I7a8d4d6e3871231ae2589d565a75d9b641b649ac Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
* | Add Calendar::pressAndHold(date) signalJ-P Nurmi2014-07-161-0/+40
| | | | | | | | | | | | | | | | [ChangeLog][Calendar] Added pressAndHold(date) signal that is emitted when the user presses and holds a valid date. Change-Id: Ie880a3ed827332d35fabc76cd6a09eebc7685eb7 Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
* | Introduce TableView::pressAndHold(int row) [signal]J-P Nurmi2014-07-143-0/+18
| | | | | | | | | | | | | | | | [ChangeLog][TableView] Introduced a pressAndHold(int row) signal that is emitted when the user presses and holds a row. Change-Id: I823a7fd534fd6fca78831f00e7ecbb9f2118e006 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* | Merge remote-tracking branch 'origin/5.3' into devJ-P Nurmi2014-07-091-82/+86
|\| | | | | | | | | | | | | Conflicts: src/controls/ToolBar.qml Change-Id: I5510496219a4ebe8bfced4192307219238ca9bb6
| * Revise unstable and slow GridLayout auto testJ-P Nurmi2014-06-301-82/+86
| | | | | | | | | | | | | | | | - add missing destroy()'s - use tryCompare() instead of waitForRendering() Change-Id: I6dfbb9c55d3cb199d8351b83d67a6ef45890143b Reviewed-by: Caroline Chao <caroline.chao@digia.com>
* | texthandles test: add checkbox for disabling mouse selectionJ-P Nurmi2014-06-301-1/+9
| | | | | | | | | | Change-Id: I2888216918e89e0c0ba41aa3125cb57d76fd7827 Reviewed-by: Caroline Chao <caroline.chao@digia.com>
* | Merge remote-tracking branch 'origin/5.3' into devJ-P Nurmi2014-06-254-4/+4
|\| | | | | | | | | | | | | | | Conflicts: .qmake.conf src/controls/Styles/Desktop/SpinBoxStyle.qml Change-Id: Ia501c1388a2af9f273ec2742abbfc766717ad9e6
| * Cleanup whitespaceJ-P Nurmi2014-06-244-4/+4
| | | | | | | | | | Change-Id: I9e84ce56e853a18205aa180cef1ee8ff4f2f678c Reviewed-by: Caroline Chao <caroline.chao@digia.com>
| * Remove QtWidgets dependency for WinRTJ-P Nurmi2014-06-244-4/+4
| | | | | | | | | | Change-Id: Ifacceae8690d2ab4dfaed0d5439b9e29804c1943 Reviewed-by: Andrew Knight <andrew.knight@digia.com>
| * Remove Widgets dependency for QNXAndreas Holzammer2014-06-244-4/+4
| | | | | | | | | | | | | | | | | | Changes.txt says that with Qt 5.2.0 dependency for Widgets have been removed for touch based platforms. But QNX is also a touch based platform and its missing. Change-Id: I140842d4501422537175ac5acb07beebe994f0eb Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
* | TextField & TextArea: add support for selection handlesJ-P Nurmi2014-06-165-0/+250
| | | | | | | | | | | | | | Task-number: QTBUG-38934 Change-Id: Id581a6e56d3461b0df476c2b35c3e642fd505fc9 Reviewed-by: Caroline Chao <caroline.chao@digia.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* | Merge remote-tracking branch 'origin/5.3' into devJ-P Nurmi2014-06-111-1/+2
|\| | | | | | | Change-Id: I7ab0f7c218d462515c5aaaac3fbe3cd88d5cb5a5
| * CalendarStyle: do not hard code the height of dayOfWeekDelegateJ-P Nurmi2014-06-111-1/+2
| | | | | | | | | | | | Task-number: QTBUG-39482 Change-Id: I7b610a098402f5ec684fc0d7f9b47c4b9981e733 Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
* | Switch: add pressed-property and clicked() signalJ-P Nurmi2014-06-021-0/+30
| | | | | | | | | | | | | | | | Align with the basic functionality offered by CheckBox, and also required by certain styles. Change-Id: I53f2868f19a26e9abc0ed9c94d327edbe940429b Reviewed-by: Caroline Chao <caroline.chao@digia.com>
* | Fix Slider increments on keypressFrederik Gladhorn2014-05-261-3/+11
| | | | | | | | | | | | | | | | | | Instead of always adding/subtracting 1/10 of the range use the step size when the arrow keys are pressed. In addition add accessible actions to inc/dec the value. Task-number: QTBUG-39099 Change-Id: I4fdf2adc8912ab1fa8838be56af4e798eeb59781 Reviewed-by: Caroline Chao <caroline.chao@digia.com>
* | Merge remote-tracking branch 'origin/stable' into devJ-P Nurmi2014-05-146-22/+330
|\| | | | | | | | | | | | | | | Conflicts: .qmake.conf src/controls/Private/TabBar.qml Change-Id: Id176e44fe8e402c1c2c021ecb63c8c5c75736d47
| * Don't allow navigation to previous/next month when dragging mouse.Mitch Curtis2014-05-131-6/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When dragging the mouse over the calendar and a date from a previous month is hit, it will change the visible month to that month. This becomes worse when dragging the mouse between in the start/end of the calendar, because there are usually several days shown from the previous month, and the calendar quickly goes back several months. [ChangeLog][Calendar] Calendar no longer selects dates in the next/previous month when dragging the mouse. Task-number: QTBUG-38848 Change-Id: I0b9bc727a05397a8e4f1280e16c91e39e160bf4a Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
| * Fix CalendarStyle's layouting and grid cell calculation.Mitch Curtis2014-05-131-13/+74
| | | | | | | | | | | | | | | | | | | | | | | | - Wrap all panel items within a container, so that the frame width checks happen in only one place, and the other items don't need to care about it. - Move the logic involving grid line width into CalendarUtils, so that the style code can be for styling and not maths. Task-number: QTBUG-38847 Change-Id: I99a1f131b9cd608f3f7a7627d51a75780a6cbac2 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
| * Fix the update of TabView.currentIndex when inserting/removing tabsJocelyn Turcotte2014-05-071-0/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Update currentIndex when adding or inserting tabs. - Make sure that we update the current index before updating the array to avoid a state of currentIndex > count -1 when removing the last tab, where a property binding on TabView.count could try fetching a tab past the array limit through TabView.getTab. - Only decrease currentIndex when removedIndex <= currentIndex to keep the current tab active when possible. Activate the next tab instead of the previous one when the current tab is removed to make it more instinctive to remove multiple tabs successively. - Keep the current behavior of leaving currentIndex to 0 when removing the last tab. Change-Id: I030b86a03ce73f1177b1f04857abbdc2f7ec5835 Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
| * Tests: Remove insignificant marker for Win7 build with AngleCaroline Chao2014-04-291-2/+0
| | | | | | | | | | | | | | | | | | tst_controls is now passing for the Windows 7 32bit with Angle configuration. Task-number: QTBUG-33029 Change-Id: If0b47b827d97bb654a12bb8a2c9dc98d3b968988 Reviewed-by: Sergio Ahumada <sahumada@blackberry.com>
| * ComboBox: Update currentText when currentIndex goes from -1 to 0Gabriel de Dietrich2014-04-281-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | We need to help things a bit because the internal selectedText property won't change in that specific case. Task-number: QTBUG-38036 Change-Id: Id997da97a77faad8ffaad08e8b9c7614d8b6b7fc Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com> Reviewed-by: J-P Nurmi <jpnurmi@digia.com> Reviewed-by: Caroline Chao <caroline.chao@digia.com>
| * Merge "Merge remote-tracking branch 'origin/release' into stable" into ↵Jani Heikkinen2014-04-251-0/+18
| |\ | | | | | | | | | refs/staging/stable
| | * Merge remote-tracking branch 'origin/release' into stableJani Heikkinen2014-04-231-0/+18
| | |\ | | | | | | | | | | | | Change-Id: Idab72460ff342ce6df541559c2e853d7c837f595