Use Q_EMIT to make it compile against kf5.82

This commit is contained in:
Laurent Montel 2021-05-13 11:33:08 +02:00
parent d740a45469
commit 0c49d302ce
44 changed files with 258 additions and 258 deletions

View file

@ -46,7 +46,7 @@ void AppMenuManagerInterfacePrivate::org_kde_kwin_appmenu_manager_create(Resourc
QObject::connect(appmenu, &QObject::destroyed, q, [=]() {
appmenus.removeOne(appmenu);
});
emit q->appMenuCreated(appmenu);
Q_EMIT q->appMenuCreated(appmenu);
}
AppMenuManagerInterfacePrivate::AppMenuManagerInterfacePrivate(AppMenuManagerInterface *_q, Display *d)
@ -92,7 +92,7 @@ void AppMenuInterfacePrivate::org_kde_kwin_appmenu_set_address(Resource *resourc
address.serviceName = service_name;
address.objectPath = object_path;
emit q->addressChanged(address);
Q_EMIT q->addressChanged(address);
}
void AppMenuInterfacePrivate::org_kde_kwin_appmenu_release(QtWaylandServer::org_kde_kwin_appmenu::Resource *resource)

View file

@ -96,7 +96,7 @@ public:
AbstractDataSource(nullptr)
{}
~TestDataSource() {
emit aboutToBeDestroyed();
Q_EMIT aboutToBeDestroyed();
}
void requestData(const QString &mimeType, qint32 fd) override {
Q_UNUSED(mimeType);

View file

@ -47,12 +47,12 @@ public:
void zwp_keyboard_shortcuts_inhibitor_v1_active() override
{
emit inhibitorActive();
Q_EMIT inhibitorActive();
}
void zwp_keyboard_shortcuts_inhibitor_v1_inactive() override
{
emit inhibitorInactive();
Q_EMIT inhibitorInactive();
}
Q_SIGNALS:

View file

@ -41,10 +41,10 @@ Q_SIGNALS:
public:
~TextInputV3() override { destroy(); }
void zwp_text_input_v3_enter(struct ::wl_surface * surface) override {
emit surface_enter(surface);
Q_EMIT surface_enter(surface);
}
void zwp_text_input_v3_leave(struct ::wl_surface * surface) override {
emit surface_leave(surface);
Q_EMIT surface_leave(surface);
}
void zwp_text_input_v3_commit_string(const QString & text) override {
commitText = text;
@ -54,10 +54,10 @@ public:
after = after_length;
}
void zwp_text_input_v3_done(uint32_t serial) override {
emit commit_string(commitText);
emit preedit_string(preeditText, cursorBegin, cursorEnd);
emit delete_surrounding_text(before, after);
emit done(serial);
Q_EMIT commit_string(commitText);
Q_EMIT preedit_string(preeditText, cursorBegin, cursorEnd);
Q_EMIT delete_surrounding_text(before, after);
Q_EMIT done(serial);
}
void zwp_text_input_v3_preedit_string(const QString &text, int32_t cursor_begin, int32_t cursor_end) override {
preeditText = text;

View file

@ -68,10 +68,10 @@ void ClientConnectionPrivate::destroyListenerCallback(wl_listener *listener, voi
Q_ASSERT(it != s_allClients.constEnd());
auto p = (*it);
auto q = p->q;
emit q->aboutToBeDestroyed();
Q_EMIT q->aboutToBeDestroyed();
p->client = nullptr;
wl_list_remove(&p->listener.link);
emit q->disconnected(q);
Q_EMIT q->disconnected(q);
q->deleteLater();
}

View file

@ -44,7 +44,7 @@ void CompositorInterfacePrivate::compositor_create_surface(Resource *resource, u
wl_resource_post_no_memory(resource->handle);
return;
}
emit q->surfaceCreated(new SurfaceInterface(q, surfaceResource));
Q_EMIT q->surfaceCreated(new SurfaceInterface(q, surfaceResource));
}
void CompositorInterfacePrivate::compositor_create_region(Resource *resource, uint32_t id)

View file

@ -60,7 +60,7 @@ void DataControlDeviceV1InterfacePrivate::zwlr_data_control_device_v1_set_select
selection->cancel();
}
selection = dataSource;
emit q->selectionChanged(selection);
Q_EMIT q->selectionChanged(selection);
}
void DataControlDeviceV1InterfacePrivate::zwlr_data_control_device_v1_destroy(QtWaylandServer::zwlr_data_control_device_v1::Resource *resource)

View file

@ -44,7 +44,7 @@ void DataControlDeviceManagerV1InterfacePrivate::zwlr_data_control_manager_v1_cr
return;
}
DataControlSourceV1Interface *dataSource = new DataControlSourceV1Interface(q, data_source_resource);
emit q->dataSourceCreated(dataSource);
Q_EMIT q->dataSourceCreated(dataSource);
}
void DataControlDeviceManagerV1InterfacePrivate::zwlr_data_control_manager_v1_get_data_device(Resource *resource, uint32_t id, wl_resource *seat)
@ -61,7 +61,7 @@ void DataControlDeviceManagerV1InterfacePrivate::zwlr_data_control_manager_v1_ge
return;
}
DataControlDeviceV1Interface *dataDevice = new DataControlDeviceV1Interface(s, data_device_resource);
emit q->dataDeviceCreated(dataDevice);
Q_EMIT q->dataDeviceCreated(dataDevice);
}
void DataControlDeviceManagerV1InterfacePrivate::zwlr_data_control_manager_v1_destroy(QtWaylandServer::zwlr_data_control_manager_v1::Resource *resource)

View file

@ -40,14 +40,14 @@ DataControlSourceV1InterfacePrivate::DataControlSourceV1InterfacePrivate(DataCon
void DataControlSourceV1InterfacePrivate::zwlr_data_control_source_v1_destroy_resource(QtWaylandServer::zwlr_data_control_source_v1::Resource *resource)
{
Q_UNUSED(resource)
emit q->aboutToBeDestroyed();
Q_EMIT q->aboutToBeDestroyed();
delete q;
}
void DataControlSourceV1InterfacePrivate::zwlr_data_control_source_v1_offer(Resource *, const QString &mimeType)
{
mimeTypes << mimeType;
emit q->mimeTypeOffered(mimeType);
Q_EMIT q->mimeTypeOffered(mimeType);
}
void DataControlSourceV1InterfacePrivate::zwlr_data_control_source_v1_destroy(QtWaylandServer::zwlr_data_control_source_v1::Resource *resource)

View file

@ -119,7 +119,7 @@ void DataDeviceInterfacePrivate::data_device_start_drag(Resource *resource, wl_r
}
surface = focusSurface;
drag.serial = serial;
emit q->dragStarted();
Q_EMIT q->dragStarted();
}
void DataDeviceInterfacePrivate::data_device_set_selection(Resource *resource, wl_resource *source, uint32_t serial)
@ -141,9 +141,9 @@ void DataDeviceInterfacePrivate::data_device_set_selection(Resource *resource, w
}
selection = dataSource;
if (selection) {
emit q->selectionChanged(selection);
Q_EMIT q->selectionChanged(selection);
} else {
emit q->selectionCleared();
Q_EMIT q->selectionCleared();
}
}
@ -175,7 +175,7 @@ DataOfferInterface *DataDeviceInterfacePrivate::createDataOffer(AbstractDataSour
void DataDeviceInterfacePrivate::data_device_destroy_resource(QtWaylandServer::wl_data_device::Resource *resource)
{
Q_UNUSED(resource)
emit q->aboutToBeDestroyed();
Q_EMIT q->aboutToBeDestroyed();
delete q;
}

View file

@ -47,7 +47,7 @@ void DataDeviceManagerInterfacePrivate::data_device_manager_create_data_source(R
return;
}
DataSourceInterface *dataSource = new DataSourceInterface(q, data_source_resource);
emit q->dataSourceCreated(dataSource);
Q_EMIT q->dataSourceCreated(dataSource);
}
void DataDeviceManagerInterfacePrivate::data_device_manager_get_data_device(Resource *resource, uint32_t id, wl_resource *seat)
@ -64,7 +64,7 @@ void DataDeviceManagerInterfacePrivate::data_device_manager_get_data_device(Reso
return;
}
DataDeviceInterface *dataDevice = new DataDeviceInterface(s, data_device_resource);
emit q->dataDeviceCreated(dataDevice);
Q_EMIT q->dataDeviceCreated(dataDevice);
}
DataDeviceManagerInterface::DataDeviceManagerInterface(Display *display, QObject *parent)

View file

@ -123,7 +123,7 @@ void DataOfferInterfacePrivate::data_offer_set_actions(Resource *resource, uint3
supportedDnDActions = supportedActions;
preferredDnDAction = preferredAction;
emit q->dragAndDropActionsChanged();
Q_EMIT q->dragAndDropActionsChanged();
}
void DataOfferInterface::sendSourceActions()

View file

