diff options
author | Johan Klokkhammer Helsing <johan.helsing@qt.io> | 2018-02-19 15:28:01 +0100 |
---|---|---|
committer | Johan Helsing <johan.helsing@qt.io> | 2018-02-26 11:19:37 +0000 |
commit | 5b69d5f05fdf187ae8a5f08e9a57375cbbd7f142 (patch) | |
tree | 5db8f7de8dc1006b69bc387d6ec2a750f0343d01 /tests/auto/client/shared/mockcompositor.h | |
parent | ec495c98189f1d849e793108b09b5af0ce2c8984 (diff) |
Client tests: Use generated classes for mocking shells
Removes a lot of boiler-plate code and makes the two shells more similar. This
also makes it easier to extend the shells with additional mocking
functionality.
Change-Id: I4a846b06eeda695527d7c5679df339beae983af6
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Diffstat (limited to 'tests/auto/client/shared/mockcompositor.h')
-rw-r--r-- | tests/auto/client/shared/mockcompositor.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/auto/client/shared/mockcompositor.h b/tests/auto/client/shared/mockcompositor.h index d4cf5f367..747da38fa 100644 --- a/tests/auto/client/shared/mockcompositor.h +++ b/tests/auto/client/shared/mockcompositor.h @@ -52,6 +52,8 @@ class Seat; class DataDeviceManager; class Surface; class Output; +class WlShell; +class XdgShellV6; class Compositor { @@ -98,8 +100,6 @@ public: private: static void bindCompositor(wl_client *client, void *data, uint32_t version, uint32_t id); - static void bindShell(wl_client *client, void *data, uint32_t version, uint32_t id); - static void bindXdgShellV6(wl_client *client, void *compositorData, uint32_t version, uint32_t id); static Surface *resolveSurface(const QVariant &v); static Output *resolveOutput(const QVariant &v); @@ -121,6 +121,8 @@ private: QScopedPointer<DataDeviceManager> m_data_device_manager; QVector<Surface *> m_surfaces; QVector<Output *> m_outputs; + QScopedPointer<WlShell> m_wlShell; + QScopedPointer<XdgShellV6> m_xdgShellV6; }; void registerResource(wl_list *list, wl_resource *resource); |