aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2017-12-28 10:07:41 -0800
committerGitHub <noreply@github.com>2017-12-28 10:07:41 -0800
commit836b46c2971d2f3be0e224e67a9dd7e3a1931782 (patch)
treec459c38deae098b5b8ac466c751938a006bb965c
parent0fbf1a07556693c6f4f5107eece983ac902afbea (diff)
parent6e9cef4ed69100241a52b158539d7be9ec413c55 (diff)
Merge pull request #536 from Timidger/bugfix/drm-refresh-double-send-mode-info
Send mode info on DRM refresh only once
-rw-r--r--types/wlr_output.c22
1 files changed, 2 insertions, 20 deletions
diff --git a/types/wlr_output.c b/types/wlr_output.c
index 115f3e8b..46db98b3 100644
--- a/types/wlr_output.c
+++ b/types/wlr_output.c
@@ -163,16 +163,7 @@ bool wlr_output_set_mode(struct wlr_output *output,
if (!output->impl || !output->impl->set_mode) {
return false;
}
- bool result = output->impl->set_mode(output, mode);
- if (result) {
- wlr_output_update_matrix(output);
-
- struct wl_resource *resource;
- wl_resource_for_each(resource, &output->wl_resources) {
- wlr_output_send_current_mode_to_resource(resource);
- }
- }
- return result;
+ return output->impl->set_mode(output, mode);
}
bool wlr_output_set_custom_mode(struct wlr_output *output, int32_t width,
@@ -180,16 +171,7 @@ bool wlr_output_set_custom_mode(struct wlr_output *output, int32_t width,
if (!output->impl || !output->impl->set_custom_mode) {
return false;
}
- bool result = output->impl->set_custom_mode(output, width, height, refresh);
- if (result) {
- wlr_output_update_matrix(output);
-
- struct wl_resource *resource;
- wl_resource_for_each(resource, &output->wl_resources) {
- wlr_output_send_current_mode_to_resource(resource);
- }
- }
- return result;
+ return output->impl->set_custom_mode(output, width, height, refresh);
}
void wlr_output_update_mode(struct wlr_output *output,