@ -47,7 +47,7 @@ DataSourceInterfacePrivate::DataSourceInterfacePrivate(DataSourceInterface *_q,
void DataSourceInterfacePrivate::data_source_destroy_resource(Resource *resource)
{
Q_UNUSED(resource)
emit q->aboutToBeDestroyed();
Q_EMIT q->aboutToBeDestroyed();
delete q;
}
@ -55,7 +55,7 @@ void DataSourceInterfacePrivate::data_source_offer(QtWaylandServer::wl_data_sour
{
Q_UNUSED(resource)
mimeTypes << mime_type;
emit q->mimeTypeOffered(mime_type);
Q_EMIT q->mimeTypeOffered(mime_type);
}
void DataSourceInterfacePrivate::data_source_destroy(QtWaylandServer::wl_data_source::Resource *resource)
@ -66,7 +66,7 @@ void DataSourceInterfacePrivate::data_source_destroy(QtWaylandServer::wl_data_so
void DataSourceInterfacePrivate::offer(const QString &mimeType)
{
mimeTypes << mimeType;
emit q->mimeTypeOffered(mimeType);
Q_EMIT q->mimeTypeOffered(mimeType);
}
void DataSourceInterfacePrivate::data_source_set_actions(Resource *resource, uint32_t dnd_actions)
@ -90,7 +90,7 @@ void DataSourceInterfacePrivate::data_source_set_actions(Resource *resource, uin
}
if (supportedDnDActions!= supportedActions) {
supportedDnDActions = supportedActions;
emit q->supportedDragAndDropActionsChanged();
Q_EMIT q->supportedDragAndDropActionsChanged();
}
}

View file

@ -28,7 +28,7 @@ DisplayPrivate::DisplayPrivate(Display *q)
void DisplayPrivate::registerSocketName(const QString &socketName)
{
socketNames.append(socketName);
emit q->socketNamesChanged();
Q_EMIT q->socketNamesChanged();
}
Display::Display(QObject *parent)
@ -97,7 +97,7 @@ bool Display::start()
connect(dispatcher, &QAbstractEventDispatcher::aboutToBlock, this, &Display::flush);
d->running = true;
emit runningChanged(true);
Q_EMIT runningChanged(true);
return true;
}
@ -180,10 +180,10 @@ ClientConnection *Display::getConnection(wl_client *client)
Q_ASSERT(index != -1);
d->clients.remove(index);
Q_ASSERT(d->clients.indexOf(c) == -1);
emit clientDisconnected(c);
Q_EMIT clientDisconnected(c);
}
);
emit clientConnected(c);
Q_EMIT clientConnected(c);
return c;
}

View file

@ -94,7 +94,7 @@ void DpmsInterface::org_kde_kwin_dpms_set(Resource *resource, uint32_t mode)
default:
return;
}
emit output->dpmsModeRequested(dpmsMode);
Q_EMIT output->dpmsModeRequested(dpmsMode);
}
void DpmsInterface::sendSupported()

View file

@ -67,7 +67,7 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_bind_resource(Resource *
FakeInputDevice *device = new FakeInputDevice(q, resource->handle);
devices << device;
QObject::connect(device, &FakeInputDevice::destroyed, q, [device, this] { devices.removeAll(device); });
emit q->deviceCreated(device);
Q_EMIT q->deviceCreated(device);
}
void FakeInputInterfacePrivate::org_kde_kwin_fake_input_destroy_resource(Resource *resource)
@ -92,7 +92,7 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_authenticate(Resource *r
if (!d) {
return;
}
emit d->authenticationRequested(application, reason);
Q_EMIT d->authenticationRequested(application, reason);
}
void FakeInputInterfacePrivate::org_kde_kwin_fake_input_pointer_motion(Resource *resource, wl_fixed_t delta_x, wl_fixed_t delta_y)
@ -101,7 +101,7 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_pointer_motion(Resource
if (!d || !d->isAuthenticated()) {
return;
}
emit d->pointerMotionRequested(QSizeF(wl_fixed_to_double(delta_x), wl_fixed_to_double(delta_y)));
Q_EMIT d->pointerMotionRequested(QSizeF(wl_fixed_to_double(delta_x), wl_fixed_to_double(delta_y)));
}
void FakeInputInterfacePrivate::org_kde_kwin_fake_input_button(Resource *resource, uint32_t button, uint32_t state)
@ -112,10 +112,10 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_button(Resource *resourc
}
switch (state) {
case WL_POINTER_BUTTON_STATE_PRESSED:
emit d->pointerButtonPressRequested(button);
Q_EMIT d->pointerButtonPressRequested(button);
break;
case WL_POINTER_BUTTON_STATE_RELEASED:
emit d->pointerButtonReleaseRequested(button);
Q_EMIT d->pointerButtonReleaseRequested(button);
break;
default:
// nothing
@ -140,7 +140,7 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_axis(Resource *resource,
// invalid
return;
}
emit d->pointerAxisRequested(orientation, wl_fixed_to_double(value));
Q_EMIT d->pointerAxisRequested(orientation, wl_fixed_to_double(value));
}
void FakeInputInterfacePrivate::org_kde_kwin_fake_input_touch_down(Resource *resource, uint32_t id, wl_fixed_t x, wl_fixed_t y)
@ -153,7 +153,7 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_touch_down(Resource *res
return;
}
touchIds << id;
emit d->touchDownRequested(id, QPointF(wl_fixed_to_double(x), wl_fixed_to_double(y)));
Q_EMIT d->touchDownRequested(id, QPointF(wl_fixed_to_double(x), wl_fixed_to_double(y)));
}
void FakeInputInterfacePrivate::org_kde_kwin_fake_input_touch_motion(Resource *resource, uint32_t id, wl_fixed_t x, wl_fixed_t y)
@ -165,7 +165,7 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_touch_motion(Resource *r
if (!touchIds.contains(id)) {
return;
}
emit d->touchMotionRequested(id, QPointF(wl_fixed_to_double(x), wl_fixed_to_double(y)));
Q_EMIT d->touchMotionRequested(id, QPointF(wl_fixed_to_double(x), wl_fixed_to_double(y)));
}
void FakeInputInterfacePrivate::org_kde_kwin_fake_input_touch_up(Resource *resource, uint32_t id)
@ -178,7 +178,7 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_touch_up(Resource *resou
return;
}
touchIds.removeOne(id);
emit d->touchUpRequested(id);
Q_EMIT d->touchUpRequested(id);
}
void FakeInputInterfacePrivate::org_kde_kwin_fake_input_touch_cancel(Resource *resource)
@ -188,7 +188,7 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_touch_cancel(Resource *r
return;
}
touchIds.clear();
emit d->touchCancelRequested();
Q_EMIT d->touchCancelRequested();
}
void FakeInputInterfacePrivate::org_kde_kwin_fake_input_touch_frame(Resource *resource)
@ -197,7 +197,7 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_touch_frame(Resource *re
if (!d || !d->isAuthenticated()) {
return;
}
emit d->touchFrameRequested();
Q_EMIT d->touchFrameRequested();
}
void FakeInputInterfacePrivate::org_kde_kwin_fake_input_pointer_motion_absolute(Resource *resource, wl_fixed_t x, wl_fixed_t y)
@ -206,7 +206,7 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_pointer_motion_absolute(
if (!d || !d->isAuthenticated()) {
return;
}
emit d->pointerMotionAbsoluteRequested(QPointF(wl_fixed_to_double(x), wl_fixed_to_double(y)));
Q_EMIT d->pointerMotionAbsoluteRequested(QPointF(wl_fixed_to_double(x), wl_fixed_to_double(y)));
}
void FakeInputInterfacePrivate::org_kde_kwin_fake_input_keyboard_key(Resource *resource, uint32_t button, uint32_t state)
@ -217,10 +217,10 @@ void FakeInputInterfacePrivate::org_kde_kwin_fake_input_keyboard_key(Resource *r
}
switch (state) {
case WL_KEYBOARD_KEY_STATE_PRESSED:
emit d->keyboardKeyPressRequested(button);
Q_EMIT d->keyboardKeyPressRequested(button);
break;
case WL_KEYBOARD_KEY_STATE_RELEASED:
emit d->keyboardKeyReleaseRequested(button);
Q_EMIT d->keyboardKeyReleaseRequested(button);
break;
default:
// nothing

View file

@ -50,7 +50,7 @@ void IdleInterface::inhibit()
{
d->inhibitCount++;
if (d->inhibitCount == 1) {
emit inhibitedChanged();
Q_EMIT inhibitedChanged();
}
}
@ -58,7 +58,7 @@ void IdleInterface::uninhibit()
{
d->inhibitCount--;
if (d->inhibitCount == 0) {
emit inhibitedChanged();
Q_EMIT inhibitedChanged();
}
}

View file

@ -126,7 +126,7 @@ void LayerShellV1InterfacePrivate::zwlr_layer_shell_v1_get_layer_surface(Resourc
auto layerSurface = new LayerSurfaceV1Interface(q, surface, output,
LayerSurfaceV1Interface::Layer(layer),
scope, layerSurfaceResource);
emit q->surfaceCreated(layerSurface);
Q_EMIT q->surfaceCreated(layerSurface);
}
void LayerShellV1InterfacePrivate::zwlr_layer_shell_v1_destroy(Resource *resource)
@ -160,7 +160,7 @@ LayerSurfaceV1InterfacePrivate::LayerSurfaceV1InterfacePrivate(LayerSurfaceV1Int
void LayerSurfaceV1InterfacePrivate::zwlr_layer_surface_v1_destroy_resource(Resource *resource)
{
Q_UNUSED(resource)
emit q->aboutToBeDestroyed();
Q_EMIT q->aboutToBeDestroyed();
delete q;
}
@ -241,7 +241,7 @@ void LayerSurfaceV1InterfacePrivate::zwlr_layer_surface_v1_ack_configure(Resourc
}
}
if (!isClosed) {
emit q->configureAcknowledged(serial);
Q_EMIT q->configureAcknowledged(serial);
}
}
@ -304,22 +304,22 @@ void LayerSurfaceV1InterfacePrivate::commit()
isCommitted = true; // Must set the committed state before emitting any signals.
if (previous.acceptsFocus != current.acceptsFocus) {
emit q->acceptsFocusChanged();
Q_EMIT q->acceptsFocusChanged();
}
if (previous.layer != current.layer) {
emit q->layerChanged();
Q_EMIT q->layerChanged();
}
if (previous.anchor != current.anchor) {
emit q->anchorChanged();
Q_EMIT q->anchorChanged();
}
if (previous.desiredSize != current.desiredSize) {
emit q->desiredSizeChanged();
Q_EMIT q->desiredSizeChanged();
}
if (previous.exclusiveZone != current.exclusiveZone) {
emit q->exclusiveZoneChanged();
Q_EMIT q->exclusiveZoneChanged();
}
if (previous.margins != current.margins) {
emit q->marginsChanged();
Q_EMIT q->marginsChanged();
}
}

View file

