[mutter] display: Use logical monitor API when requesting pad OSD
- From: Jonas Ådahl <jadahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] display: Use logical monitor API when requesting pad OSD
- Date: Wed, 25 Jan 2017 08:31:43 +0000 (UTC)
commit 06770b0dd483012d2a6a198e5be247a9ac848347
Author: Jonas Ådahl <jadahl gmail com>
Date: Thu Dec 1 12:55:21 2016 +0800
display: Use logical monitor API when requesting pad OSD
Don't use the array index based logical monitor API and switch to the
one directly referencing logical monitor instances.
https://bugzilla.gnome.org/show_bug.cgi?id=777732
src/core/display.c | 15 +++------------
1 files changed, 3 insertions(+), 12 deletions(-)
---
diff --git a/src/core/display.c b/src/core/display.c
index ee1352c..c064620 100644
--- a/src/core/display.c
+++ b/src/core/display.c
@@ -3089,7 +3089,6 @@ meta_display_request_pad_osd (MetaDisplay *display,
const gchar *layout_path = NULL;
ClutterActor *osd;
MetaLogicalMonitor *logical_monitor;
- gint monitor_idx;
GSettings *settings;
#ifdef HAVE_LIBWACOM
WacomDevice *wacom_device;
@@ -3119,20 +3118,12 @@ meta_display_request_pad_osd (MetaDisplay *display,
if (!layout_path || !settings)
return;
- if (logical_monitor)
- {
- monitor_idx =
- meta_screen_get_monitor_index_for_rect (display->screen,
- &logical_monitor->rect);
- }
- else
- {
- monitor_idx = meta_screen_get_current_monitor (display->screen);
- }
+ if (!logical_monitor)
+ logical_monitor = meta_screen_get_current_logical_monitor (display->screen);
g_signal_emit (display, display_signals[SHOW_PAD_OSD], 0,
pad, settings, layout_path,
- edition_mode, monitor_idx, &osd);
+ edition_mode, logical_monitor->number, &osd);
if (osd)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]