Questions tagged [android-homebutton]

The home button in the android Operating System

This button is used to get back to the Home screen on the android enabled smartphones.

350 questions
205
votes
25 answers

Display back button on action bar

I'm trying to display a Back button on the Action bar to move previous page/activity or to the main page (first opening). And I can not do it. my code. ActionBar actionBar = getActionBar(); actionBar.setHomeButtonEnabled(true); the code is in…
Dany Maor
  • 2,391
  • 2
  • 18
  • 26
103
votes
18 answers

Detect home button press in android

This has been driving me nuts for a while now. Is there any way of reliably detecting if the home button has been pressed in an android application? Failing that, is there a robust way of telling what caused an activity to go into onPause? i.e Can…
Dean Wild
  • 5,886
  • 3
  • 38
  • 45
35
votes
5 answers

How to disable the home key

I'd like to lock the screen. I want to disable the home key and only use the back key. How do I accomplish this?
pengwang
  • 19,536
  • 34
  • 119
  • 168
25
votes
3 answers

Clicking app icon doesn't trigger onOptionsItemSelected()

I'm currently working on an Android app. I would like to use the app icon in the action bar to navigate to the "home" activity. I read on this page that all that needs to be done is to add an onOptionsItemSelected and look for the id…
Nait
  • 1,055
  • 1
  • 14
  • 19
23
votes
4 answers

Android: change default Home Application

for some specific requirement I am required to change Android Default Home application with my customized Home application ( a setting inside my app that will toggle default home = my application or previous home) I don't want the user to travel…
Waza_Be
  • 39,407
  • 49
  • 186
  • 260
23
votes
3 answers

How to add "menu" indicator next to Action Bar's app icon?

At least Gmail and Youtube Android apps use a side menu (navigation drawer?) that opens by swiping, or by clicking the app icon (home button): Is the menu indicator / icon in the screenshot above a ready-made part of Android SDK? (Or a custom icon…
17
votes
6 answers

How to disable home button in Android like lock screen apps do?

I know this question is asked many times but I found that none of the solution is working. I tried the code given below... protected void onPause() { super.onPause(); Intent intent = new Intent(this,LockActivity.class); …
Ruag
  • 189
  • 1
  • 2
  • 15
15
votes
3 answers

Lock Screen detect home button

I recently downloaded the ACDisplay lock screen app: https://play.google.com/store/apps/details?id=com.achep.acdisplay The application shows an overlay on my device while also at the same time detecting home button click on the activity so that i…
user2511882
  • 9,022
  • 10
  • 51
  • 59
15
votes
2 answers

Android application restarts when opened by clicking the application icon

I am new to the Android development world and I've built a simple "Hello World" app. First, activity requests a text. When the "Go" button is clicked, the app launches the second activity displaying the input text. If I click the HOME button and…
14
votes
5 answers

Disable home button in android toddler app?

I've developed and app that is a slide show of pictures which each play a sound when you tap them. It's like a picture book for ages 2-4. The problem is, since android won't let you capture a home button press and essentially disable it, when…
cmerrell
  • 503
  • 3
  • 7
  • 16
13
votes
8 answers

Android emulator(Android Studio) Home button not working and giving logcat - I/WindowManager: Not starting activity because user setup is in progress

Started emulator from Android Studio and it's Home button not working. When I press Home button, in logcat I can see I/WindowManager: Not starting activity because user setup is in progress: Intent { act=android.intent.action.MAIN…
11
votes
1 answer

Android - Is It possible to disable the long click of home button to avoid the task manager?

I am looking for a way to disable the task manager window once I long press on the home button. I managed to disable other device keys (such as volume, menu etc) and the normal click on the home button as I am the default launcher, but I don't know…
Amir
  • 153
  • 1
  • 1
  • 9
10
votes
3 answers

Android Toolbar with both home and back button

Is it possible to display both home icon and back icon in the toolbar? 1) Is it possible change the order of display of back button icon and home icon. Currently it displays the arrow button first and then the logo (home button) 2) Second…
10
votes
1 answer

Hiding Home and Back button in Android

I would like my app to hide the Home and Back button which is show at bottom of activity. I was able to hide the title bar but I am not able to do for Home and Back button. Is it possible to do it?
ik024
  • 3,566
  • 7
  • 38
  • 61
9
votes
3 answers

Home button disable

I do know that it is ill advice to take control of the HOME button for users. But I'm developing a android lockdown application for educational purposes. I was browsing the site and came upon this link on disabling the home button. @override public…
edyim
  • 145
  • 1
  • 3
  • 9
1
2 3
23 24