@ -160,7 +160,7 @@ void OutputInterfacePrivate::output_bind_resource(Resource *resource)
sendGeometry(resource);
sendDone(resource);
emit q->bound(display->getConnection(resource->client()), resource->handle);
Q_EMIT q->bound(display->getConnection(resource->client()), resource->handle);
}
OutputInterface::OutputInterface(Display *display, QObject *parent)
@ -188,7 +188,7 @@ void OutputInterface::remove()
}
d->globalRemove();
emit removed();
Q_EMIT removed();
}
QSize OutputInterface::pixelSize() const
@ -219,9 +219,9 @@ void OutputInterface::setMode(const Mode &mode)
d->sendMode(resource);
}
emit modeChanged();
emit refreshRateChanged(mode.refreshRate);
emit pixelSizeChanged(mode.size);
Q_EMIT modeChanged();
Q_EMIT refreshRateChanged(mode.refreshRate);
Q_EMIT pixelSizeChanged(mode.size);
}
void OutputInterface::setMode(const QSize &size, int refreshRate)
@ -241,7 +241,7 @@ void OutputInterface::setPhysicalSize(const QSize &physicalSize)
}
d->physicalSize = physicalSize;
d->broadcastGeometry();
emit physicalSizeChanged(d->physicalSize);
Q_EMIT physicalSizeChanged(d->physicalSize);
}
QPoint OutputInterface::globalPosition() const
@ -255,7 +255,7 @@ void OutputInterface::setGlobalPosition(const QPoint &globalPos)
return;
}
d->globalPosition = globalPos;
emit globalPositionChanged(d->globalPosition);
Q_EMIT globalPositionChanged(d->globalPosition);
}
QString OutputInterface::manufacturer() const
@ -270,7 +270,7 @@ void OutputInterface::setManufacturer(const QString &manufacturer)
}
d->manufacturer = manufacturer;
d->broadcastGeometry();
emit manufacturerChanged(d->manufacturer);
Q_EMIT manufacturerChanged(d->manufacturer);
}
QString OutputInterface::model() const
@ -285,7 +285,7 @@ void OutputInterface::setModel(const QString &model)
}
d->model = model;
d->broadcastGeometry();
emit modelChanged(d->model);
Q_EMIT modelChanged(d->model);
}
int OutputInterface::scale() const
@ -305,7 +305,7 @@ void OutputInterface::setScale(int scale)
d->sendScale(resource);
}
emit scaleChanged(d->scale);
Q_EMIT scaleChanged(d->scale);
}
OutputInterface::SubPixel OutputInterface::subPixel() const
@ -320,7 +320,7 @@ void OutputInterface::setSubPixel(SubPixel subPixel)
}
d->subPixel = subPixel;
d->broadcastGeometry();
emit subPixelChanged(d->subPixel);
Q_EMIT subPixelChanged(d->subPixel);
}
OutputInterface::Transform OutputInterface::transform() const
@ -335,7 +335,7 @@ void OutputInterface::setTransform(Transform transform)
}
d->transform = transform;
d->broadcastGeometry();
emit transformChanged(d->transform);
Q_EMIT transformChanged(d->transform);
}
void OutputInterface::setDpmsMode(OutputInterface::DpmsMode mode)
@ -344,7 +344,7 @@ void OutputInterface::setDpmsMode(OutputInterface::DpmsMode mode)
return;
}
d->dpms.mode = mode;
emit dpmsModeChanged();
Q_EMIT dpmsModeChanged();
}
void OutputInterface::setDpmsSupported(bool supported)
@ -353,7 +353,7 @@ void OutputInterface::setDpmsSupported(bool supported)
return;
}
d->dpms.supported = supported;
emit dpmsSupportedChanged();
Q_EMIT dpmsSupportedChanged();
}
OutputInterface::DpmsMode OutputInterface::dpmsMode() const

View file

