gdk/wayland: Use g_warning_once for cursor scale mismatches.
This commit is contained in:
@@ -224,7 +224,6 @@ _gdk_wayland_cursor_get_buffer (GdkCursor *cursor,
|
||||
{
|
||||
struct wl_cursor_image *image;
|
||||
int cursor_scale;
|
||||
gboolean warned = FALSE;
|
||||
|
||||
if (image_index >= wayland_cursor->wl_cursor->image_count)
|
||||
{
|
||||
@@ -240,13 +239,9 @@ _gdk_wayland_cursor_get_buffer (GdkCursor *cursor,
|
||||
while ((image->width % cursor_scale != 0) ||
|
||||
(image->height % cursor_scale != 0))
|
||||
{
|
||||
if (!warned)
|
||||
{
|
||||
g_warning (G_STRLOC " cursor image size (%dx%d) not an integer"
|
||||
"multiple of scale (%d)", image->width, image->height,
|
||||
cursor_scale);
|
||||
warned = TRUE;
|
||||
}
|
||||
g_warning_once (G_STRLOC " cursor image size (%dx%d) not an integer"
|
||||
"multiple of scale (%d)", image->width, image->height,
|
||||
cursor_scale);
|
||||
cursor_scale--;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user