Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ActionView doesn't center when width and height are changed during orientation change #11

Open
ssppgit opened this issue Oct 15, 2014 · 1 comment
Labels

Comments

@ssppgit
Copy link

ssppgit commented Oct 15, 2014

Hi!

I have using ActionView in my layout. I have define width and height in dimens.xml for landscape and portrait.

<at.markushi.ui.ActionView
        android:id="@+id/action"
        android:layout_width="@dimen/action_size"
        android:layout_height="@dimen/action_size"
        android:padding="16dp"
        android:background="#FF0000"
        app:av_action="drawer"
        app:av_color="@android:color/white"/>

action_size is 56dp for portrait and 48dp for landscape.

When i run my app i see well the ActionView. However if i change orientation of my device, Image of actionView doesn't center well. I don't know why because if a run my app only in landscape mode i see well the actionView.

You can see it in this image.

action

Any idea? Thanks!

@markushi markushi added the bug label Oct 15, 2014
@ali-star
Copy link

i use this and it's work fine:

<LinearLayout
            android:id="@+id/menu_monitor"
            android:layout_width="match_parent"
            android:layout_height="56dp"
            android:gravity="center"
            android:orientation="vertical" >

            <at.markushi.ui.ActionView
                android:id="@+id/action"
                android:layout_width="56dp"
                android:layout_height="56dp"
                android:padding="16dip" />

</LinearLayout>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants