datacontrolv1: emit clipboard mode changed when selection changed
Pick-to: 6.9 Change-Id: I47508a88d2115ee92521b0499f72faa566e6b3a3 Reviewed-by: Liang Qi <liang.qi@qt.io>
This commit is contained in:
parent
8c0dd12f4b
commit
3bd2a2f8ee
@ -64,7 +64,7 @@ void QWaylandDataControlDeviceV1::invalidateSelectionOffer()
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
m_selectionOffer.reset();
|
m_selectionOffer.reset();
|
||||||
QGuiApplicationPrivate::platformIntegration()->clipboard()->emitChanged(QClipboard::Selection);
|
QGuiApplicationPrivate::platformIntegration()->clipboard()->emitChanged(QClipboard::Clipboard);
|
||||||
}
|
}
|
||||||
|
|
||||||
void QWaylandDataControlDeviceV1::setSelectionSource(QWaylandDataControlSourceV1 *source)
|
void QWaylandDataControlDeviceV1::setSelectionSource(QWaylandDataControlSourceV1 *source)
|
||||||
@ -105,14 +105,14 @@ void QWaylandDataControlDeviceV1::zwlr_data_control_device_v1_selection(zwlr_dat
|
|||||||
|
|
||||||
// The selection event may be sent before platfrmIntegration is set.
|
// The selection event may be sent before platfrmIntegration is set.
|
||||||
if (auto* integration = QGuiApplicationPrivate::platformIntegration())
|
if (auto* integration = QGuiApplicationPrivate::platformIntegration())
|
||||||
integration->clipboard()->emitChanged(QClipboard::Selection);
|
integration->clipboard()->emitChanged(QClipboard::Clipboard);
|
||||||
}
|
}
|
||||||
|
|
||||||
void QWaylandDataControlDeviceV1::zwlr_data_control_device_v1_finished()
|
void QWaylandDataControlDeviceV1::zwlr_data_control_device_v1_finished()
|
||||||
{
|
{
|
||||||
m_selectionOffer.reset();
|
m_selectionOffer.reset();
|
||||||
m_primarySelectionOffer.reset();
|
m_primarySelectionOffer.reset();
|
||||||
QGuiApplicationPrivate::platformIntegration()->clipboard()->emitChanged(QClipboard::Selection);
|
QGuiApplicationPrivate::platformIntegration()->clipboard()->emitChanged(QClipboard::Clipboard);
|
||||||
}
|
}
|
||||||
|
|
||||||
void QWaylandDataControlDeviceV1::zwlr_data_control_device_v1_primary_selection(struct ::zwlr_data_control_offer_v1 *id)
|
void QWaylandDataControlDeviceV1::zwlr_data_control_device_v1_primary_selection(struct ::zwlr_data_control_offer_v1 *id)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user