Skip to content

Commit

Permalink
refactor(server): remove wlr output configuration member
Browse files Browse the repository at this point in the history
It is unused.
  • Loading branch information
romangg committed Sep 11, 2023
1 parent 66dd3bc commit eb698bb
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 15 deletions.
14 changes: 5 additions & 9 deletions server/wlr_output_configuration_head_v1.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ QSize estimate_logical_size(output_state const& state, double scale)
wlr_output_configuration_head_v1::Private::Private(Client* client,
uint32_t version,
uint32_t id,
wlr_output_configuration_v1& configuration,
wlr_output_head_v1_res& head,
wlr_output_configuration_head_v1& q_ptr)
: Wayland::Resource<wlr_output_configuration_head_v1>(
Expand All @@ -59,7 +58,6 @@ wlr_output_configuration_head_v1::Private::Private(Client* client,
&q_ptr)
, state{head.d_ptr->head->output.d_ptr->published.state}
, scale{estimate_scale(state)}
, configuration{configuration}
, head{&head}
{
}
Expand Down Expand Up @@ -146,13 +144,11 @@ void wlr_output_configuration_head_v1::Private::set_adaptive_sync_callback(wl_cl
priv->state.adaptive_sync = wlState == ZWLR_OUTPUT_HEAD_V1_ADAPTIVE_SYNC_STATE_ENABLED;
}

wlr_output_configuration_head_v1::wlr_output_configuration_head_v1(
Client* client,
uint32_t version,
uint32_t id,
wlr_output_configuration_v1& configuration,
wlr_output_head_v1_res& head)
: d_ptr{new Private(client, version, id, configuration, head, *this)}
wlr_output_configuration_head_v1::wlr_output_configuration_head_v1(Client* client,
uint32_t version,
uint32_t id,
wlr_output_head_v1_res& head)
: d_ptr{new Private(client, version, id, head, *this)}
{
}

Expand Down
1 change: 0 additions & 1 deletion server/wlr_output_configuration_head_v1.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ class WRAPLANDSERVER_EXPORT wlr_output_configuration_head_v1 : public QObject
wlr_output_configuration_head_v1(Client* client,
uint32_t version,
uint32_t id,
wlr_output_configuration_v1& configuration,
wlr_output_head_v1_res& head);
friend class wlr_output_configuration_v1_res;

Expand Down
3 changes: 0 additions & 3 deletions server/wlr_output_configuration_head_v1_p.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,11 @@ class wlr_output_configuration_head_v1::Private
Private(Client* client,
uint32_t version,
uint32_t id,
wlr_output_configuration_v1& configuration,
wlr_output_head_v1_res& head,
wlr_output_configuration_head_v1& q_ptr);

output_state state;
double scale;

wlr_output_configuration_v1& configuration;
wlr_output_head_v1_res* head;

private:
Expand Down
4 changes: 2 additions & 2 deletions server/wlr_output_configuration_v1.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -161,8 +161,8 @@ void wlr_output_configuration_v1_res::Private::enable_head_callback(wl_client* /
return;
}

priv->enabled_heads.push_back(new wlr_output_configuration_head_v1(
priv->client->handle, priv->version, id, *priv->front, *head));
priv->enabled_heads.push_back(
new wlr_output_configuration_head_v1(priv->client->handle, priv->version, id, *head));
}

void wlr_output_configuration_v1_res::Private::disable_head_callback(wl_client* /*wlClient*/,
Expand Down

0 comments on commit eb698bb

Please sign in to comment.