Click here to Skip to main content
15,885,757 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello,

I'm working on a chatting application for visually impaired people and so I want to make it easy for them to look up the application and open it.

I'm thinking about sliding my phone's screen from bottom to top to open the application. Can any one provide me a code to do this ?
Posted
Comments
Richard MacCutchan 28-Oct-14 13:40pm    
Applications are opened by tapping on them in the window showing their icon. You would need to modify the basic Android OS to change this.

1 solution

To my knowledge you can't open your app when you slide open your device, but you can use the sliding feature in your app if you want.

The name of the View (Android speak for a UI widget) is a SlidingDrawer.

You use the View by adding code to the DrawerOpen and DrawerClose events.

XML
private SlidingDrawer _slidingDrawer;
 _slidingDrawer = Activity.FindViewById<SlidingDrawer>(Resource.Id.SlidingDrawer);


_slidingDrawer.DrawerOpen += (o, e) => { //add your code here}
_slidingDrawer.DrawerClose += (o, e) => { //add your code here}


More information can be found here http://developer.android.com/reference/android/widget/SlidingDrawer.html[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900