Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3368: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3370: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3371: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3372: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)OrbWorks Community Forum • View topic - Select buttons and fields using 5-way?

OrbWorks Community Forum

This site is now in read-only mode. No new topics can be created, and no new users can register.

Is it possible to navigate through buttons and fields in an app using the 5-way key and have the selected items appear highlighted (like you see in many Palm OS apps)?

I'd like to be able to navigate/highlight the UI elements of my app using he directional keys and then use the select button to either fire the onselect event of highlighted buttons or set focus to the highlighted field.

and saw that the focus related methods only worked with UIField objects so they won't be much help.

I wonder if it would be feasible to implement a set of methods to
- select an object
- deselect an object
- jump to the next or prior object
- execute the object onselect handler.

Select would draw a rectangle around an particular object (obj.x,obj.y,objw,obj,h)

Deselect would draw a clear rectangle around the object and then repaint the the object with the visible property.

Jump would mean each form would need a table of objects so that at the nth object you'd know what the n+1 and n-1 one would be.

Execute would probably need the same object table and then call the same routine that handles the onselect processing. I've found that in order to support an object selection and a menu item that does the same thing (like a "Save" button and a File / Save menu item, both event handlers call SaveRtn or something like that; you'd need to do that too.)

The tricky part would be whether you could pass in generic object pointers to these methods or whether only specific object pointers can be used, e.g. Select(obj * thisone); as opposed to Select(UIButton *thisone);

I think only the latter can be done so that means you'd need global pointers like
UIButton *CurrentButton;
UIField *CurrentFirld;
UIScroll *CurrentScroll; etc.

Select(int objid)
and switch statement processing to process the type of object objid is and what select handlers it uses, etc.

Just some random thoughts. I'm sure other people have better ideas.
Frank

Frank, thanks for the input. That seems an awful lot of work and code for functionality that appears to already be built into the OS. For instance, I get a limited field and button selection capability if I convert my form from standard to modal.

Maybe tapping into this functionality would require writing a native plug-in (although I would have no idea how to proceed or if it is even possible).

Jeremy, any chance you could weigh in? Is there something we are missing here?

Though I am not sure how this works, my guess is that since the OrbC runtime is processing the 5-way events, the OS isn't handling them. In the case of domodal, the OS completely runs the event loop - so it works there.