API: screen: Remove gdk_screen_make_display_name()

It's identical to gdk_display_get_name().
This commit is contained in:
Benjamin Otte 2016-09-28 02:52:25 +02:00
parent 6b9e481e38
commit 9be9e00a0e
10 changed files with 0 additions and 89 deletions

View File

@ -207,7 +207,6 @@ gdk_screen_get_display
gdk_screen_get_number
gdk_screen_list_visuals
gdk_screen_get_toplevel_windows
gdk_screen_make_display_name
gdk_screen_get_n_monitors
gdk_screen_get_primary_monitor
gdk_screen_get_monitor_geometry

View File

@ -154,12 +154,6 @@ gdk_broadway_screen_is_composited (GdkScreen *screen)
}
static gchar *
gdk_broadway_screen_make_display_name (GdkScreen *screen)
{
return g_strdup ("browser");
}
static void
gdk_broadway_screen_broadcast_client_message (GdkScreen *screen,
GdkEvent *event)
@ -191,7 +185,6 @@ gdk_broadway_screen_class_init (GdkBroadwayScreenClass *klass)
screen_class->get_display = gdk_broadway_screen_get_display;
screen_class->get_root_window = gdk_broadway_screen_get_root_window;
screen_class->is_composited = gdk_broadway_screen_is_composited;
screen_class->make_display_name = gdk_broadway_screen_make_display_name;
screen_class->broadcast_client_message = gdk_broadway_screen_broadcast_client_message;
screen_class->get_setting = gdk_broadway_screen_get_setting;
screen_class->get_rgba_visual = gdk_broadway_screen_get_rgba_visual;

View File

