Showing posts with label If it possible to do behavior like setCanceledOnTouchOutside of dialog on Android. Show all posts
Showing posts with label If it possible to do behavior like setCanceledOnTouchOutside of dialog on Android. Show all posts

Thursday, May 2, 2013

[android help] If it possible to do behavior like setCanceledOnTouchOutside of dialog on Android

If it possible to do behavior like setCanceledOnTouchOutside of dialog on Android - Stack Overflow







Tell me more ×

Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.

















My layout xml file as below:




android:id="@+id/RelativeLayout1"
android:layout_width="match_parent"
android:layout_height="match_parent" >

android:id="@+id/action_bar_item_list"
android:layout_above="@+id/mybutton"
android:layout_width="match_parent"
android:layout_height="wrap_content" >


android:id="@+id/mybutton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:layout_alignParentRight="true"
android:text="Button" />

android:id="@+id/messagelayout"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:orientation="vertical" >

android:id="@+id/message"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Large Text"
android:textAppearance="?android:attr/textAppearanceLarge" />






If mybutton be clicked, messagelayout will be set to visible.
And while messagelayout is visible, I want to do a function such as setCanceledOnTouchOutside of dialog do.
While user touch screen beside messagelayout, it will set messagelayout to gone, and not do any other things.
If I don't want to use a dialog, how can I do it?
















Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.










default






.

stackoverflow.comm

Google Voice on T-Mobile? [General]

Google Voice on T-Mobile? So I recently switched from a GNex on Verizon to a Moto X DE on T-Mobile. I had always used Google Voice for my v...