[mutter] Remove meta_monitor_manager_get_monitor_for_output() API



commit 18ec86bd9093f3decb3ee7de7fecae1b07997577
Author: Jonas Ådahl <jadahl gmail com>
Date:   Mon Jul 10 18:02:47 2017 +0800

    Remove meta_monitor_manager_get_monitor_for_output() API
    
    This function is replaced by an equivalent that takes a connector
    string.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=785381

 src/backends/meta-monitor-manager.c |   34 ----------------------------------
 src/meta/meta-monitor-manager.h     |    3 ---
 2 files changed, 0 insertions(+), 37 deletions(-)
---
diff --git a/src/backends/meta-monitor-manager.c b/src/backends/meta-monitor-manager.c
index ba00556..dd9d447 100644
--- a/src/backends/meta-monitor-manager.c
+++ b/src/backends/meta-monitor-manager.c
@@ -2814,40 +2814,6 @@ meta_monitor_manager_get_monitor_matrix (MetaMonitorManager *manager,
 }
 
 /**
- * meta_monitor_manager_get_monitor_for_output:
- * @manager: A #MetaMonitorManager
- * @id: A valid #MetaOutput id
- *
- * Returns: The monitor index or -1 if @id isn't valid or the output
- * isn't associated with a logical monitor.
- */
-gint
-meta_monitor_manager_get_monitor_for_output (MetaMonitorManager *manager,
-                                             guint               id)
-{
-  MetaOutput *output;
-  GList *l;
-
-  g_return_val_if_fail (META_IS_MONITOR_MANAGER (manager), -1);
-  g_return_val_if_fail (id < g_list_length (manager->outputs), -1);
-
-  output = g_list_nth_data (manager->outputs, id);
-  if (!output || !output->crtc)
-    return -1;
-
-  for (l = manager->logical_monitors; l; l = l->next)
-    {
-      MetaLogicalMonitor *logical_monitor = l->data;
-
-      if (meta_rectangle_contains_rect (&logical_monitor->rect,
-                                        &output->crtc->rect))
-        return logical_monitor->number;
-    }
-
-  return -1;
-}
-
-/**
  * meta_monitor_manager_get_monitor_for_connector:
  * @manager: A #MetaMonitorManager
  * @connector: A valid connector name
diff --git a/src/meta/meta-monitor-manager.h b/src/meta/meta-monitor-manager.h
index 81f8605..d902d9f 100644
--- a/src/meta/meta-monitor-manager.h
+++ b/src/meta/meta-monitor-manager.h
@@ -40,9 +40,6 @@ GType meta_monitor_manager_get_type (void);
 
 MetaMonitorManager *meta_monitor_manager_get  (void);
 
-gint meta_monitor_manager_get_monitor_for_output (MetaMonitorManager *manager,
-                                                  guint               id);
-
 gint meta_monitor_manager_get_monitor_for_connector (MetaMonitorManager *manager,
                                                      const char         *connector);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]