]> www.fi.muni.cz Git - evince.git/blobdiff - libview/ev-transition-animation.c
Fixes typo
[evince.git] / libview / ev-transition-animation.c
index 148b4c7734eccaba3e576e1f1ec5ef060ce722e3..efcb509e24108af97fc38de2331171593d057ea5 100644 (file)
@@ -556,8 +556,6 @@ ev_transition_animation_paint (EvTransitionAnimation *animation,
        g_return_if_fail (EV_IS_TRANSITION_ANIMATION (animation));
 
        priv = EV_TRANSITION_ANIMATION_GET_PRIVATE (animation);
-       g_object_get (priv->effect, "type", &type, NULL);
-       progress = ev_timeline_get_progress (EV_TIMELINE (animation));
 
        if (!priv->dest_surface) {
                /* animation is still not ready, paint the origin surface */
@@ -565,6 +563,9 @@ ev_transition_animation_paint (EvTransitionAnimation *animation,
                return;
        }
 
+       g_object_get (priv->effect, "type", &type, NULL);
+       progress = ev_timeline_get_progress (EV_TIMELINE (animation));
+
        switch (type) {
        case EV_TRANSITION_EFFECT_REPLACE:
                /* just paint the destination slide */
@@ -678,5 +679,5 @@ ev_transition_animation_ready (EvTransitionAnimation *animation)
 
        priv = EV_TRANSITION_ANIMATION_GET_PRIVATE (animation);
 
-       return (priv->origin_surface && priv->dest_surface);
+       return (priv->origin_surface != NULL);
 }