KWayland

datadevicemanager_interface.h
1 /*
2  SPDX-FileCopyrightText: 2014 Martin Gräßlin <[email protected]>
3 
4  SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
5 */
6 #ifndef WAYLAND_SERVER_DATA_DEVICE_MANAGER_INTERFACE_H
7 #define WAYLAND_SERVER_DATA_DEVICE_MANAGER_INTERFACE_H
8 
9 #include <QObject>
10 
11 #include "datadevice_interface.h"
12 #include "global.h"
13 #include <KWayland/Server/kwaylandserver_export.h>
14 
15 namespace KWayland
16 {
17 namespace Server
18 {
19 class Display;
20 class DataSourceInterface;
21 
22 /**
23  * @brief Represents the Global for wl_data_device_manager interface.
24  *
25  **/
26 class KWAYLANDSERVER_EXPORT DataDeviceManagerInterface : public Global
27 {
28  Q_OBJECT
29 public:
30  virtual ~DataDeviceManagerInterface();
31 
32  /**
33  * Drag and Drop actions supported by the DataSourceInterface.
34  * @since 5.XX
35  **/
36  enum class DnDAction {
37  None = 0,
38  Copy = 1 << 0,
39  Move = 1 << 1,
40  Ask = 1 << 2,
41  };
42  Q_DECLARE_FLAGS(DnDActions, DnDAction)
43 
44 Q_SIGNALS:
45  void dataSourceCreated(KWayland::Server::DataSourceInterface *);
46  void dataDeviceCreated(KWayland::Server::DataDeviceInterface *);
47 
48 private:
49  explicit DataDeviceManagerInterface(Display *display, QObject *parent = nullptr);
50  friend class Display;
51  class Private;
52 };
53 
54 Q_DECLARE_OPERATORS_FOR_FLAGS(DataDeviceManagerInterface::DnDActions)
55 
56 }
57 }
58 
59 #endif
DataDeviceInterface allows clients to share data by copy-and-paste and drag-and-drop.
Represents the Global for wl_data_device_manager interface.
Class holding the Wayland server display loop.
Definition: display.h:86
Base class for all Globals.
Definition: global.h:46
DnDAction
Drag and Drop actions supported by the DataSourceInterface.
Represents the Resource for the wl_data_source interface.
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Thu Sep 23 2021 22:51:07 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.