Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In XWaylandSurface::map() the reply function, cookie, is never called #3702

Open
carbonXIII opened this issue Dec 17, 2024 · 0 comments
Open

Comments

@carbonXIII
Copy link

// _NET_WM_STATE is not in property_handlers because we only read it on window creation
// We, the server (not the client) are responsible for updating it after the window has been mapped
// The client should use a client message to change state later
auto const cookie = connection->read_property(
window,
connection->_NET_WM_STATE,
{
[&](std::vector<xcb_atom_t> const& net_wm_states)
{
for (auto const& net_wm_state : net_wm_states)
{
state = state.with_net_wm_state_change(*connection, NetWmStateAction::ADD, net_wm_state);
}
}
});
// If we had more properties to read we would queue them all up before completing the first one
uint32_t const workspace = 1;
connection->set_property<XCBType::CARDINAL32>(
window,
connection->_NET_WM_DESKTOP,
workspace);
inform_client_of_window_state(std::unique_lock(mutex), state);
request_scene_surface_state(state.active_mir_state());
xcb_map_window(*connection, window);

cookie is not actually called, so properties set by Xwayland clients via _NET_WM_STATE are ignored.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant