Discussion Forums  >  Plugins, Customizing, Source Code

Replies: 1    Views: 42

QC
Aspiring developer
Profile
Posts: 50
Reg: Apr 20, 2013
Milwaukee, WI
6,650
02/17/14 04:12 PM (11 years ago)

set different focuses on buttons in BT - table layout

I want to be able to set different focuses for buttons in BT using the grid or table layout. What I would like it when the user hoovers over the button for the state to change. this is in my menu_button.xml, sixth line down I put in a state.xml <?xml version="1.0" encoding="utf-8"?> <!-- android:background="android:color/transparent" --> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:id="@+id/containerView" --> android:background="@drawable/state" android:padding="0dip" android:layout_margin="0dip" android:contentDescription="@+id/titleText" tools:context=".Animation" android:layout_width="wrap_content" android:layout_height="wrap_content"> state.xml is in my res/drawables <?xml version="1.0" encoding="utf-8"?> <!-- Copyright (C) 2007 The Android Open Source Project --> <selector xmlns:android="http://schemas.android.com/apk/res/android" android:shape="line"> <item android:state_pressed="true" android:color="#7700ff00" /> <item android:state_focused="true" android:color="#77ffff00" /> <item android:color="#7f00" /> </selector> Thanks
 
Kittsy
buzztouch Evangelist
Profile
Posts: 2251
Reg: Feb 22, 2012
Liverpool
31,360
like
02/17/14 04:31 PM (11 years ago)
How do you hover with a touch screen device
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.