Hide navigation bar on rooted android device - android

I have a custom rooted android tablet working on Android M version. We built a kiosk application and next step is removing navigation bar completely, while our application is working. Also, when administrator close our application, navigation bar should appear again.
Before asking this question, I researched on Internet and find a lot of people have this problem. However, answers to theirs question were generally, making application to work in full-screen mode or in immersive full-screen mode.
These answers didn't help me at all, because user still can fling on screen and navigation bar would show again. These solutions are probably the best that can be done with an unrooted device, but in my case I need a better solution and my device is rooted.
Also, I saw this answer link, but after using this command my desktop went black, and couldn't reboot android system again. Happily I have recovery USB so my device is working again. :)
I found another answer link, and like others, didn't help me because I need to reboot system after adding line of code (qemu.hw.mainkeys = 1). Also, solution that I looking for is fully dynamical and done by code.
I am really convinced that this isn't mission impossible, because we had old tablet (also rooted) with button in back, which can hide and show navigation bar without rebooting it.
Any help is appreciated.

I can't help you with your problem, but provide a little more information.
The company im working for is using devices in kiosk mode, but we have custom android devices from a hardware producer, which provides a custom HAL interface. We can set the kiosk mode via that interface.
My guess is it cant be done easily, if it was easy, we would have not gone that way. Hope it helps.

Related

Create custom LockScreen for Android

I'm trying to create a custom lockscreen for Android version 7.1.1. (Nougat). I know that there are a lot answers on how to create a custom lockscreen, but whatever code I try to use, it's not really working.
The problem appears because of using deprecated methods. The app crushes, and there are no methods to replace the deprecated ones.
Does anyone know a way that this still works?
These are some of the links I've tried to use (there were a few older ones also but I didn't save them):
how to make our own lock screen in android instead of default lock screen
https://github.com/thomasvidas/Simple-Lockscreen/tree/master
developing an android lock screen application
Create custom lockscreen for android 4.0 or above?
At the end I managed to make this app working. My biggest problem was to put my device in kiosk mode (disabling hardware buttons when the lockscreen is displayed). The solution that worked for me was enabling device owner mode using Android Debug Bridge. It wasn't the best solution, but it was the most acceptable one for this project.
Here are some of the links that I used to achieve this:
https://documentation.meraki.com/SM/Device_Enrollment/Enabling_Device_Owner_Mode_using_Android_Debug_Bridge_(ADB)
http://www.sureshjoshi.com/mobile/android-kiosk-mode-without-root/

How can I remove the new do-nothing "settings" control from my Marmalade Android app on HTC One (Credo only?)?

I'm working on my first (C++/IwNUI) Marmalade app, which so far works fine, but on Monday one of my devices (an HTC One Android phone, Credo Mobile) had a system update, after which my app, and only my app, now shows what seems to be a "settings" control on top of my app, which can be moved around, but does nothing but clock taps to the app where it is. It's a grey circle with three dots in it, which appears immediately when my app starts to load. Another Android test machine (Samsung Galaxy) does not show this control on my app.
Has anyone else seen this? How might I get it not to appear?
I have asked on the Marmalade forums with no response, and searched here and on the web but I haven't seen any reference to it, so I assume it may be limited to some combination of Marmalade apps, HTC One, and/or Credo Mobile Android phones.
Update: This control appears (on this phone only) on all of the Marmalade example apps I have built too, including IwUI, IwNUI, and plain demos like IwHTTPExample.
Even though this is very specific, I wonder if anyone knows a programmatic way in Marmalade C++ for me to at least get such a settings control to hide or go away?
I found a way to make it go away: "Add android:targetSdkVersion="11" (or higher) to your element." in the settings file which in my Marmalade project is called AndroidManifest.xml.
It seems like this may be a bug where it thinks there is an "overflow" of a title/menu-bar which isn't even there in these apps. By targeting a later version, it uses a newer "holo" menu, which doesn't do this.
If someone has a better explanation, I'll wait to mark that as the accepted answer.
In case it may help future people confused by all this, here's how I found this. Jared's answer led me to study my Marmalade config files, and the Android developer site where I found some general somewhat relevant info about what this is, and to search some different terms on the Marmalade forums, which got me to a relevant question I had missed on the Marmalade community answer pages, which led me to this page which had the suggestion which has the desired effect.
I am guessing you created a new project. Are you seeing this "settings"?
This is automatically added in every new app. Check your res -> menu folder. You can remove the "fake" options menu if you like.
Samsung will show this menu if you hit the menu button on the bottom left of the device.
HTC devices will show the options menu in the ActionBar/ToolBar.

Immersive like feature in JB and ICS

I am developing an Application where I need to go completely full screen. In kitkat its very easy by using Immersive tag. But since not all devices support kitkat I need to take JB and ICS (atleast) into consideration.
Well although there is a way of hiding navigation bar and status bar in JB and ICS it becomes visible as soon as the user interacts. This certainly does not looks good. It also takes one extra touch.
I did a lot of searching on net and was surprised that there is no way we can achieve it. I was hoping to find some trick or hack but nothing.
I am pretty sure that before kitkat came there were games which used full screen so I guess there should be a way (like Temple Run and Andgry Birds). Can some one please guide me in correct direction.
P.S: I am looking solution for devices which are not rooted.
Thanks :)
Use a full screen theme, or set it from code as described here https://developer.android.com/training/system-ui/status.html
As I already pointed out in the comments, this will give you full screen. Not the immersive mode as seen on KitKat where the user can easily unhide the status bar. If you're going with the theme approach it's probably best to set a not full screen theme on API19+ (KitKat) and tell it to use Immersive mode from there on.

Removing notificationbar for kiosk mode

I am trying to build an android app in kiosk-mode in Android 4.2.2 (Jelly Bean). What I have achieved till now is to make the application as full screen and also handled the home and back buttons. However, my problem is, I want to remove the status/notification bar. I don't want the user to access any other settings through it. I have tried out many ways including the usage of different flags available in android WindowManager for having a screen devoid of the notification bar. However, none were helpful for that.
I have read about apps like Surelock which serve this purpose. Therefore, at least I know that there is something which can be done, except rooting, to remove the notification bar.
Can anyone please help me on this?

Disable system/combo bar Android ICS with out rooting

I have searched high and low, all the while people telling me that, "no it is impossible to completely surpress the navigation/combo bar on an ICS tablet without rooting it.. and then i find there is an app on the market called Surelock that does exactly this.. Unfortunately i am building a launcher app myself so i can't use their launcher app, but the big question is HOW do they do it? anyone?
Whatever SureLock is doing is exploiting some security hole. Someday, I will take the time to find out what they are doing and will work to get the hole fixed.

Categories

Resources