summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZenWalker <[email protected]>2017-08-03 23:26:38 +0200
committerraveit65 <[email protected]>2017-08-05 17:12:05 +0200
commit421ced2a99d9ce2b6b32258a2d11c86f1e90c353 (patch)
tree2fed015e2388e9f7cd307c81bca0d4e686e584db
parent4cfcd65955e4ee3f22818bf5540196fb38c8bce5 (diff)
downloadmate-desktop-421ced2a99d9ce2b6b32258a2d11c86f1e90c353.tar.bz2
mate-desktop-421ced2a99d9ce2b6b32258a2d11c86f1e90c353.tar.xz
avoid deprecated gdk_screen_make_display_name
-rw-r--r--libmate-desktop/mate-desktop-item.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/libmate-desktop/mate-desktop-item.c b/libmate-desktop/mate-desktop-item.c
index e7b2533..b86ab02 100644
--- a/libmate-desktop/mate-desktop-item.c
+++ b/libmate-desktop/mate-desktop-item.c
@@ -1678,11 +1678,12 @@ static char **
make_environment_for_screen (GdkScreen *screen,
char **envp)
{
- char **retval;
- char **freeme;
- char *display_name;
- int display_index = -1;
- int i, env_len;
+ GdkDisplay *display;
+ char **retval;
+ char **freeme;
+ char *display_name;
+ int display_index = -1;
+ int i, env_len;
g_return_val_if_fail (GDK_IS_SCREEN (screen), NULL);
@@ -1705,7 +1706,8 @@ make_environment_for_screen (GdkScreen *screen,
retval = g_new (char *, env_len + 1);
retval [env_len] = NULL;
- display_name = gdk_screen_make_display_name (screen);
+ display = gdk_screen_get_display (screen);
+ display_name = g_strdup (gdk_display_get_name (display));
for (i = 0; i < env_len; i++)
if (i == display_index)