stack: respect gtk-enable-animations setting
https://bugzilla.gnome.org/show_bug.cgi?id=712632
This commit is contained in:
@ -45,6 +45,9 @@
|
|||||||
* These animations respect the #GtkSettings::gtk-enable-animations
|
* These animations respect the #GtkSettings::gtk-enable-animations
|
||||||
* setting.
|
* setting.
|
||||||
*
|
*
|
||||||
|
* These animations respect the #GtkSettings::gtk-enable-animations
|
||||||
|
* setting.
|
||||||
|
*
|
||||||
* The GtkStack widget was added in GTK+ 3.10.
|
* The GtkStack widget was added in GTK+ 3.10.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@ -827,6 +830,14 @@ static GtkStackTransitionType
|
|||||||
effective_transition_type (GtkStack *stack,
|
effective_transition_type (GtkStack *stack,
|
||||||
GtkStackTransitionType transition_type)
|
GtkStackTransitionType transition_type)
|
||||||
{
|
{
|
||||||
|
gboolean animations_enabled;
|
||||||
|
|
||||||
|
g_object_get (gtk_widget_get_settings (GTK_WIDGET (stack)),
|
||||||
|
"gtk-enable-animations", &animations_enabled,
|
||||||
|
NULL);
|
||||||
|
if (!animations_enabled)
|
||||||
|
return GTK_STACK_TRANSITION_TYPE_NONE;
|
||||||
|
|
||||||
if (gtk_widget_get_direction (GTK_WIDGET (stack)) == GTK_TEXT_DIR_RTL)
|
if (gtk_widget_get_direction (GTK_WIDGET (stack)) == GTK_TEXT_DIR_RTL)
|
||||||
{
|
{
|
||||||
if (transition_type == GTK_STACK_TRANSITION_TYPE_SLIDE_LEFT)
|
if (transition_type == GTK_STACK_TRANSITION_TYPE_SLIDE_LEFT)
|
||||||
|
|||||||
Reference in New Issue
Block a user