зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1505164 - Express explicit wailand interface versions r=jhorak
Differential Revision: https://phabricator.services.mozilla.com/D11757 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
0a243e03d4
Коммит
dc82a88ccf
|
@ -242,7 +242,8 @@ global_registry_handler(void *data, wl_registry *registry, uint32_t id,
|
|||
if (strcmp(interface, "wl_shm") == 0) {
|
||||
auto interface = reinterpret_cast<nsWaylandDisplay *>(data);
|
||||
auto shm = static_cast<wl_shm*>(
|
||||
wl_registry_bind(registry, id, &wl_shm_interface, 1));
|
||||
wl_registry_bind(registry, id, &wl_shm_interface,
|
||||
WL_SHM_POOL_RESIZE_SINCE_VERSION));
|
||||
wl_proxy_set_queue((struct wl_proxy *)shm, interface->GetEventQueue());
|
||||
interface->SetShm(shm);
|
||||
}
|
||||
|
|
|
@ -180,9 +180,9 @@ registry_handle_global (void *data,
|
|||
if(strcmp(interface, "wl_subcompositor") == 0) {
|
||||
container->subcompositor =
|
||||
static_cast<wl_subcompositor*>(wl_registry_bind(registry,
|
||||
name,
|
||||
&wl_subcompositor_interface,
|
||||
1));
|
||||
name,
|
||||
&wl_subcompositor_interface,
|
||||
WL_SUBCOMPOSITOR_GET_SUBSURFACE_SINCE_VERSION));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -712,7 +712,10 @@ nsRetrievalContextWayland::InitDataDeviceManager(wl_registry *registry,
|
|||
uint32_t id,
|
||||
uint32_t version)
|
||||
{
|
||||
int data_device_manager_version = MIN (version, 3);
|
||||
// The documentation is pretty mean according wl_data_device_manager versions.
|
||||
// We should be fine with version 1 but Gtk+ uses this construction
|
||||
// so let's follow them.
|
||||
int data_device_manager_version = MIN(version, 3);
|
||||
mDataDeviceManager = (wl_data_device_manager *)wl_registry_bind(registry, id,
|
||||
&wl_data_device_manager_interface, data_device_manager_version);
|
||||
}
|
||||
|
@ -723,7 +726,8 @@ nsRetrievalContextWayland::InitPrimarySelectionDataDeviceManager(
|
|||
{
|
||||
mPrimarySelectionDataDeviceManager =
|
||||
(gtk_primary_selection_device_manager *)wl_registry_bind(registry, id,
|
||||
>k_primary_selection_device_manager_interface, 1);
|
||||
>k_primary_selection_device_manager_interface,
|
||||
/* First version of gtk_primary_selection extension */ 1);
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -731,7 +735,8 @@ nsRetrievalContextWayland::InitSeat(wl_registry *registry,
|
|||
uint32_t id, uint32_t version,
|
||||
void *data)
|
||||
{
|
||||
mSeat = (wl_seat*)wl_registry_bind(registry, id, &wl_seat_interface, 1);
|
||||
mSeat = (wl_seat*)wl_registry_bind(registry, id, &wl_seat_interface,
|
||||
WL_SEAT_CAPABILITIES_SINCE_VERSION);
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
@ -612,7 +612,8 @@ gdk_registry_handle_global(void *data,
|
|||
{
|
||||
if (strcmp(interface, "wl_seat") == 0) {
|
||||
wl_seat *seat =
|
||||
(wl_seat*)wl_registry_bind(registry, id, &wl_seat_interface, 1);
|
||||
(wl_seat*)wl_registry_bind(registry, id, &wl_seat_interface,
|
||||
WL_SEAT_CAPABILITIES_SINCE_VERSION);
|
||||
wl_seat_add_listener(seat, &seat_listener, data);
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче