void Compositor::bind_func(struct wl_client *client, void *data,
uint32_t version, uint32_t id)
{
+ Q_UNUSED(version);
wl_client_add_object(client,&wl_compositor_interface, &compositor_interface, id,data);
}
#if defined (QT_COMPOSITOR_WAYLAND_GL)
, m_graphics_hw_integration(0)
#endif
- , m_retainNotify(0)
, m_outputExtension(0)
, m_surfaceExtension(0)
, m_subSurfaceExtension(0)
+ , m_retainNotify(0)
{
compositor = this;
qDebug() << "Compositor instance is" << this;
wl_display_add_global(m_display->handle(), &wl_shell_interface, &m_shell, Shell::bind_func);
- m_shell = new Shell(this);
+ m_shell = new Shell();
m_outputExtension = new OutputExtensionGlobal(this);
m_surfaceExtension = new SurfaceExtensionGlobal(this);
void Compositor::overrideSelection(QMimeData *data)
{
+ Q_UNUSED(data);
// ### TODO implement
}
void Compositor::sendDragMoveEvent(const QPoint &global, const QPoint &local,
Surface *surface)
{
+ Q_UNUSED(global);
+ Q_UNUSED(local);
+ Q_UNUSED(surface);
// Drag::instance()->dragMove(global, local, surface);
}
namespace Wayland {
-Shell::Shell(Compositor *compositor)
+Shell::Shell()
{
}
}
+
void ShellSurface::move(struct wl_client *client,
struct wl_resource *shell_surface_resource,
struct wl_resource *input_device,
uint32_t edges)
{
Q_UNUSED(shell_surface_resource);
+ Q_UNUSED(client);
+ Q_UNUSED(time);
+ Q_UNUSED(edges);
ShellSurface *shell_surface = static_cast<ShellSurface *>(shell_surface_resource->data);
+ Q_UNUSED(shell_surface);
InputDevice *input_device = static_cast<InputDevice *>(input_device_super->data);
+ Q_UNUSED(input_device);
+
}
void ShellSurface::set_toplevel(struct wl_client *client,
Q_UNUSED(shell_surface_resource);
}
+void ShellSurface::set_popup(wl_client *client, wl_resource *resource, wl_resource *input_device, uint32_t time, wl_resource *parent, int32_t x, int32_t y, uint32_t flags)
+{
+ Q_UNUSED(client);
+ Q_UNUSED(resource);
+ Q_UNUSED(input_device);
+ Q_UNUSED(time);
+ Q_UNUSED(parent);
+ Q_UNUSED(x);
+ Q_UNUSED(y);
+ Q_UNUSED(flags);
+}
+
const struct wl_shell_surface_interface ShellSurface::shell_surface_interface = {
ShellSurface::move,
ShellSurface::resize,
ShellSurface::set_toplevel,
ShellSurface::set_transient,
- ShellSurface::set_fullscreen
+ ShellSurface::set_fullscreen,
+ ShellSurface::set_popup
+
};
}
class Shell
{
public:
- Shell(Compositor *compositor);
+ Shell();
static void bind_func(struct wl_client *client, void *data,
uint32_t version, uint32_t id);
Surface *m_surface;
static void move(struct wl_client *client,
- struct wl_resource *shell_surface_resource,
- struct wl_resource *input_device_super,
- uint32_t time);
+ struct wl_resource *shell_surface_resource,
+ struct wl_resource *input_device_super,
+ uint32_t time);
static void resize(struct wl_client *client,
- struct wl_resource *shell_surface_resource,
- struct wl_resource *input_device,
- uint32_t time,
- uint32_t edges);
+ struct wl_resource *shell_surface_resource,
+ struct wl_resource *input_device,
+ uint32_t time,
+ uint32_t edges);
static void set_toplevel(struct wl_client *client,
- struct wl_resource *shell_surface_resource);
+ struct wl_resource *shell_surface_resource);
static void set_transient(struct wl_client *client,
- struct wl_resource *shell_surface_resource,
+ struct wl_resource *shell_surface_resource,
+ struct wl_resource *parent,
+ int x,
+ int y,
+ uint32_t flags);
+ static void set_fullscreen(struct wl_client *client,
+ struct wl_resource *shell_surface_resource);
+ static void set_popup(struct wl_client *client,
+ struct wl_resource *resource,
+ struct wl_resource *input_device,
+ uint32_t time,
struct wl_resource *parent,
- int x,
- int y,
+ int32_t x,
+ int32_t y,
uint32_t flags);
- static void set_fullscreen(struct wl_client *client,
- struct wl_resource *shell_surface_resource);
static const struct wl_shell_surface_interface shell_surface_interface;