st-scroll-view: properly check if the scrollbars are visible

We don't set :visible on the scrollbars, but use booleans to track
if they are visible. Thus check the booleans instead of the actor's
properties when allocating the scrollbars.

https://bugzilla.gnome.org/show_bug.cgi?id=704265
This commit is contained in:
Emilio Pozuelo Monfort 2013-07-15 17:42:43 +02:00
parent a8fe063726
commit cfecd063c9

View File

@ -598,7 +598,7 @@ st_scroll_view_allocate (ClutterActor *actor,
*/ */
/* Vertical scrollbar */ /* Vertical scrollbar */
if (CLUTTER_ACTOR_IS_VISIBLE (priv->vscroll)) if (vscrollbar_visible)
{ {
if (clutter_actor_get_text_direction (actor) == CLUTTER_TEXT_DIRECTION_RTL) if (clutter_actor_get_text_direction (actor) == CLUTTER_TEXT_DIRECTION_RTL)
{ {
@ -617,7 +617,7 @@ st_scroll_view_allocate (ClutterActor *actor,
} }
/* Horizontal scrollbar */ /* Horizontal scrollbar */
if (CLUTTER_ACTOR_IS_VISIBLE (priv->hscroll)) if (hscrollbar_visible)
{ {
if (clutter_actor_get_text_direction (actor) == CLUTTER_TEXT_DIRECTION_RTL) if (clutter_actor_get_text_direction (actor) == CLUTTER_TEXT_DIRECTION_RTL)
{ {