Don't use g_slist_next in the x11 backend

We generally use ->next directly.
This commit is contained in:
Matthias Clasen 2015-10-19 20:31:57 -04:00
parent 364d1a574b
commit 4d59233ba9
4 changed files with 8 additions and 8 deletions

View File

@ -155,13 +155,13 @@ _gdk_x11_cursor_display_finalize (GdkDisplay *display)
/* Remove this item from the list */
*(itemp) = item->next;
olditem = item;
item = g_slist_next (item);
item = item->next;
g_slist_free_1 (olditem);
}
else
}
else
{
itemp = &(item->next);
item = g_slist_next (item);
item = item->next;
}
}
}

View File

@ -474,7 +474,7 @@ gdk_x11_device_core_window_at_position (GdkDevice *device,
pointer_window = None;
screen = gdk_display_get_screen (display, 0);
toplevels = gdk_screen_get_toplevel_windows (screen);
for (list = toplevels; list != NULL; list = g_list_next (list))
for (list = toplevels; list != NULL; list = list->next)
{
window = GDK_WINDOW (list->data);
impl = GDK_WINDOW_IMPL_X11 (window->impl);

View File

@ -544,7 +544,7 @@ gdk_x11_device_xi2_window_at_position (GdkDevice *device,
screen = gdk_display_get_screen (display, 0);
toplevels = gdk_screen_get_toplevel_windows (screen);
for (list = toplevels; list != NULL; list = g_list_next (list))
for (list = toplevels; list != NULL; list = list->next)
{
window = GDK_WINDOW (list->data);
xwindow = GDK_WINDOW_XID (window);

View File

@ -3864,7 +3864,7 @@ gdk_x11_window_set_icon_list (GdkWindow *window,
n++;
size += 2 + width * height;
l = g_list_next (l);
l = l->next;
}
data = g_malloc (size * sizeof (gulong));
@ -3903,7 +3903,7 @@ gdk_x11_window_set_icon_list (GdkWindow *window,
}
}
l = g_list_next (l);
l = l->next;
n--;
}