@ -92,7 +92,7 @@ void PlasmaShellInterfacePrivate::org_kde_plasma_shell_get_surface(QtWaylandServ
s_shellSurfaces.removeOne(shellSurface);
});
emit q->surfaceCreated(shellSurface);
Q_EMIT q->surfaceCreated(shellSurface);
}
/*********************************
@ -143,7 +143,7 @@ void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_set_position(Res
}
m_positionSet = true;
m_globalPos = globalPos;
emit q->positionChanged();
Q_EMIT q->positionChanged();
}
void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_set_role(Resource *resource, uint32_t role)
@ -179,7 +179,7 @@ void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_set_role(Resourc
return;
}
m_role = r;
emit q->roleChanged();
Q_EMIT q->roleChanged();
}
void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_set_panel_behavior(Resource *resource, uint32_t flag)
@ -205,7 +205,7 @@ void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_set_panel_behavi
return;
}
m_panelBehavior = newBehavior;
emit q->panelBehaviorChanged();
Q_EMIT q->panelBehaviorChanged();
}
void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_set_skip_taskbar(Resource *resource, uint32_t skip)
@ -213,7 +213,7 @@ void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_set_skip_taskbar
Q_UNUSED(resource)
m_skipTaskbar = (bool)skip;
emit q->skipTaskbarChanged();
Q_EMIT q->skipTaskbarChanged();
}
void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_set_skip_switcher(Resource *resource, uint32_t skip)
@ -221,7 +221,7 @@ void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_set_skip_switche
Q_UNUSED(resource)
m_skipSwitcher = (bool)skip;
emit q->skipSwitcherChanged();
Q_EMIT q->skipSwitcherChanged();
}
void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_panel_auto_hide_hide(Resource *resource)
@ -230,7 +230,7 @@ void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_panel_auto_hide_
wl_resource_post_error(resource->handle, error_panel_not_auto_hide, "Not an auto hide panel");
return;
}
emit q->panelAutoHideHideRequested();
Q_EMIT q->panelAutoHideHideRequested();
}
void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_panel_auto_hide_show(Resource *resource)
@ -239,7 +239,7 @@ void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_panel_auto_hide_
wl_resource_post_error(resource->handle, error_panel_not_auto_hide, "Not an auto hide panel");
return;
}
emit q->panelAutoHideShowRequested();
Q_EMIT q->panelAutoHideShowRequested();
}
void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_set_panel_takes_focus(Resource *resource, uint32_t takesFocus)
@ -250,7 +250,7 @@ void PlasmaShellSurfaceInterfacePrivate::org_kde_plasma_surface_set_panel_takes_
return;
}
m_panelTakesFocus = takesFocus;
emit q->panelTakesFocusChanged();
Q_EMIT q->panelTakesFocusChanged();
}
QPoint PlasmaShellSurfaceInterface::position() const

View file

@ -84,13 +84,13 @@ void PlasmaVirtualDesktopManagementInterfacePrivate::org_kde_plasma_virtual_desk
void PlasmaVirtualDesktopManagementInterfacePrivate::org_kde_plasma_virtual_desktop_management_request_create_virtual_desktop(Resource *resource, const QString &name, uint32_t position)
{
Q_UNUSED(resource)
emit q->desktopCreateRequested(name, qBound<quint32>(0, position, (quint32)desktops.count()));
Q_EMIT q->desktopCreateRequested(name, qBound<quint32>(0, position, (quint32)desktops.count()));
}
void PlasmaVirtualDesktopManagementInterfacePrivate::org_kde_plasma_virtual_desktop_management_request_remove_virtual_desktop(Resource *resource, const QString &desktop_id)
{
Q_UNUSED(resource)
emit q->desktopRemoveRequested(desktop_id);
Q_EMIT q->desktopRemoveRequested(desktop_id);
}
PlasmaVirtualDesktopManagementInterfacePrivate::PlasmaVirtualDesktopManagementInterfacePrivate(PlasmaVirtualDesktopManagementInterface *_q, Display *display)
@ -221,7 +221,7 @@ void PlasmaVirtualDesktopManagementInterface::sendDone()
void PlasmaVirtualDesktopInterfacePrivate::org_kde_plasma_virtual_desktop_request_activate(Resource *resource)
{
Q_UNUSED(resource)
emit q->activateRequested();
Q_EMIT q->activateRequested();
}
PlasmaVirtualDesktopInterfacePrivate::PlasmaVirtualDesktopInterfacePrivate(PlasmaVirtualDesktopInterface *q, PlasmaVirtualDesktopManagementInterface *c)

View file

@ -210,7 +210,7 @@ void PlasmaWindowManagementInterfacePrivate::org_kde_plasma_window_management_sh
s = PlasmaWindowManagementInterface::ShowingDesktopState::Disabled;
break;
}
emit q->requestChangeShowingDesktop(s);
Q_EMIT q->requestChangeShowingDesktop(s);
}
void PlasmaWindowManagementInterfacePrivate::org_kde_plasma_window_management_get_window(Resource *resource, uint32_t id, uint32_t internal_window_id)
@ -454,31 +454,31 @@ void PlasmaWindowInterfacePrivate::org_kde_plasma_window_get_icon(Resource *reso
void PlasmaWindowInterfacePrivate::org_kde_plasma_window_request_enter_virtual_desktop(Resource *resource, const QString &id)
{
Q_UNUSED(resource)
emit q->enterPlasmaVirtualDesktopRequested(id);
Q_EMIT q->enterPlasmaVirtualDesktopRequested(id);
}
void PlasmaWindowInterfacePrivate::org_kde_plasma_window_request_enter_new_virtual_desktop(Resource *resource)
{
Q_UNUSED(resource)
emit q->enterNewPlasmaVirtualDesktopRequested();
Q_EMIT q->enterNewPlasmaVirtualDesktopRequested();
}
void PlasmaWindowInterfacePrivate::org_kde_plasma_window_request_leave_virtual_desktop(Resource *resource, const QString &id)
{
Q_UNUSED(resource)
emit q->leavePlasmaVirtualDesktopRequested(id);
Q_EMIT q->leavePlasmaVirtualDesktopRequested(id);
}
void PlasmaWindowInterfacePrivate::org_kde_plasma_window_request_enter_activity(Resource *resource, const QString &id)
{
Q_UNUSED(resource)
emit q->enterPlasmaActivityRequested(id);
Q_EMIT q->enterPlasmaActivityRequested(id);
}
void PlasmaWindowInterfacePrivate::org_kde_plasma_window_request_leave_activity(Resource *resource, const QString &id)
{
Q_UNUSED(resource)
emit q->leavePlasmaActivityRequested(id);
Q_EMIT q->leavePlasmaActivityRequested(id);
}
void PlasmaWindowInterfacePrivate::setTitle(const QString &title)
@ -619,83 +619,83 @@ void PlasmaWindowInterfacePrivate::setApplicationMenuPaths(const QString &servic
void PlasmaWindowInterfacePrivate::org_kde_plasma_window_close(Resource *resource)
{
Q_UNUSED(resource)
emit q->closeRequested();
Q_EMIT q->closeRequested();
}
void PlasmaWindowInterfacePrivate::org_kde_plasma_window_request_move(Resource *resource)
{
Q_UNUSED(resource)
emit q->moveRequested();
Q_EMIT q->moveRequested();
}
void PlasmaWindowInterfacePrivate::org_kde_plasma_window_request_resize(Resource *resource)
{
Q_UNUSED(resource)
emit q->resizeRequested();
Q_EMIT q->resizeRequested();
}
void PlasmaWindowInterfacePrivate::org_kde_plasma_window_set_virtual_desktop(Resource *resource, uint32_t number)
{
Q_UNUSED(resource)
emit q->virtualDesktopRequested(number);
Q_EMIT q->virtualDesktopRequested(number);
}
void PlasmaWindowInterfacePrivate::org_kde_plasma_window_set_state(Resource *resource, uint32_t flags, uint32_t state)
{
Q_UNUSED(resource)
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_ACTIVE) {
emit q->activeRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_ACTIVE);
Q_EMIT q->activeRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_ACTIVE);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MINIMIZED) {
emit q->minimizedRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MINIMIZED);
Q_EMIT q->minimizedRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MINIMIZED);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MAXIMIZED) {
emit q->maximizedRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MAXIMIZED);
Q_EMIT q->maximizedRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MAXIMIZED);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_FULLSCREEN) {
emit q->fullscreenRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_FULLSCREEN);
Q_EMIT q->fullscreenRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_FULLSCREEN);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_KEEP_ABOVE) {
emit q->keepAboveRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_KEEP_ABOVE);
Q_EMIT q->keepAboveRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_KEEP_ABOVE);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_KEEP_BELOW) {
emit q->keepBelowRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_KEEP_BELOW);
Q_EMIT q->keepBelowRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_KEEP_BELOW);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_DEMANDS_ATTENTION) {
emit q->demandsAttentionRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_DEMANDS_ATTENTION);
Q_EMIT q->demandsAttentionRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_DEMANDS_ATTENTION);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_CLOSEABLE) {
emit q->closeableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_CLOSEABLE);
Q_EMIT q->closeableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_CLOSEABLE);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MINIMIZABLE) {
emit q->minimizeableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MINIMIZABLE);
Q_EMIT q->minimizeableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MINIMIZABLE);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MAXIMIZABLE) {
emit q->maximizeableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MAXIMIZABLE);
Q_EMIT q->maximizeableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MAXIMIZABLE);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_FULLSCREENABLE) {
emit q->fullscreenableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_FULLSCREENABLE);
Q_EMIT q->fullscreenableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_FULLSCREENABLE);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SKIPTASKBAR) {
emit q->skipTaskbarRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SKIPTASKBAR);
Q_EMIT q->skipTaskbarRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SKIPTASKBAR);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SKIPSWITCHER) {
emit q->skipSwitcherRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SKIPSWITCHER);
Q_EMIT q->skipSwitcherRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SKIPSWITCHER);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SHADEABLE) {
emit q->shadeableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SHADEABLE);
Q_EMIT q->shadeableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SHADEABLE);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SHADED) {
emit q->shadedRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SHADED);
Q_EMIT q->shadedRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_SHADED);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MOVABLE) {
emit q->movableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MOVABLE);
Q_EMIT q->movableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_MOVABLE);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_RESIZABLE) {
emit q->resizableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_RESIZABLE);
Q_EMIT q->resizableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_RESIZABLE);
}
if (flags & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_VIRTUAL_DESKTOP_CHANGEABLE) {
emit q->virtualDesktopChangeableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_VIRTUAL_DESKTOP_CHANGEABLE);
Q_EMIT q->virtualDesktopChangeableRequested(state & ORG_KDE_PLASMA_WINDOW_MANAGEMENT_STATE_VIRTUAL_DESKTOP_CHANGEABLE);
}
}
@ -713,10 +713,10 @@ void PlasmaWindowInterfacePrivate::org_kde_plasma_window_set_minimized_geometry(
}
minimizedGeometries[panelSurface] = QRect(x, y, width, height);
emit q->minimizedGeometriesChanged();
Q_EMIT q->minimizedGeometriesChanged();
QObject::connect(panelSurface, &QObject::destroyed, q, [this, panelSurface] () {
if (minimizedGeometries.remove(panelSurface)) {
emit q->minimizedGeometriesChanged();
Q_EMIT q->minimizedGeometriesChanged();
}
});
}
@ -733,7 +733,7 @@ void PlasmaWindowInterfacePrivate::org_kde_plasma_window_unset_minimized_geometr
return;
}
minimizedGeometries.remove(panelSurface);
emit q->minimizedGeometriesChanged();
Q_EMIT q->minimizedGeometriesChanged();
}
PlasmaWindowInterface::PlasmaWindowInterface(PlasmaWindowManagementInterface *wm, QObject *parent)

View file

@ -93,7 +93,7 @@ void PointerInterfacePrivate::pointer_set_cursor(Resource *resource, uint32_t se
cursor = new Cursor(q);
cursor->d->update(surface, serial, QPoint(hotspot_x, hotspot_y));
QObject::connect(cursor, &Cursor::changed, q, &PointerInterface::cursorChanged);
emit q->cursorChanged();
Q_EMIT q->cursorChanged();
} else {
cursor->d->update(surface, serial, QPoint(hotspot_x, hotspot_y));
}
@ -180,14 +180,14 @@ void PointerInterface::setFocusedSurface(SurfaceInterface *surface, const QPoint
d->sendLeave(d->seat->display()->nextSerial());
d->sendFrame();
d->focusedSurface = nullptr;
emit focusedSurfaceChanged();
Q_EMIT focusedSurfaceChanged();
});
d->sendEnter(position, serial);
d->sendFrame();
d->lastPosition = position;
}
emit focusedSurfaceChanged();
Q_EMIT focusedSurfaceChanged();
}
void PointerInterface::sendButton(quint32 button, PointerButtonState state, quint32 serial)
@ -301,12 +301,12 @@ void CursorPrivate::update(SurfaceInterface *s, quint32 serial, const QPoint &p)
if (enteredSerial != serial) {
enteredSerial = serial;
emitChanged = true;
emit q->enteredSerialChanged();
Q_EMIT q->enteredSerialChanged();
}
if (hotspot != p) {
hotspot = p;
emitChanged = true;
emit q->hotspotChanged();
Q_EMIT q->hotspotChanged();
}
if (surface != s) {
if (!surface.isNull()) {
@ -317,10 +317,10 @@ void CursorPrivate::update(SurfaceInterface *s, quint32 serial, const QPoint &p)
QObject::connect(surface.data(), &SurfaceInterface::damaged, q, &Cursor::changed);
}
emitChanged = true;
emit q->surfaceChanged();
Q_EMIT q->surfaceChanged();
}
if (emitChanged) {
emit q->changed();
Q_EMIT q->changed();
}
}

View file

@ -160,19 +160,19 @@ void LockedPointerV1InterfacePrivate::commit()
if (hasPendingRegion) {
region = pendingRegion;
hasPendingRegion = false;
emit q->regionChanged();
Q_EMIT q->regionChanged();
}
if (hasPendingHint) {
hint = pendingHint;
hasPendingHint = false;
emit q->cursorPositionHintChanged();
Q_EMIT q->cursorPositionHintChanged();
}
}
void LockedPointerV1InterfacePrivate::zwp_locked_pointer_v1_destroy_resource(Resource *resource)
{
Q_UNUSED(resource)
emit q->aboutToBeDestroyed();
Q_EMIT q->aboutToBeDestroyed();
delete q;
}
@ -242,7 +242,7 @@ void LockedPointerV1Interface::setLocked(bool locked)
} else {
d->send_unlocked();
}
emit lockedChanged();
Q_EMIT lockedChanged();
}
ConfinedPointerV1InterfacePrivate *ConfinedPointerV1InterfacePrivate::get(ConfinedPointerV1Interface *q)
@ -266,7 +266,7 @@ void ConfinedPointerV1InterfacePrivate::commit()
if (hasPendingRegion) {
region = pendingRegion;
hasPendingRegion = false;
emit q->regionChanged();
Q_EMIT q->regionChanged();
}
}
@ -325,7 +325,7 @@ void ConfinedPointerV1Interface::setConfined(bool confined)
} else {
d->send_unconfined();
}
emit confinedChanged();
Q_EMIT confinedChanged();
}
} // namespace KWaylandServer

View file

@ -54,7 +54,7 @@ private:
* and that the pointer is inside the {@link LockedPointerV1Interface::region} when
* it activates the lock.
*
* While the lock is active the PointerInterface does no longer emit pointer motion
* While the lock is active the PointerInterface does no longer Q_EMIT pointer motion
* events, but still emits relative pointer motion events.
*/
class KWAYLANDSERVER_EXPORT LockedPointerV1Interface : public QObject
@ -87,7 +87,7 @@ public:
/**
* Indicates where the mouse cursor should be positioned after it has been unlocked again.
* The compositor can warp the cursor at this moment to the position. For that it
* will not emit any relative motion events. The hint is relative to the top-left
* will not Q_EMIT any relative motion events. The hint is relative to the top-left
* corner of the surface the lock was applied to. Only non-negative x and y values
* are allowed. Otherwise the hint is invalid and should be ignored by the compositor.
*

View file

@ -64,7 +64,7 @@ void PrimarySelectionDeviceV1InterfacePrivate::zwp_primary_selection_device_v1_s
}
selection = dataSource;
if (selection) {
emit q->selectionChanged(selection);
Q_EMIT q->selectionChanged(selection);
}
}

View file

@ -42,7 +42,7 @@ void PrimarySelectionDeviceManagerV1InterfacePrivate::zwp_primary_selection_devi
return;
}
PrimarySelectionSourceV1Interface *dataSource = new PrimarySelectionSourceV1Interface(q, data_source_resource);
emit q->dataSourceCreated(dataSource);
Q_EMIT q->dataSourceCreated(dataSource);
}
void PrimarySelectionDeviceManagerV1InterfacePrivate::zwp_primary_selection_device_manager_v1_get_device(Resource *resource, uint32_t id, wl_resource *seat)
@ -59,7 +59,7 @@ void PrimarySelectionDeviceManagerV1InterfacePrivate::zwp_primary_selection_devi
return;
}
PrimarySelectionDeviceV1Interface *dataDevice = new PrimarySelectionDeviceV1Interface(s, data_device_resource);
emit q->dataDeviceCreated(dataDevice);
Q_EMIT q->dataDeviceCreated(dataDevice);
}
void PrimarySelectionDeviceManagerV1InterfacePrivate::zwp_primary_selection_device_manager_v1_destroy(Resource *resource)

View file

@ -39,14 +39,14 @@ PrimarySelectionSourceV1InterfacePrivate::PrimarySelectionSourceV1InterfacePriva
void PrimarySelectionSourceV1InterfacePrivate::zwp_primary_selection_source_v1_destroy_resource(QtWaylandServer::zwp_primary_selection_source_v1::Resource *resource)
{
Q_UNUSED(resource)
emit q->aboutToBeDestroyed();
Q_EMIT q->aboutToBeDestroyed();
delete q;
}
void PrimarySelectionSourceV1InterfacePrivate::zwp_primary_selection_source_v1_offer(Resource *, const QString &mimeType)
{
mimeTypes << mimeType;
emit q->mimeTypeOffered(mimeType);
Q_EMIT q->mimeTypeOffered(mimeType);
}
void PrimarySelectionSourceV1InterfacePrivate::zwp_primary_selection_source_v1_destroy(QtWaylandServer::zwp_primary_selection_source_v1::Resource *resource)

View file

@ -214,8 +214,8 @@ void SeatInterfacePrivate::registerDataDevice(DataDeviceInterface *dataDevice)
drag.dragSourceDestroyConnection = QMetaObject::Connection();
}
dataDevice->updateDragTarget(proxied ? nullptr : originSurface, dataDevice->dragImplicitGrabSerial());
emit q->dragStarted();
emit q->dragSurfaceChanged();
Q_EMIT q->dragStarted();
Q_EMIT q->dragSurfaceChanged();
}
);
// is the new DataDevice for the current keyoard focus?
@ -335,8 +335,8 @@ void SeatInterfacePrivate::endDrag(quint32 serial)
}
drag = Drag();
emit q->dragSurfaceChanged();
emit q->dragEnded();
Q_EMIT q->dragSurfaceChanged();
Q_EMIT q->dragEnded();
}
void SeatInterfacePrivate::updateSelection(DataDeviceInterface *dataDevice)
@ -380,7 +380,7 @@ void SeatInterface::setHasKeyboard(bool has)
d->accumulatedCapabilities |= d->capabilities;
d->sendCapabilities();
emit hasKeyboardChanged(d->keyboard);
Q_EMIT hasKeyboardChanged(d->keyboard);
}
void SeatInterface::setHasPointer(bool has)
@ -398,7 +398,7 @@ void SeatInterface::setHasPointer(bool has)
d->accumulatedCapabilities |= d->capabilities;
d->sendCapabilities();
emit hasPointerChanged(d->pointer);
Q_EMIT hasPointerChanged(d->pointer);
}
void SeatInterface::setHasTouch(bool has)
@ -416,7 +416,7 @@ void SeatInterface::setHasTouch(bool has)
d->accumulatedCapabilities |= d->capabilities;
d->sendCapabilities();
emit hasTouchChanged(d->touch);
Q_EMIT hasTouchChanged(d->touch);
}
void SeatInterface::setName(const QString &name)
@ -433,7 +433,7 @@ void SeatInterface::setName(const QString &name)
}
}
emit nameChanged(d->name);
Q_EMIT nameChanged(d->name);
}
QString SeatInterface::name() const
@ -483,7 +483,7 @@ void SeatInterface::notifyPointerMotion(const QPointF &pos)
return;
}
d->globalPointer.pos = pos;
emit pointerPosChanged(pos);
Q_EMIT pointerPosChanged(pos);
SurfaceInterface *focusedSurface = focusedPointerSurface();
if (!focusedSurface) {
@ -528,7 +528,7 @@ void SeatInterface::setTimestamp(quint32 time)
return;
}
d->timestamp = time;
emit timestampChanged(time);
Q_EMIT timestampChanged(time);
}
void SeatInterface::setDragTarget(SurfaceInterface *surface, const QPointF &globalPosition, const QMatrix4x4 &inputTransformation)
@ -565,7 +565,7 @@ void SeatInterface::setDragTarget(SurfaceInterface *surface, const QPointF &glob
} else {
d->drag.surface = nullptr;
}
emit dragSurfaceChanged();
Q_EMIT dragSurfaceChanged();
return;
}
@ -1103,7 +1103,7 @@ void SeatInterface::notifyTouchMotion(qint32 id, const QPointF &globalPosition)
}
}
}
emit touchMoved(id, d->globalTouch.ids[id], globalPosition);
Q_EMIT touchMoved(id, d->globalTouch.ids[id], globalPosition);
}
void SeatInterface::notifyTouchUp(qint32 id)
@ -1205,7 +1205,7 @@ void SeatInterface::setFocusedTextInputSurface(SurfaceInterface *surface)
d->textInputV2->d->sendLeave(serial, d->focusedTextInputSurface);
d->textInputV3->d->sendLeave(d->focusedTextInputSurface);
d->focusedTextInputSurface = surface;
emit focusedTextInputSurfaceChanged();
Q_EMIT focusedTextInputSurfaceChanged();
}
if (d->focusedTextInputSurface) {
@ -1276,7 +1276,7 @@ void SeatInterface::setSelection(AbstractDataSource *selection)
}
}
emit selectionChanged(selection);
Q_EMIT selectionChanged(selection);
}
void SeatInterface::setPrimarySelection(AbstractDataSource *selection)
@ -1306,7 +1306,7 @@ void SeatInterface::setPrimarySelection(AbstractDataSource *selection)
}
}
emit primarySelectionChanged(selection);
Q_EMIT primarySelectionChanged(selection);
}
}

View file

@ -222,7 +222,7 @@ void BufferInterface::Private::destroyListenerCallback(wl_listener *listener, vo
Q_UNUSED(listener);
auto b = cast(reinterpret_cast<wl_resource*>(data));
b->buffer = nullptr;
emit b->q->aboutToBeDestroyed(b->q);
Q_EMIT b->q->aboutToBeDestroyed(b->q);
delete b->q;
}
@ -327,7 +327,7 @@ void BufferInterface::setSize(const QSize &size)
return;
}
d->size = size;
emit sizeChanged();
Q_EMIT sizeChanged();
}
bool BufferInterface::hasAlphaChannel() const

View file

@ -42,7 +42,7 @@ void EglStreamControllerInterfacePrivate::eglstream_controller_attach_eglstream_
wl_resource_post_error(resource->handle, 0, "Invalid surface");
return;
}
emit q->streamConsumerAttached(surface, eglStream, attribs);
Q_EMIT q->streamConsumerAttached(surface, eglStream, attribs);
}
EglStreamControllerInterfacePrivate::EglStreamControllerInterfacePrivate(EglStreamControllerInterface *_q, Display *display)

View file

@ -67,7 +67,7 @@ void Global::destroy()
if (!d->global) {
return;
}
emit aboutToDestroyGlobal();
Q_EMIT aboutToDestroyGlobal();
wl_global_destroy(d->global);
d->global = nullptr;
}

View file

@ -194,12 +194,12 @@ void OutputDeviceInterface::addMode(Mode &mode)
}
);
auto emitChanges = [this, mode] {
emit modesChanged();
Q_EMIT modesChanged();
if (mode.flags.testFlag(ModeFlag::Current)) {
d->currentMode = mode;
emit refreshRateChanged(mode.refreshRate);
emit pixelSizeChanged(mode.size);
emit currentModeChanged();
Q_EMIT refreshRateChanged(mode.refreshRate);
Q_EMIT pixelSizeChanged(mode.size);
Q_EMIT currentModeChanged();
}
};
if (existingModeIt != d->modes.end()) {
@ -247,10 +247,10 @@ void OutputDeviceInterface::setCurrentMode(const int modeId)
Q_ASSERT(existingModeIt != d->modes.end());
(*existingModeIt).flags |= ModeFlag::Current;
d->currentMode = *existingModeIt;
emit modesChanged();
emit refreshRateChanged((*existingModeIt).refreshRate);
emit pixelSizeChanged((*existingModeIt).size);
emit currentModeChanged();
Q_EMIT modesChanged();
Q_EMIT refreshRateChanged((*existingModeIt).refreshRate);
Q_EMIT pixelSizeChanged((*existingModeIt).size);
Q_EMIT currentModeChanged();
}
bool OutputDeviceInterface::setCurrentMode(const QSize &size, int refreshRate)
@ -467,7 +467,7 @@ bool OutputDeviceInterface::ColorCurves::operator!=(const ColorCurves &cc) const
return; \
} \
d->argumentName = arg; \
emit argumentName##Changed(d->argumentName); \
Q_EMIT argumentName##Changed(d->argumentName); \
}
SETTER(setPhysicalSize, const QSize&, physicalSize)
@ -487,7 +487,7 @@ void OutputDeviceInterface::setScaleF(qreal scale)
return;
}
d->scale = scale;
emit scaleFChanged(d->scale);
Q_EMIT scaleFChanged(d->scale);
}
QSize OutputDeviceInterface::physicalSize() const
@ -562,14 +562,14 @@ void OutputDeviceInterface::setColorCurves(const ColorCurves &colorCurves)
return;
}
d->colorCurves = colorCurves;
emit colorCurvesChanged(d->colorCurves);
Q_EMIT colorCurvesChanged(d->colorCurves);
}
void OutputDeviceInterface::setEdid(const QByteArray &edid)
{
d->edid = edid;
d->updateEdid();
emit edidChanged();
Q_EMIT edidChanged();
}
QByteArray OutputDeviceInterface::edid() const
@ -582,7 +582,7 @@ void OutputDeviceInterface::setEnabled(OutputDeviceInterface::Enablement enabled
if (d->enabled != enabled) {
d->enabled = enabled;
d->updateEnabled();
emit enabledChanged();
Q_EMIT enabledChanged();
}
}
@ -596,7 +596,7 @@ void OutputDeviceInterface::setUuid(const QUuid &uuid)
if (d->uuid != uuid) {
d->uuid = uuid;
d->updateUuid();
emit uuidChanged();
Q_EMIT uuidChanged();
}
}
@ -671,7 +671,7 @@ void OutputDeviceInterface::setCapabilities(Capabilities cap)
if (d->capabilities != cap) {
d->capabilities = cap;
d->updateCapabilities();
emit capabilitiesChanged();
Q_EMIT capabilitiesChanged();
}
}
@ -696,7 +696,7 @@ void OutputDeviceInterface::setOverscan(uint32_t overscan)
if (d->overscan != overscan) {
d->overscan = overscan;
d->updateOverscan();
emit overscanChanged();
Q_EMIT overscanChanged();
}
}
@ -734,7 +734,7 @@ void OutputDeviceInterface::setVrrPolicy(VrrPolicy policy)
if (d->vrrPolicy != policy) {
d->vrrPolicy = policy;
d->updateVrrPolicy();
emit vrrPolicyChanged();
Q_EMIT vrrPolicyChanged();
}
}

View file

@ -19,7 +19,7 @@ class OutputConfigurationInterface;
*
* This class is used to change the configuration of the Wayland server's outputs.
* The client requests an OutputConfiguration, changes its OutputDevices and then
* calls OutputConfiguration::apply, which makes this class emit a signal, carrying
* calls OutputConfiguration::apply, which makes this class Q_EMIT a signal, carrying
* the new configuration.
* The server is then expected to make the requested changes by applying the settings
* of the OutputDevices to the Outputs.

View file

@ -47,9 +47,9 @@ void Resource::Private::create(ClientConnection *c, quint32 version, quint32 id)
void Resource::Private::unbind(wl_resource *r)
{
Private *p = cast<Private>(r);
emit p->q->aboutToBeUnbound();
Q_EMIT p->q->aboutToBeUnbound();
p->resource = nullptr;
emit p->q->unbound();
Q_EMIT p->q->unbound();
p->q->deleteLater();
}

View file

@ -61,7 +61,7 @@ void ServerSideDecorationManagerInterfacePrivate::org_kde_kwin_server_decoration
}
auto decoration = new ServerSideDecorationInterface(s, decorationResource);
decoration->setMode(defaultMode);
emit q->decorationCreated(decoration);
Q_EMIT q->decorationCreated(decoration);
}
void ServerSideDecorationManagerInterfacePrivate::setDefaultMode(ServerSideDecorationManagerInterface::Mode mode)
@ -148,7 +148,7 @@ void ServerSideDecorationInterfacePrivate::org_kde_kwin_server_decoration_reques
qCWarning(KWAYLAND_SERVER) << "Invalid mode:" << mode;
return;
}
emit q->modeRequested(m);
Q_EMIT q->modeRequested(m);
}
void ServerSideDecorationInterfacePrivate::org_kde_kwin_server_decoration_release(Resource *resource)

View file

@ -50,7 +50,7 @@ void ServerSideDecorationPaletteManagerInterfacePrivate::org_kde_kwin_server_dec
QObject::connect(palette, &QObject::destroyed, q, [=]() {
palettes.removeOne(palette);
});
emit q->paletteCreated(palette);
Q_EMIT q->paletteCreated(palette);
}
ServerSideDecorationPaletteManagerInterfacePrivate::ServerSideDecorationPaletteManagerInterfacePrivate(ServerSideDecorationPaletteManagerInterface *_q, Display *display)
@ -105,7 +105,7 @@ void ServerSideDecorationPaletteInterfacePrivate::org_kde_kwin_server_decoration
return;
}
this->palette = palette;
emit q->paletteChanged(this->palette);
Q_EMIT q->paletteChanged(this->palette);
}
void ServerSideDecorationPaletteInterfacePrivate::org_kde_kwin_server_decoration_palette_destroy_resource(Resource *resource)

View file

@ -70,7 +70,7 @@ void SubCompositorInterfacePrivate::subcompositor_get_subsurface(Resource *resou
return;
}
emit q->subSurfaceCreated(new SubSurfaceInterface(surface, parent, subsurfaceResource));
Q_EMIT q->subSurfaceCreated(new SubSurfaceInterface(surface, parent, subsurfaceResource));
}
SubCompositorInterface::SubCompositorInterface(Display *display, QObject *parent)
@ -164,7 +164,7 @@ void SubSurfaceInterfacePrivate::subsurface_set_sync(Resource *)
return;
}
mode = SubSurfaceInterface::Mode::Synchronized;
emit q->modeChanged(SubSurfaceInterface::Mode::Synchronized);
Q_EMIT q->modeChanged(SubSurfaceInterface::Mode::Synchronized);
}
void SubSurfaceInterfacePrivate::subsurface_set_desync(Resource *)
@ -176,7 +176,7 @@ void SubSurfaceInterfacePrivate::subsurface_set_desync(Resource *)
if (!q->isSynchronized()) {
synchronizedCommit();
}
emit q->modeChanged(SubSurfaceInterface::Mode::Desynchronized);
Q_EMIT q->modeChanged(SubSurfaceInterface::Mode::Desynchronized);
}
void SubSurfaceInterfacePrivate::commit()
@ -206,7 +206,7 @@ void SubSurfaceInterfacePrivate::parentCommit(bool synchronized)
if (hasPendingPosition) {
hasPendingPosition = false;
position = pendingPosition;
emit q->positionChanged(position);
Q_EMIT q->positionChanged(position);
}
if (synchronized || mode == SubSurfaceInterface::Mode::Synchronized) {

View file

@ -84,8 +84,8 @@ void SurfaceInterfacePrivate::addChild(SubSurfaceInterface *child)
cached.children.append(child);
current.children.append(child);
child->surface()->setOutputs(outputs);
emit q->childSubSurfaceAdded(child);
emit q->childSubSurfacesChanged();
Q_EMIT q->childSubSurfaceAdded(child);
Q_EMIT q->childSubSurfacesChanged();
}
void SurfaceInterfacePrivate::removeChild(SubSurfaceInterface *child)
@ -94,8 +94,8 @@ void SurfaceInterfacePrivate::removeChild(SubSurfaceInterface *child)
pending.children.removeAll(child);
cached.children.removeAll(child);
current.children.removeAll(child);
emit q->childSubSurfaceRemoved(child);
emit q->childSubSurfacesChanged();
Q_EMIT q->childSubSurfaceRemoved(child);
Q_EMIT q->childSubSurfacesChanged();
}
bool SurfaceInterfacePrivate::raiseChild(SubSurfaceInterface *subsurface, SurfaceInterface *sibling)
@ -206,7 +206,7 @@ void SurfaceInterfacePrivate::installPointerConstraint(LockedPointerV1Interface
constrainsOneShotConnection = QMetaObject::Connection();
QObject::disconnect(constrainsUnboundConnection);
constrainsUnboundConnection = QMetaObject::Connection();
emit q->pointerConstraintsChanged();
Q_EMIT q->pointerConstraintsChanged();
};
if (lock->lifeTime() == LockedPointerV1Interface::LifeTime::OneShot) {
@ -220,7 +220,7 @@ void SurfaceInterfacePrivate::installPointerConstraint(LockedPointerV1Interface
);
}
constrainsUnboundConnection = QObject::connect(lock, &LockedPointerV1Interface::destroyed, q, cleanUp);
emit q->pointerConstraintsChanged();
Q_EMIT q->pointerConstraintsChanged();
}
void SurfaceInterfacePrivate::installPointerConstraint(ConfinedPointerV1Interface *confinement)
@ -236,7 +236,7 @@ void SurfaceInterfacePrivate::installPointerConstraint(ConfinedPointerV1Interfac
constrainsOneShotConnection = QMetaObject::Connection();
QObject::disconnect(constrainsUnboundConnection);
constrainsUnboundConnection = QMetaObject::Connection();
emit q->pointerConstraintsChanged();
Q_EMIT q->pointerConstraintsChanged();
};
if (confinement->lifeTime() == ConfinedPointerV1Interface::LifeTime::OneShot) {
@ -250,7 +250,7 @@ void SurfaceInterfacePrivate::installPointerConstraint(ConfinedPointerV1Interfac
);
}
constrainsUnboundConnection = QObject::connect(confinement, &ConfinedPointerV1Interface::destroyed, q, cleanUp);
emit q->pointerConstraintsChanged();
Q_EMIT q->pointerConstraintsChanged();
}
void SurfaceInterfacePrivate::installIdleInhibitor(IdleInhibitorV1Interface *inhibitor)
@ -260,18 +260,18 @@ void SurfaceInterfacePrivate::installIdleInhibitor(IdleInhibitorV1Interface *inh
[this, inhibitor] {
idleInhibitors.removeOne(inhibitor);
if (idleInhibitors.isEmpty()) {
emit q->inhibitsIdleChanged();
Q_EMIT q->inhibitsIdleChanged();
}
}
);
if (idleInhibitors.count() == 1) {
emit q->inhibitsIdleChanged();
Q_EMIT q->inhibitsIdleChanged();
}
}
void SurfaceInterfacePrivate::surface_destroy_resource(Resource *)
{
emit q->aboutToBeDestroyed();
Q_EMIT q->aboutToBeDestroyed();
delete q;
}
@ -610,24 +610,24 @@ void SurfaceInterfacePrivate::swapStates(State *source, State *target, bool emit
bufferToSurfaceMatrix = surfaceToBufferMatrix.inverted();
inputRegion = target->input & QRect(QPoint(0, 0), target->size);
if (opaqueRegionChanged) {
emit q->opaqueChanged(target->opaque);
Q_EMIT q->opaqueChanged(target->opaque);
}
if (oldInputRegion != inputRegion) {
emit q->inputChanged(inputRegion);
Q_EMIT q->inputChanged(inputRegion);
}
if (scaleFactorChanged) {
emit q->bufferScaleChanged(target->bufferScale);
Q_EMIT q->bufferScaleChanged(target->bufferScale);
}
if (transformChanged) {
emit q->bufferTransformChanged(target->bufferTransform);
Q_EMIT q->bufferTransformChanged(target->bufferTransform);
}
if (visibilityChanged) {
if (target->buffer) {
subSurfaceIsMapped = true;
emit q->mapped();
Q_EMIT q->mapped();
} else {
subSurfaceIsMapped = false;
emit q->unmapped();
Q_EMIT q->unmapped();
}
}
if (bufferChanged) {
@ -635,32 +635,32 @@ void SurfaceInterfacePrivate::swapStates(State *source, State *target, bool emit
const QRegion windowRegion = QRegion(0, 0, q->size().width(), q->size().height());
const QRegion bufferDamage = q->mapFromBuffer(target->bufferDamage);
target->damage = windowRegion.intersected(target->damage.united(bufferDamage));
emit q->damaged(target->damage);
Q_EMIT q->damaged(target->damage);
}
}
if (surfaceToBufferMatrix != oldSurfaceToBufferMatrix) {
emit q->surfaceToBufferMatrixChanged();
Q_EMIT q->surfaceToBufferMatrixChanged();
}
if (bufferSize != oldBufferSize) {
emit q->bufferSizeChanged();
Q_EMIT q->bufferSizeChanged();
}
if (target->size != oldSize) {
emit q->sizeChanged();
Q_EMIT q->sizeChanged();
}
if (shadowChanged) {
emit q->shadowChanged();
Q_EMIT q->shadowChanged();
}
if (blurChanged) {
emit q->blurChanged();
Q_EMIT q->blurChanged();
}
if (contrastChanged) {
emit q->contrastChanged();
Q_EMIT q->contrastChanged();
}
if (slideChanged) {
emit q->slideOnShowHideChanged();
Q_EMIT q->slideOnShowHideChanged();
}
if (childrenChanged) {
emit q->childSubSurfacesChanged();
Q_EMIT q->childSubSurfacesChanged();
}
}
@ -681,7 +681,7 @@ void SurfaceInterfacePrivate::commit()
role->commit();
}
emit q->committed();
Q_EMIT q->committed();
}
QRegion SurfaceInterface::damage() const

View file

@ -286,7 +286,7 @@ void TextInputV2InterfacePrivate::zwp_text_input_v2_enable(Resource *resource, w
Q_UNUSED(resource)
surface = SurfaceInterface::get(s);
enabled = true;
emit q->enabledChanged();
Q_EMIT q->enabledChanged();
}
void TextInputV2InterfacePrivate::zwp_text_input_v2_disable(Resource *resource, wl_resource *s)
@ -298,19 +298,19 @@ void TextInputV2InterfacePrivate::zwp_text_input_v2_disable(Resource *resource,
surface.clear();
enabled = false;
emit q->enabledChanged();
Q_EMIT q->enabledChanged();
}
void TextInputV2InterfacePrivate::zwp_text_input_v2_update_state(Resource *resource, uint32_t serial, uint32_t reason)
{
Q_UNUSED(resource)
emit q->stateUpdated(serial, TextInputV2Interface::UpdateReason(reason));
Q_EMIT q->stateUpdated(serial, TextInputV2Interface::UpdateReason(reason));
}
void TextInputV2InterfacePrivate::zwp_text_input_v2_hide_input_panel(Resource *resource)
{
Q_UNUSED(resource)
emit q->requestHideInputPanel();
Q_EMIT q->requestHideInputPanel();
}
void TextInputV2InterfacePrivate::zwp_text_input_v2_set_surrounding_text(Resource *resource, const QString &text, int32_t cursor, int32_t anchor)
@ -319,7 +319,7 @@ void TextInputV2InterfacePrivate::zwp_text_input_v2_set_surrounding_text(Resourc
surroundingText = text;
surroundingTextCursorPosition = cursor;
surroundingTextSelectionAnchor = anchor;
emit q->surroundingTextChanged();
Q_EMIT q->surroundingTextChanged();
}
void TextInputV2InterfacePrivate::zwp_text_input_v2_set_content_type(Resource *resource, uint32_t hint, uint32_t purpose)
@ -330,7 +330,7 @@ void TextInputV2InterfacePrivate::zwp_text_input_v2_set_content_type(Resource *r
if (this->contentHints != contentHints || this->contentPurpose != contentPurpose) {
this->contentHints = contentHints;
this->contentPurpose = contentPurpose;
emit q->contentTypeChanged();
Q_EMIT q->contentTypeChanged();
}
}
@ -340,7 +340,7 @@ void TextInputV2InterfacePrivate::zwp_text_input_v2_set_cursor_rectangle(Resourc
const QRect rect = QRect(x, y, width, height);
if (cursorRectangle != rect) {
cursorRectangle = rect;
emit q->cursorRectangleChanged(cursorRectangle);
Q_EMIT q->cursorRectangleChanged(cursorRectangle);
}
}
@ -349,14 +349,14 @@ void TextInputV2InterfacePrivate::zwp_text_input_v2_set_preferred_language(Resou
Q_UNUSED(resource)
if (preferredLanguage != language) {
preferredLanguage = language;
emit q->preferredLanguageChanged(preferredLanguage);
Q_EMIT q->preferredLanguageChanged(preferredLanguage);
}
}
void TextInputV2InterfacePrivate::zwp_text_input_v2_show_input_panel(Resource *resource)
{
Q_UNUSED(resource)
emit q->requestShowInputPanel();
Q_EMIT q->requestShowInputPanel();
}
QList<TextInputV2InterfacePrivate::Resource *> TextInputV2InterfacePrivate::textInputsForClient(ClientConnection *client) const

View file

@ -289,7 +289,7 @@ void TextInputV3InterfacePrivate::zwp_text_input_v3_commit(Resource *resource)
if (enabled != pending.enabled) {
enabled = pending.enabled;
emit q->enabledChanged();
Q_EMIT q->enabledChanged();
}
if (surroundingTextChangeCause != pending.surroundingTextChangeCause) {
@ -301,14 +301,14 @@ void TextInputV3InterfacePrivate::zwp_text_input_v3_commit(Resource *resource)
contentHints = pending.contentHints;
contentPurpose = pending.contentPurpose;
if (enabled) {
emit q->contentTypeChanged();
Q_EMIT q->contentTypeChanged();
}
}
if (cursorRectangle != pending.cursorRectangle) {
cursorRectangle = pending.cursorRectangle;
if (enabled) {
emit q->cursorRectangleChanged(cursorRectangle);
Q_EMIT q->cursorRectangleChanged(cursorRectangle);
}
}
@ -317,11 +317,11 @@ void TextInputV3InterfacePrivate::zwp_text_input_v3_commit(Resource *resource)
surroundingTextCursorPosition = pending.surroundingTextCursorPosition;
surroundingTextSelectionAnchor = pending.surroundingTextSelectionAnchor;
if (enabled) {
emit q->surroundingTextChanged();
Q_EMIT q->surroundingTextChanged();
}
}
emit q->stateCommitted(serialHash[resource]);
Q_EMIT q->stateCommitted(serialHash[resource]);
}
void TextInputV3InterfacePrivate::defaultPending()

View file

@ -50,7 +50,7 @@ void XdgDecorationManagerV1InterfacePrivate::zxdg_decoration_manager_v1_get_topl
auto decoration = new XdgToplevelDecorationV1Interface(toplevelPrivate->q, decorationResource);
toplevelPrivate->decoration = decoration;
emit q->decorationCreated(decoration);
Q_EMIT q->decorationCreated(decoration);
}
XdgDecorationManagerV1Interface::XdgDecorationManagerV1Interface(Display *display, QObject *parent)
@ -96,14 +96,14 @@ void XdgToplevelDecorationV1InterfacePrivate::zxdg_toplevel_decoration_v1_set_mo
break;
}
emit q->preferredModeChanged(preferredMode);
Q_EMIT q->preferredModeChanged(preferredMode);
}
void XdgToplevelDecorationV1InterfacePrivate::zxdg_toplevel_decoration_v1_unset_mode(Resource *resource)
{
Q_UNUSED(resource)
preferredMode = XdgToplevelDecorationV1Interface::Mode::Undefined;
emit q->preferredModeChanged(preferredMode);
Q_EMIT q->preferredModeChanged(preferredMode);
}
XdgToplevelDecorationV1Interface::XdgToplevelDecorationV1Interface(XdgToplevelInterface *toplevel,

View file

@ -153,7 +153,7 @@ void XdgImporterV2Interface::link(XdgImportedV2Interface *parent, SurfaceInterfa
m_parents[child] = parent;
m_children[parent] = child;
emit m_foreign->transientChanged(child, parent->surface());
Q_EMIT m_foreign->transientChanged(child, parent->surface());
}
void XdgImporterV2Interface::unlink(XdgImportedV2Interface *parent, SurfaceInterface *child)
@ -166,7 +166,7 @@ void XdgImporterV2Interface::unlink(XdgImportedV2Interface *parent, SurfaceInter
SurfaceInterface *child = *it;
m_parents.remove(*it);
m_children.erase(it);
emit m_foreign->transientChanged(child, nullptr);
Q_EMIT m_foreign->transientChanged(child, nullptr);
}
} else if (child) {
// If the child endpoint is unlinked, the transientChanged() signal will indicate
@ -176,7 +176,7 @@ void XdgImporterV2Interface::unlink(XdgImportedV2Interface *parent, SurfaceInter
XdgImportedV2Interface *parent = *it;
m_children.remove(*it);
m_parents.erase(it);
emit m_foreign->transientChanged(nullptr, parent->surface());
Q_EMIT m_foreign->transientChanged(nullptr, parent->surface());
}
}
}
@ -252,7 +252,7 @@ void XdgImportedV2Interface::zxdg_imported_v2_set_parent_of(Resource *resource,
}
m_child = surf;
emit childChanged(surf);
Q_EMIT childChanged(surf);
}
void XdgImportedV2Interface::zxdg_imported_v2_destroy(Resource *resource)

View file

@ -55,10 +55,10 @@ void XdgShellInterfacePrivate::registerPing(quint32 serial)
QObject::connect(timer, &QTimer::timeout, q, [this, serial, attempt = 0]() mutable {
++attempt;
if (attempt == 1) {
emit q->pingDelayed(serial);
Q_EMIT q->pingDelayed(serial);
return;
}
emit q->pingTimeout(serial);
Q_EMIT q->pingTimeout(serial);
delete pings.take(serial);
});
pings.insert(serial, timer);
@ -111,7 +111,7 @@ void XdgShellInterfacePrivate::xdg_wm_base_pong(Resource *resource, uint32_t ser
if (QTimer *timer = pings.take(serial)) {
delete timer;
}
emit q->pongReceived(serial);
Q_EMIT q->pongReceived(serial);
}
XdgShellInterface::XdgShellInterface(Display *display, QObject *parent)
@ -153,7 +153,7 @@ void XdgSurfaceInterfacePrivate::commit()
{
if (current.windowGeometry != next.windowGeometry) {
current.windowGeometry = next.windowGeometry;
emit q->windowGeometryChanged(current.windowGeometry);
Q_EMIT q->windowGeometryChanged(current.windowGeometry);
}
isMapped = surface->buffer();
}
@ -162,7 +162,7 @@ void XdgSurfaceInterfacePrivate::reset()
{
isConfigured = false;
current = next = State();
emit q->resetOccurred();
Q_EMIT q->resetOccurred();
}
XdgSurfaceInterfacePrivate *XdgSurfaceInterfacePrivate::get(XdgSurfaceInterface *surface)
@ -199,7 +199,7 @@ void XdgSurfaceInterfacePrivate::xdg_surface_get_toplevel(Resource *resource, ui
resource->version(), id);
toplevel = new XdgToplevelInterface(q, toplevelResource);
emit shell->toplevelCreated(toplevel);
Q_EMIT shell->toplevelCreated(toplevel);
}
void XdgSurfaceInterfacePrivate::xdg_surface_get_popup(Resource *resource, uint32_t id,
@ -233,7 +233,7 @@ void XdgSurfaceInterfacePrivate::xdg_surface_get_popup(Resource *resource, uint3
resource->version(), id);
popup = new XdgPopupInterface(q, parentSurface, positioner, popupResource);
emit shell->popupCreated(popup);
Q_EMIT shell->popupCreated(popup);
}
void XdgSurfaceInterfacePrivate::xdg_surface_set_window_geometry(Resource *resource,
@ -258,7 +258,7 @@ void XdgSurfaceInterfacePrivate::xdg_surface_set_window_geometry(Resource *resou
void XdgSurfaceInterfacePrivate::xdg_surface_ack_configure(Resource *resource, uint32_t serial)
{
Q_UNUSED(resource)
emit q->configureAcknowledged(serial);
Q_EMIT q->configureAcknowledged(serial);
}
XdgSurfaceInterface::XdgSurfaceInterface(XdgShellInterface *shell, SurfaceInterface *surface,
@ -329,7 +329,7 @@ void XdgToplevelInterfacePrivate::commit()
if (xdgSurfacePrivate->isConfigured) {
xdgSurfacePrivate->commit();
} else {
emit q->initializeRequested();
Q_EMIT q->initializeRequested();
return;
}
@ -340,11 +340,11 @@ void XdgToplevelInterfacePrivate::commit()
if (current.minimumSize != next.minimumSize) {
current.minimumSize = next.minimumSize;
emit q->minimumSizeChanged(current.minimumSize);
Q_EMIT q->minimumSizeChanged(current.minimumSize);
}
if (current.maximumSize != next.maximumSize) {
current.maximumSize = next.maximumSize;
emit q->maximumSizeChanged(current.maximumSize);
Q_EMIT q->maximumSizeChanged(current.maximumSize);
}
}
@ -357,7 +357,7 @@ void XdgToplevelInterfacePrivate::reset()
windowClass = QString();
current = next = State();
emit q->resetOccurred();
Q_EMIT q->resetOccurred();
}
void XdgToplevelInterfacePrivate::xdg_toplevel_destroy_resource(Resource *resource)
@ -380,7 +380,7 @@ void XdgToplevelInterfacePrivate::xdg_toplevel_set_parent(Resource *resource,
return;
}
parentXdgToplevel = parent;
emit q->parentXdgToplevelChanged();
Q_EMIT q->parentXdgToplevelChanged();
}
void XdgToplevelInterfacePrivate::xdg_toplevel_set_title(Resource *resource, const QString &title)
@ -390,7 +390,7 @@ void XdgToplevelInterfacePrivate::xdg_toplevel_set_title(Resource *resource, con
return;
}
windowTitle = title;
emit q->windowTitleChanged(title);
Q_EMIT q->windowTitleChanged(title);
}
void XdgToplevelInterfacePrivate::xdg_toplevel_set_app_id(Resource *resource, const QString &app_id)
@ -400,7 +400,7 @@ void XdgToplevelInterfacePrivate::xdg_toplevel_set_app_id(Resource *resource, co
return;
}
windowClass = app_id;
emit q->windowClassChanged(app_id);
Q_EMIT q->windowClassChanged(app_id);
}
void XdgToplevelInterfacePrivate::xdg_toplevel_show_window_menu(Resource *resource, ::wl_resource *seatResource,
@ -415,7 +415,7 @@ void XdgToplevelInterfacePrivate::xdg_toplevel_show_window_menu(Resource *resour
}
SeatInterface *seat = SeatInterface::get(seatResource);
emit q->windowMenuRequested(seat, QPoint(x, y), serial);
Q_EMIT q->windowMenuRequested(seat, QPoint(x, y), serial);
}
void XdgToplevelInterfacePrivate::xdg_toplevel_move(Resource *resource, ::wl_resource *seatResource, uint32_t serial)
@ -429,7 +429,7 @@ void XdgToplevelInterfacePrivate::xdg_toplevel_move(Resource *resource, ::wl_res
}
SeatInterface *seat = SeatInterface::get(seatResource);
emit q->moveRequested(seat, serial);
Q_EMIT q->moveRequested(seat, serial);
}
void XdgToplevelInterfacePrivate::xdg_toplevel_resize(Resource *resource, ::wl_resource *seatResource,
@ -459,7 +459,7 @@ void XdgToplevelInterfacePrivate::xdg_toplevel_resize(Resource *resource, ::wl_r
edges |= Qt::LeftEdge;
}
emit q->resizeRequested(seat, edges, serial);
Q_EMIT q->resizeRequested(seat, edges, serial);
}
void XdgToplevelInterfacePrivate::xdg_toplevel_set_max_size(Resource *resource, int32_t width, int32_t height)
@ -483,32 +483,32 @@ void XdgToplevelInterfacePrivate::xdg_toplevel_set_min_size(Resource *resource,
void XdgToplevelInterfacePrivate::xdg_toplevel_set_maximized(Resource *resource)
{
Q_UNUSED(resource)
emit q->maximizeRequested();
Q_EMIT q->maximizeRequested();
}
void XdgToplevelInterfacePrivate::xdg_toplevel_unset_maximized(Resource *resource)
{
Q_UNUSED(resource)
emit q->unmaximizeRequested();
Q_EMIT q->unmaximizeRequested();
}
void XdgToplevelInterfacePrivate::xdg_toplevel_set_fullscreen(Resource *resource, ::wl_resource *outputResource)
{
Q_UNUSED(resource)
OutputInterface *output = OutputInterface::get(outputResource);
emit q->fullscreenRequested(output);
Q_EMIT q->fullscreenRequested(output);
}
void XdgToplevelInterfacePrivate::xdg_toplevel_unset_fullscreen(Resource *resource)
{
Q_UNUSED(resource)
emit q->unfullscreenRequested();
Q_EMIT q->unfullscreenRequested();
}
void XdgToplevelInterfacePrivate::xdg_toplevel_set_minimized(Resource *resource)
{
Q_UNUSED(resource)
emit q->minimizeRequested();
Q_EMIT q->minimizeRequested();
}
XdgToplevelInterfacePrivate *XdgToplevelInterfacePrivate::get(XdgToplevelInterface *toplevel)
@ -666,7 +666,7 @@ void XdgPopupInterfacePrivate::commit()
if (xdgSurfacePrivate->isConfigured) {
xdgSurfacePrivate->commit();
} else {
emit q->initializeRequested();
Q_EMIT q->initializeRequested();
return;
}
@ -703,14 +703,14 @@ void XdgPopupInterfacePrivate::xdg_popup_grab(Resource *resource, ::wl_resource
return;
}
SeatInterface *seat = SeatInterface::get(seatHandle);
emit q->grabRequested(seat, serial);
Q_EMIT q->grabRequested(seat, serial);
}
void XdgPopupInterfacePrivate::xdg_popup_reposition(Resource *resource, ::wl_resource *positionerResource, uint32_t token)
{
Q_UNUSED(resource)
positioner = XdgPositioner::get(positionerResource);
emit q->repositionRequested(token);
Q_EMIT q->repositionRequested(token);
}
XdgPopupInterface::XdgPopupInterface(XdgSurfaceInterface *surface,