backends/native: update cursor on resume

As mentioned in a previous commit, the proprietary NVIDIA
driver garbles memory on suspend. That behavior, means that
the cursor gets corrupted on suspend.

This commit forces the cursor to redraw itself when the
logind session becomes active (on VT switch and resume).
This commit is contained in:
Ray Strode 2019-01-15 10:29:55 -05:00
parent e4339aed83
commit 2a2697910a
3 changed files with 4 additions and 2 deletions

View File

@ -655,6 +655,7 @@ void meta_backend_native_resume (MetaBackendNative *native)
if (cogl_has_feature (cogl_context, COGL_FEATURE_ID_UNSTABLE_TEXTURES))
{
clutter_clear_glyph_cache ();
meta_screen_update_cursor (display->screen);
g_signal_emit_by_name (display, "gl-video-memory-purged");
}

View File

@ -122,8 +122,6 @@ void meta_screen_foreach_window (MetaScreen *scree
MetaScreenWindowFunc func,
gpointer data);
void meta_screen_update_cursor (MetaScreen *screen);
void meta_screen_update_tile_preview (MetaScreen *screen,
gboolean delay);
void meta_screen_hide_tile_preview (MetaScreen *screen);

View File

@ -125,4 +125,7 @@ void meta_screen_override_workspace_layout (MetaScreen *screen,
void meta_screen_set_cursor (MetaScreen *screen,
MetaCursor cursor);
void meta_screen_update_cursor (MetaScreen *screen);
#endif