@ -483,25 +483,6 @@ gdk_screen_is_composited (GdkScreen *screen)
return GDK_SCREEN_GET_CLASS (screen)->is_composited (screen);
}
/**
* gdk_screen_make_display_name:
* @screen: a #GdkScreen
*
* Determines the name to pass to gdk_display_open() to get
* a #GdkDisplay with this screen as the default screen.
*
* Returns: a newly allocated string, free with g_free()
*
* Since: 2.2
**/
gchar *
gdk_screen_make_display_name (GdkScreen *screen)
{
g_return_val_if_fail (GDK_IS_SCREEN (screen), NULL);
return GDK_SCREEN_GET_CLASS (screen)->make_display_name (screen);
}
/**
* gdk_screen_get_setting:
* @screen: the #GdkScreen where the setting is located

View File

@ -57,8 +57,6 @@ GDK_AVAILABLE_IN_ALL
GList * gdk_screen_list_visuals (GdkScreen *screen);
GDK_AVAILABLE_IN_ALL
GList * gdk_screen_get_toplevel_windows (GdkScreen *screen);
GDK_AVAILABLE_IN_ALL
gchar * gdk_screen_make_display_name (GdkScreen *screen);
GDK_AVAILABLE_IN_ALL
GdkScreen *gdk_screen_get_default (void);

View File

@ -63,7 +63,6 @@ struct _GdkScreenClass
GdkVisual * (* get_system_visual) (GdkScreen *screen);
GdkVisual * (* get_rgba_visual) (GdkScreen *screen);
gboolean (* is_composited) (GdkScreen *screen);
gchar * (* make_display_name) (GdkScreen *screen);
void (* broadcast_client_message) (GdkScreen *screen,
GdkEvent *event);
gboolean (* get_setting) (GdkScreen *screen,

View File

@ -419,13 +419,6 @@ gdk_mir_screen_is_composited (GdkScreen *screen)
return TRUE;
}
static gchar *
gdk_mir_screen_make_display_name (GdkScreen *screen)
{
//g_printerr ("gdk_mir_screen_make_display_name\n");
return NULL; // FIXME
}
static void
gdk_mir_screen_broadcast_client_message (GdkScreen *screen,
GdkEvent *event)
@ -804,7 +797,6 @@ gdk_mir_screen_class_init (GdkMirScreenClass *klass)
screen_class->get_system_visual = gdk_mir_screen_get_system_visual;
screen_class->get_rgba_visual = gdk_mir_screen_get_rgba_visual;
screen_class->is_composited = gdk_mir_screen_is_composited;
screen_class->make_display_name = gdk_mir_screen_make_display_name;
screen_class->broadcast_client_message = gdk_mir_screen_broadcast_client_message;
screen_class->get_setting = gdk_mir_screen_get_setting;
screen_class->visual_get_best_depth = gdk_mir_screen_visual_get_best_depth;

View File

@ -452,12 +452,6 @@ _gdk_quartz_screen_get_monitor_scale_factor (GdkScreen *screen,
return scale_factor;
}
static gchar *
gdk_quartz_screen_make_display_name (GdkScreen *screen)
{
return g_strdup (gdk_display_get_name (_gdk_display));
}
static gboolean
gdk_quartz_screen_is_composited (GdkScreen *screen)
{
@ -487,7 +481,6 @@ gdk_quartz_screen_class_init (GdkQuartzScreenClass *klass)
screen_class->get_monitor_geometry = gdk_quartz_screen_get_monitor_geometry;
screen_class->get_monitor_workarea = gdk_quartz_screen_get_monitor_workarea;
screen_class->is_composited = gdk_quartz_screen_is_composited;
screen_class->make_display_name = gdk_quartz_screen_make_display_name;
screen_class->broadcast_client_message = _gdk_quartz_screen_broadcast_client_message;
screen_class->get_setting = _gdk_quartz_screen_get_setting;
screen_class->get_rgba_visual = _gdk_quartz_screen_get_rgba_visual;

View File

@ -135,12 +135,6 @@ gdk_wayland_screen_is_composited (GdkScreen *screen)
return TRUE;
}
static gchar *
gdk_wayland_screen_make_display_name (GdkScreen *screen)
{
return g_strdup (gdk_display_get_name (GDK_WAYLAND_SCREEN (screen)->display));
}
static void
gdk_wayland_screen_broadcast_client_message (GdkScreen *screen,
GdkEvent *event)
@ -806,7 +800,6 @@ _gdk_wayland_screen_class_init (GdkWaylandScreenClass *klass)
screen_class->get_system_visual = gdk_wayland_screen_get_system_visual;
screen_class->get_rgba_visual = gdk_wayland_screen_get_rgba_visual;
screen_class->is_composited = gdk_wayland_screen_is_composited;
screen_class->make_display_name = gdk_wayland_screen_make_display_name;
screen_class->broadcast_client_message = gdk_wayland_screen_broadcast_client_message;
screen_class->get_setting = gdk_wayland_screen_get_setting;
screen_class->visual_get_best_depth = gdk_wayland_screen_visual_get_best_depth;

View File

@ -386,12 +386,6 @@ gdk_win32_screen_get_root_window (GdkScreen *screen)
return GDK_WIN32_SCREEN (screen)->root_window;
}
static gchar *
gdk_win32_screen_make_display_name (GdkScreen *screen)
{
return g_strdup (gdk_display_get_name (_gdk_display));
}
static gboolean
gdk_win32_screen_is_composited (GdkScreen *screen)
{
@ -527,7 +521,6 @@ gdk_win32_screen_class_init (GdkWin32ScreenClass *klass)
screen_class->get_display = gdk_win32_screen_get_display;
screen_class->get_root_window = gdk_win32_screen_get_root_window;
screen_class->is_composited = gdk_win32_screen_is_composited;
screen_class->make_display_name = gdk_win32_screen_make_display_name;
screen_class->get_setting = _gdk_win32_screen_get_setting;
screen_class->get_system_visual = gdk_win32_screen_get_system_visual;
screen_class->get_rgba_visual = gdk_win32_screen_get_rgba_visual;

View File

@ -1052,35 +1052,6 @@ _gdk_x11_screen_process_owner_change (GdkScreen *screen,
#endif
}
static gchar *
substitute_screen_number (const gchar *display_name,
gint screen_number)
{
GString *str;
gchar *p;
str = g_string_new (display_name);
p = strrchr (str->str, '.');
if (p && p > strchr (str->str, ':'))
g_string_truncate (str, p - str->str);
g_string_append_printf (str, ".%d", screen_number);
return g_string_free (str, FALSE);
}
static gchar *
gdk_x11_screen_make_display_name (GdkScreen *screen)
{
const gchar *old_display;
old_display = gdk_display_get_name (gdk_screen_get_display (screen));
return substitute_screen_number (old_display,
gdk_x11_screen_get_screen_number (screen));
}
static gboolean
gdk_x11_screen_get_setting (GdkScreen *screen,
const gchar *name,
@ -1385,7 +1356,6 @@ gdk_x11_screen_class_init (GdkX11ScreenClass *klass)
screen_class->get_system_visual = _gdk_x11_screen_get_system_visual;
screen_class->get_rgba_visual = gdk_x11_screen_get_rgba_visual;
screen_class->is_composited = gdk_x11_screen_is_composited;
screen_class->make_display_name = gdk_x11_screen_make_display_name;
screen_class->get_setting = gdk_x11_screen_get_setting;
screen_class->visual_get_best_depth = _gdk_x11_screen_visual_get_best_depth;
screen_class->visual_get_best_type = _gdk_x11_screen_visual_get_best_type;