diff --git a/src/wayland/meta-wayland-outputs.c b/src/wayland/meta-wayland-outputs.c index c2ed5986b..dfd21a37f 100644 --- a/src/wayland/meta-wayland-outputs.c +++ b/src/wayland/meta-wayland-outputs.c @@ -144,23 +144,6 @@ calculate_wayland_output_scale (MetaMonitor *monitor) return ceilf (scale); } -static void -get_native_output_mode_resolution (MetaMonitor *monitor, - MetaMonitorMode *mode, - int *mode_width, - int *mode_height) -{ - MetaLogicalMonitor *logical_monitor; - MetaMonitorTransform transform; - - logical_monitor = meta_monitor_get_logical_monitor (monitor); - transform = meta_logical_monitor_get_transform (logical_monitor); - if (meta_monitor_transform_is_rotated (transform)) - meta_monitor_mode_get_resolution (mode, mode_height, mode_width); - else - meta_monitor_mode_get_resolution (mode, mode_width, mode_height); -} - static enum wl_output_transform wl_output_transform_from_transform (MetaMonitorTransform transform) { @@ -259,10 +242,9 @@ send_output_events (struct wl_resource *resource, if (current_mode == preferred_mode) mode_flags |= WL_OUTPUT_MODE_PREFERRED; - get_native_output_mode_resolution (monitor, - current_mode, - &new_width, - &new_height); + meta_monitor_mode_get_resolution (current_mode, + &new_width, + &new_height); if (need_all_events || wayland_output->mode_width != new_width || wayland_output->mode_height != new_height || @@ -383,10 +365,9 @@ meta_wayland_output_set_monitor (MetaWaylandOutput *wayland_output, wayland_output->transform = meta_logical_monitor_get_transform (logical_monitor); - get_native_output_mode_resolution (monitor, - current_mode, - &wayland_output->mode_width, - &wayland_output->mode_height); + meta_monitor_mode_get_resolution (current_mode, + &wayland_output->mode_width, + &wayland_output->mode_height); } static void