shell-global: Remove hacks around clutter_event_get_current_time()
clutter_event_get_current_time() has been fixed upstream as part of reentrant bug fixes, so there's no need for these shenanigans. https://bugzilla.gnome.org/show_bug.cgi?id=690665
This commit is contained in:
parent
ab638a4f54
commit
5566aa4588
@ -1415,7 +1415,7 @@ shell_global_get_current_time (ShellGlobal *global)
|
|||||||
from some Clutter event callbacks.
|
from some Clutter event callbacks.
|
||||||
|
|
||||||
clutter_get_current_event_time() will return the correct time
|
clutter_get_current_event_time() will return the correct time
|
||||||
from a Clutter event callback, but may return an out-of-date
|
from a Clutter event callback, but may return CLUTTER_CURRENT_TIME
|
||||||
timestamp if called at other times.
|
timestamp if called at other times.
|
||||||
|
|
||||||
So we try meta_display_get_current_time() first, since we
|
So we try meta_display_get_current_time() first, since we
|
||||||
@ -1425,17 +1425,9 @@ shell_global_get_current_time (ShellGlobal *global)
|
|||||||
|
|
||||||
time = meta_display_get_current_time (global->meta_display);
|
time = meta_display_get_current_time (global->meta_display);
|
||||||
if (time != CLUTTER_CURRENT_TIME)
|
if (time != CLUTTER_CURRENT_TIME)
|
||||||
return time;
|
return time;
|
||||||
/*
|
|
||||||
* We don't use clutter_get_current_event_time as it can give us a
|
|
||||||
* too old timestamp if there is no current event.
|
|
||||||
*/
|
|
||||||
clutter_event = clutter_get_current_event ();
|
|
||||||
|
|
||||||
if (clutter_event != NULL)
|
return clutter_get_current_event_time ();
|
||||||
return clutter_event_get_time (clutter_event);
|
|
||||||
else
|
|
||||||
return CLUTTER_CURRENT_TIME;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user