Commit Graph

931 Commits

Author SHA1 Message Date
Sergio Martins
65f74077d3 tests: Replace a usage of QWidgetOrQuick with View 2022-05-15 13:00:08 +01:00
Sergio Martins
383e4f8abd tests: Use tests_createView() instead of MyWidget2
Decouples tests from Qt a bit more
2022-05-15 12:20:30 +01:00
Sergio Martins
9698baefd0 tests: Remove unused HostedWidget 2022-05-15 12:20:30 +01:00
Sergio Martins
f719697852 Remove DockWidget::setWidget(QWidget) 2022-05-14 09:38:55 +01:00
Sergio Martins
df61c35314 Implemented ViewWrapper::sizePolicy() 2022-05-14 09:26:07 +01:00
Sergio Martins
f5fe7e6cc8 tests: Port away from QWidget further
DockWidget::widget() is getting removed in favor of guestView()
2022-05-11 23:51:57 +01:00
Sergio Martins
313be585ae tests: More focus tests 2022-05-11 17:23:31 +01:00
Sergio Martins
8a725298de Added View::hasFocus() 2022-05-11 00:02:18 +01:00
Sergio Martins
721402b710 Remove a few usages of DockWidget::widget()
Use View instead of QWidget
2022-05-10 23:43:07 +01:00
Sergio Martins
73e6822a1d Added View::focusPolicy() 2022-05-10 23:23:27 +01:00
Sergio Martins
9f7c4cb217 Removed the DockWidgetBase typedef
That existed only to ease porting
2022-05-10 22:53:16 +01:00
Sergio Martins
93e388e04f tests: tst_multisplitter is now run against all platforms 2022-05-09 17:38:22 +01:00
Sergio Martins
146b929b5d qtquick: Implement View::maximumSize() and test 2022-05-09 17:28:48 +01:00
Sergio Martins
9173226be7 tests: Normalise signature of argc/argv to match QApplication's
Fixes crash when passing "platform -xcb", because argc was being
passed by value, decremented in QApplication, then going out
of bounds in QTest
2022-05-09 15:16:36 +01:00
Sergio Martins
3c340aee40 tests: Remove last traces of QWidget from tst_multisplitter 2022-05-08 19:56:25 +01:00
Sergio Martins
2b2c5efd1a tests: Don't instance Separator_qtwidgets directly
So it can support qtquick
2022-05-08 19:50:15 +01:00
Sergio Martins
985224f24b tests: Run tst_view on offscreen by default
Moved the QPA offscreen defaulting to Platform_qt
2022-05-08 19:38:52 +01:00
Sergio Martins
97f26743e5 tests: Decouple tst_multisplitter from QWidget more
It now asks the platform to create a test view instead of
using one that inherits from QWidget.
2022-05-08 19:33:04 +01:00
Sergio Martins
a3bf159281 tests: Minor, add two QCOMPARE 2022-05-08 19:21:28 +01:00
Sergio Martins
8eba26fd53 tests: minor, add 2 QVERIFY 2022-05-08 19:09:39 +01:00
Sergio Martins
17b6b7f7b9 tests: minor, add a QCOMPARE for min position 2022-05-08 18:38:48 +01:00
Sergio Martins
7d27d76448 Port layoutInvalidated signal to KDBindings
This removes triplication between qtquick, qtwidgets and tests.
It also allows us to remove the usage of old-style Qt connect.
2022-05-08 15:23:40 +01:00
Sergio Martins
418c4514df tests: Remove some unneeded overridden methods in tst_multisplitter 2022-05-08 15:13:42 +01:00
Sergio Martins
0a1a783054 Implemented ViewWrapper::window()
Implementation was missing for qtquick and add a bug for qtwidgets.
2022-05-03 20:02:14 +01:00
Sergio Martins
dc9a0145e2 tests: Rename ViewWrapper tests, they still said "View::" 2022-05-03 19:46:30 +01:00
Sergio Martins
9f532fb543 qtquick: Implement ViewWrapper::minSize() 2022-05-02 23:40:14 +01:00
Sergio Martins
b719435ae8 qtquick: Implement ViewWrapper::objectName() 2022-05-02 23:27:09 +01:00
Sergio Martins
f8a287675b qtquick: Implement ViewWrapper::setParent and childViews 2022-05-02 23:10:00 +01:00
Sergio Martins
e462098cce tests: Move tst_view.cpp's main into a separate file, so it can be shared 2022-05-02 22:40:33 +01:00
Sergio Martins
3d2e45b5d5 tests: Add test for View::closeRequested 2022-05-02 22:00:15 +01:00
Sergio Martins
a6e698b0fe tests: Add a test for View::objectName 2022-05-02 17:23:39 +01:00
Sergio Martins
33d7d730f4 tests: Add a test for View::minSize() 2022-05-02 17:21:31 +01:00
Sergio Martins
5607fab8db tests: Add test for View::sizeHint 2022-05-02 10:29:46 +01:00
Sergio Martins
c2ae9abfb5 tests_createView() now receives a struct
As we'll be passing more parameters
2022-05-02 10:20:19 +01:00
Sergio Martins
3fabf34bee Renamed View::windowHandle() to View::window()
windowHandle() is missnamed in Qt because QWidget::window() was already
taken in Qt4. But we can make it better here.
2022-05-01 23:09:18 +01:00
Sergio Martins
0d02be6387 qtquick: Implement View::rootView() 2022-05-01 23:00:19 +01:00
Sergio Martins
fff3adf967 Rename View::window() to View::rootView()
window() was an artifact of Qt4 times, when QWindow didn't exist yet.
2022-05-01 22:52:00 +01:00
Sergio Martins
4b41291830 qtquick: Fix geometry() always returning 0,0 as position 2022-05-01 22:42:23 +01:00
Sergio Martins
8dd8eabf1a tests: tests_createView now can create visible views too 2022-05-01 22:21:08 +01:00
Sergio Martins
1591ed49da tests: Added tests for View::geometry,pos,x,y,width,height,rect 2022-05-01 21:15:27 +01:00
Sergio Martins
a069a812db tests: Remove qDebug() from doctest based tests
TestExplorer will fail to work if we print to stderr. Instead
we now print to stdout.
2022-05-01 20:17:51 +01:00
Sergio Martins
58afb97eb2 qtquick: Move the rest of old/QWidgetAdapter_quick to View_qtquick 2022-05-01 20:01:46 +01:00
Sergio Martins
738a78d12b qtquick: Implement View::windowHandle() and Window_qtquick::rootView()
For QtWidgets it now calls create() in the ctor so we have a window
during tests.
2022-05-01 14:38:20 +01:00
Sergio Martins
b089b49b28 qtquick: Implement and test View::hide() too 2022-04-30 11:47:02 +01:00
Sergio Martins
7547163d2d qtquick: Implement View::isVisible/setVisible 2022-04-30 11:42:53 +01:00
Sergio Martins
95f61629a9 tests: Print the name of the platform we're testing 2022-04-30 11:33:02 +01:00
Sergio Martins
3227ffab81 qtquick: Implemented and tested View::parentView/childViews
tst_view is now enabled for QtQuick too
2022-04-30 11:27:47 +01:00
Sergio Martins
1ecc42d50c tests: Fix memory leaks in tst_view 2022-04-30 11:19:12 +01:00
Sergio Martins
712751e89b tests: Make tst_view test View, not ViewWrapper 2022-04-30 11:08:54 +01:00
Sergio Martins
f3934ebd2c Rename View::isTopLevel() to isRootView() 2022-04-30 01:06:03 +01:00