The Super Special Official Android Support Thread

Here is where I’ll be tracking progress on Android support. Report unreported issues here, please!

I’m making some significant headway (thanks to the help of others who I’ll tag in an update to this thread).

I’m gonna brain dump here with a list of features and their current status/tested/not tested/etc:

Library as a whole:
The custom shader used for both elements and bitmap fonts seems to work fine.
The custom loaded for bitmap fonts works as expected.

Screen class :
—System clipboard support will be going away until I can abstract the screen class and separate it for the target platform.
—Texture Atlas: ALWAYS enable the global texture atlas.
—Audio support: not test yet
—Tooltip support: I believe this is bugged at the moment, I’ll need to retest it.
—Cursor effects: This is useless feature for android, so I am not going to bother to support it for this platform

Effect Manager:
—Effects: basic effects have been tested (i.e. those associated by default to components)
—BatchEffect: not tested
—EffectQueue: not tested

Element:
—Resizing : working
—Moving : working
—Thus far I have not found any issues

Buttons: (Adapter, Radio,Radio group, Checkbox)
—All functionality seems to be working ok thus far.
—Use left mouse button methods!

Menus:
—There is a bug related to mousedown hiding menus by default. This is a very easy fix and will be working soon.

Windows:
—Everything seems to be working fine

Text, Labels, Etc:
—I’m not finding any issues with these. They are working as expected in all classes leveraging these

TextFields:
—not tested yet

Sliders:
—not tested, however… buttons work fine, locktoparentbounds works fine, so these should work fine. Will test tonight.

Spinners:
—not tested… This will depend on how textfield holds up.

ScrollPanels:
—not tested yet

Indicators:
—not tested yet

Drop-down/ComboBox:
—not tested yet

SpriteElement:
—not tested yet

ColorWheel:
—not tested yet

ChatBox/ChatBoxExt:
—not tested yet

OSRViewPort:
—not tested yet, however, I’m fairly confident in this one. Will know later tonight and report

Dials:
—not tested yet

SelectList:
—not tested yet

SlideTray/TabControl:
—not tested yet

Um… ok… I’ll keep you posted as to the progress.

1 Like

Well sheeeet, can’t update the original post… so:

Sliders: tested
— work as expected

Indicators: tested
— work as expected

Labels: tested
— Work as expected

Checkboxes: tested
— work as expected

Toggle buttons: tested
— work as expected

More to come

Require some assistance with testing text fields. How does one show the onscreen keyboard?

TextField: testing at the moment
— I can at least report that focus, highlighting and caret positioning works as expected.

This also means:

EffectManager:
—Shader based effects: work as expected.

And it would seem I’ll be providing a new control… Keyboard… dun dun duuuuuun.

Will let ya know when it is done.

The virtual keyboard is almost done… this was actually a lot trickier than it sounds, as it completely goes against how keyboard, focus and tabfocus elements are handled. The good news is, this now has a bypass mechanism that the virtual keyboard leverages.

Now… for the ultra-super-insanely-awesome-greatest news:

TextField: completely tested (including text range selection using touch/drag/release)
— working as intended.

Can I say that again??

Working AS INTENDED!

The virtual keyboard rocks… it will be a screen level componant created if a textfield is added to your GUI. When the textfield gets focus, the virtual keyboard will display at the bottom of the screen (this may be configurable… not sure yet). When the element loses focus (or enter key is touched). The keyboard removes itself from the screen.

After this addition is complete, I’ll post a thread specific to the control with the how’s/why’s/etc

I’ll be adding a virtual joystick control for android as well soon after this.

All of the updates thus far have been committed to the repo, however!

It is critical that I update the global atlas defs and the atlas image, as you likely will not see anything until I do. I’ll take care of this sometime tomorrow.

Really great work, I am very glad I don’t have to implement an Android keyboard myself. I will test it today.
And I appreciate that you are trying to get every piece of your gui working on android.

After a first glance on your code, I found the Keyboard.java, but neither inside the TextField.java nor in Screen it is ever used. Maybe you missed to commit a file or I just did not find it?

@Erebos3D said: Really great work, I am very glad I don't have to implement an Android keyboard myself. I will test it today. And I appreciate that you are trying to get every piece of your gui working on android.

After a first glance on your code, I found the Keyboard.java, but neither inside the TextField.java nor in Screen it is ever used. Maybe you missed to commit a file or I just did not find it?

Haven’t pushed out the integration updates yet. Will be there by this evening along with the atlas updates.

More testing:

ScrollArea: tested
—Works as expected

ScrollAreaAdapter: tested
—Works as expected

Single menus (since I haven’t updated for click-to-display-submenu): tested
—The menu itself works as expected, just need to alter how they are shown for android

Spinners: tested
—Works as expected

An idea on ScrollAreas / -Adapters:
Smartphone users are used to scrolling up and down without a vertical drag bar and just a touch on the area.
Is it possible to implement that? That even touch/mouse events on sub-panels etc are used for scrolling?

@Erebos3D said: An idea on ScrollAreas / -Adapters: Smartphone users are used to scrolling up and down without a vertical drag bar and just a touch on the area. Is it possible to implement that? That even touch/mouse events on sub-panels etc are used for scrolling?

I’ll see if I can makes something a bit more android-ie for scroll area interaction. Have a few things to finish up first.

I just committed all updates for style atlas changes, Virtual Keyboard integration, and I was able to add style support for key configurations as well. It’s a bit laborious going through the xml file… but it is there.

I’m sure there is plenty of work to do to work out quirks… all controls tested are in working order. Sub-menuing is not fixed yet, but is the next on the list.

Update for testing:

SelectBox: tested
—works great

ComboBox: tested with keyboard
—works great

ChatBox/ChatBoxExt: tested
—works great

SelectList: tested
—works great

That’s pretty much it for all standard controls. Just the menus left to fix.

As for extra stuff… the two I find most useful are:

OSRViewPort… not tested yet, EDIT: erm… nm… that would make ZERO sense. I’ll get on testing this soon.
SpriteElement… not tested, however this should work just fine.
ColorWheel… is broke for texture atlas atm all the way around. I’ll fix this in the next couple days.

More updates:

Menus now work on Android.
—tested and working as expected.

OSRViewPort now works on Android
—tested and NOT working as expected :wink: Reason being is I have currently disabled the depth buffer altogether until I can come up with a working solution that won’t break applications if JME implements a solution of it’s own.

Still, the Off-screen rendered VP allows for touch-controlled camera, it just renders a bit flat for now. (EDIT: I just realized that my stupid sense of humor doesn’t always translate well in writing. This doesn’t actually effect the rendered scene in the OSR… it works well, you just have no depth buffer returned as a texture is all.)

I’m still making my way through the list, however, these were the two that I knew were going to have issues because the desktop version relies on focus/lose focus events for certain functions.