Weird ActionBarSherlock behavior when starting an Action Mode on Gingerbread - android

I'm using ActionBarSherlock in my android app, the theme is set to Sherlock.Light.DarkActionBar, when I run the app on ICS devices , everything looks ok,
but when I test it on Gingerbread (both emu and on multiple devices) the action bar looks weird, sometimes when it loses focus it becomes white.
I'm not using custom styles, so I can't quite understand what may be causing this.
Update:
I have noticed that this is actually happening each time I'm entering and exiting an Action Mode programmatically (StartActionMode).

I was able to resolve this problem, it occurred because I started and stopped the action mode very fast.

Related

Android Studio Action Bar wont leave

A white bar covering some of the commands in android studio will not disappear, The only way to make it go away is turn off the application it self, but when I turn it back on it comes back, How do I get rid of the bar while still in studio?
For me, these kind of issues are normally (Any ghost dialog) solved by rebooting my computer..

Android Studio floating action button's weird feature

I am making my own android application and came across a weird issue. I've got a few floating action buttons into my app and in the editor they look just fine. But when I upload this app to my phone or to the simulator, an other strange color appears which even moves when I touch the button. (the lighter blue is what I am talking about).
What is this feature and how can I turn this off?
Thank you for your answers in advance.

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?

DialogFragment behaves differently when invoked via ActionBar

I'm experiencing strange, perhaps version-specific behavior with my DialogFragment subclass when testing the following steps:
(1) Open the dialog
(2) Leave the app with either the Home key or the Recent Apps key
(3) Return to the app, and the dialog is no longer visible. It seems to be briefly, translucently visible behind the main activity.
(4) Rotate the device, and the dialog re-appears.
This bug occurs on my Asus TF700T pad running Android 4.2.1, and it does not occur on my Motorola Razr phone running Android 4.1.2 (which has a menu key rather than an overflow button). Moreover, it only occurs if the dialog is opened via the overflow menu - dialogs opened via ActionBar items do not exhibit this issue! And finally, the issue does not occur if you do an orientation change before pausing the activity.
I have found a very similar issue which includes depressing comments like "This is clearly an Android bug." There are associated bug reports. Please, say it ain't so...
My workaround for this issue is in onResume(): I check the FragmentManager for existing dialogs with findFragmentByTag; if any are not null I dismiss and re-show them. But I'd like to understand what's really going on here.
I guess the answer to this question is the Google bug report linked above. I changed my design to avoid the problem, so I have not tried the workaround someone there has posted.

trigger.io Android webview app - grey background appearing after keyboard closes or orientation change

I'm building an html5 wrapped iOS / Android app with Trigger.io.
I have a problem on Android with a grey background appearing on the screen in some occasions after the virtual keyboard has closed, or after the phone has changed orientation.
Example screenshots are shown below.
The grey background is after the end of my app's page. Sometimes it is visible for a split second, other times it stays visible until you make an action such as scroll the page, bring the keyboard back, change orientation.
It's pretty jarring to look at.
I'd ideally like to stop the issue occurring, but as a temporary fix I'd be happy with being able to set the grey to my own background colour to make it less noticeable.
This looks like the HTML's not being re-drawn when the keyboard disappears... does it clear up if you do something to trigger a render?
Are you using a framework to handle the UI here? Something that might be trying to do something clever based on the visible viewport?
From what I can tell, the root of the issue is in the webview not re-drawing correctly, or something in your JavaScript failing to respond to the viewport changing size.
You could try running the app on the "web" target (instead of Android) then opening it in your phone's browser: if you can get far enough into the app to create the same effect it would help isolate the problem to the webview rendering or your JS.
I had a very similar issue in my project, in my case on Android 2.3.5 but not on Android 4.*. The cause in my case was not setting a window soft input mode for the associated activity in the manifest:
android:windowSoftInputMode="adjustPan"
Instead, the window was resizing when the keyboard appeared but apparently not resizing once more when the keyboard disappeared.
More details can be found here.
I almost went crazy with the same issue. I finally found out that this largely depends on the device you are using. I had a similar problem : Fixed elements (HTML) break after android keyboard dissapears?
And I am also using trigger.io. This doesn't happen with some devices. Could be the particular OS in android or could just be the way the specific device handles the memory latency.
I have looked for this but I go with #jamesbrady in that the HTML doesn't redraw. The problem in trigger is that you cannot edit the
android:windowSoftInputMode="adjustPan"
because the activity tag in the AndroidManifest.xml updates on each run. You would need to build a private module for that.

Categories

Resources