Qt
6.x
The Qt SDK
Loading...
Searching...
No Matches
qwaylandbuffer.cpp
Go to the documentation of this file.
1
// Copyright (C) 2017 The Qt Company Ltd.
2
// Copyright (C) 2017 Giulio Camuffo.
3
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
4
5
#include "
qwaylandbuffer_p.h
"
6
7
#include <QDebug>
8
9
QT_BEGIN_NAMESPACE
10
11
namespace
QtWaylandClient
{
12
13
QWaylandBuffer::QWaylandBuffer
()
14
{
15
}
16
17
QWaylandBuffer::~QWaylandBuffer
()
18
{
19
if
(
mBuffer
)
20
wl_buffer_destroy(
mBuffer
);
21
}
22
23
void
QWaylandBuffer::init
(wl_buffer *
buf
)
24
{
25
mBuffer
=
buf
;
26
wl_buffer_add_listener(
buf
, &listener,
this
);
27
}
28
29
void
QWaylandBuffer::release(
void
*
data
, wl_buffer *)
30
{
31
QWaylandBuffer
*self =
static_cast<
QWaylandBuffer
*
>
(
data
);
32
self->mBusy =
false
;
33
self->mCommitted =
false
;
34
}
35
36
const
wl_buffer_listener QWaylandBuffer::listener = {
37
QWaylandBuffer::release
38
};
39
40
}
41
42
QT_END_NAMESPACE
QtWaylandClient::QWaylandBuffer
Definition
qwaylandbuffer_p.h:30
QtWaylandClient::QWaylandBuffer::mBuffer
struct wl_buffer * mBuffer
Definition
qwaylandbuffer_p.h:47
QtWaylandClient::QWaylandBuffer::init
void init(wl_buffer *buf)
Definition
qwaylandbuffer.cpp:23
QtWaylandClient::QWaylandBuffer::QWaylandBuffer
QWaylandBuffer()
Definition
qwaylandbuffer.cpp:13
QtWaylandClient::QWaylandBuffer::~QWaylandBuffer
virtual ~QWaylandBuffer()
Definition
qwaylandbuffer.cpp:17
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qstandardpaths_haiku.cpp:21
QT_END_NAMESPACE
Definition
qsharedpointer.cpp:1545
QtWaylandClient
Definition
qwaylandclientextension.h:15
buf
GLenum GLuint GLenum GLsizei const GLchar * buf
Definition
qopengles2ext.h:151
data
GLint GLsizei GLsizei GLenum GLenum GLsizei void * data
Definition
qopengles2ext.h:206
qwaylandbuffer_p.h
qtwayland
src
client
qwaylandbuffer.cpp
Generated by
1.9.7