Re: Managing new blue focus ring
Harry wrote: If you just want to suppress the focus ring try the following (works fine in my app). In the form event handler just "swallow" the event that gives the focus to the control: switch (eventP->eType) { case frmObjectFocusTakeEvent: return true; ... There is one exeption however. You cannot use this with fields, > as those cannot be edited then. How does this event differ from fldEnterEvent? -- Luc Le Blanc -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
Re: Managing new blue focus ring
Grzegorz Szewc wrote: If you wont to turn off nav focus ring try to add following lines in frmOpen event: FrmNavStateFlagsTypenavStateFlags; Err navErr; navErr = FrmGetNavState (frmP, &navStateFlags); navStateFlags &= ~kFrmNavStateFlagsObjectFocusMode; navErr = FrmSetNavState (frmP, navStateFlags); It is a code from Palm sample apps. I didn't check if it works correct. You have to check. Some more info can be found at website: http://www.palmos.com/dev/support/docs/palmos/PalmOSReference/Form.html# 1131325 It works fine. I just have to call FrmGlueNavIsSupported() to make sure the device has the one-handed navigation feature, otherwise the OS reports a fatal error. -- Luc Le Blanc -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
re: Managing new blue focus ring
If you just want to suppress the focus ring try the following (works fine in my app). In the form event handler just "swallow" the event that gives the focus to the control: switch (eventP->eType) { case frmObjectFocusTakeEvent: return true; ... There is one exeption however. You cannot use this with fields, as those cannot be edited then. Harry -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
Re: Managing new blue focus ring
At 02:16 PM 2/4/2006, you wrote: I'm not sure from your example whether I must complete the object array with every single form object I have in each form even if I just want to completely turn off the blue focus ring. No, just specify the mode as appFocusStartState and don't bother listing any controls. -- Ben Combee, Senior Software Engineer, Palm, Inc. "Combee on Palm OS" weblog: http://palmos.combee.net/ Developer Forum Archives: http://news.palmos.com/read/all_forums/ -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
RE: Managing new blue focus ring
If you wont to turn off nav focus ring try to add following lines in frmOpen event: FrmNavStateFlagsTypenavStateFlags; Err navErr; navErr = FrmGetNavState (frmP, &navStateFlags); navStateFlags &= ~kFrmNavStateFlagsObjectFocusMode; navErr = FrmSetNavState (frmP, navStateFlags); It is a code from Palm sample apps. I didn't check if it works correct. You have to check. Some more info can be found at website: http://www.palmos.com/dev/support/docs/palmos/PalmOSReference/Form.html# 1131325 Regards, Gregory -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
Re: Managing new blue focus ring
I'm not sure from your example whether I must complete the object array with every single form object I have in each form even if I just want to completely turn off the blue focus ring. -- Luc Le Blanc Grzegorz Szewc wrote: You can create navigation file and add it to your project. The file extension should be .r, here is an example: //File navigation.r #include "StarterRsc.h" //You have to include all resource headers you will//reference to #define frmNavFlags \ defaultStartStateValue = 0x, \ objectFocusStartState = 0x0001, \ appFocusStartState = 0x0002 #define frmNavObjectFlags \ none = 0x, \ skip = 0x0001, \ forceInteraction = 0x0002, \ bigButton= 0x8000 type 'fnav' { unsigned integer = 1; /* resource version */ unsigned integer = $$Countof(ObjectArray); unsigned integer = 20; /* size of header */ unsigned integer = 8; /* size of list elements */ unsigned longint frmNavFlags; /* navigation flags */ unsigned integer; /* ID of initial focus object */ unsigned integer = 0; /* hint ID of jump to object */ unsigned integer = 0; /* hint ID of bottom left object */ fill word; array ObjectArray { unsigned integer; /* ID of object */ unsigned integer frmNavObjectFlags; /* object flags */ unsigned integer; /* ID of above object */ unsigned integer; /* ID of below object */ }; }; //Here is navigation rules for form TargetForm resource 'fnav' (TargetForm) { objectFocusStartState, TargetExitGraphicButton, { TargetExitGraphicButton, 0, TargetTableGadget, 0, TargetEditGraphicButton, 0, TargetTableGadget, 0, TargetSaveGraphicButton, 0, TargetTableGadget, 0, TargetTableGadget, 0, TargetTargetTypePopTrigger, TargetExitGraphicButton, TargetTargetTypePopTrigger, 0, 0, TargetTableGadget } }; -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
Re: Managing new blue focus ring
At 06:35 AM 2/3/2006, you wrote: "Ben Combee" <[EMAIL PROTECTED]> a écrit dans le message de news: [EMAIL PROTECTED] > > If you use a 'fnav' resource to tell Palm OS that your form should not be > in Object Interaction mode, you shouldn't get the blue ring. This focus > system has a major benefit for smart phone users, where it allows > selecting and activating controls without touching the screen, something > that's quite useful for one-handed operation of lots of programs. > I asked almost that same question on january 18 but got no usefull answers. My forms are made with constructor so I can't add a fnav on them (unless there is a way I don't know about). Is there a way to create it programaticaly at formload time? You can add a .r file with your 'fnav' resources to your project file using the template that's in the PalmSource knowledgebase or using the RCP-to-Rez plugin from Neil Rhodes. -- Ben Combee, Senior Software Engineer, Palm, Inc. "Combee on Palm OS" weblog: http://palmos.combee.net/ Developer Forum Archives: http://news.palmos.com/read/all_forums/ -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
RE: Managing new blue focus ring
You can create navigation file and add it to your project. The file extension should be .r, here is an example: //File navigation.r #include "StarterRsc.h" //You have to include all resource headers you will//reference to #define frmNavFlags \ defaultStartStateValue = 0x, \ objectFocusStartState = 0x0001, \ appFocusStartState = 0x0002 #define frmNavObjectFlags \ none = 0x, \ skip = 0x0001, \ forceInteraction = 0x0002, \ bigButton= 0x8000 type 'fnav' { unsigned integer = 1; /* resource version */ unsigned integer = $$Countof(ObjectArray); unsigned integer = 20; /* size of header */ unsigned integer = 8; /* size of list elements */ unsigned longint frmNavFlags; /* navigation flags */ unsigned integer; /* ID of initial focus object */ unsigned integer = 0; /* hint ID of jump to object */ unsigned integer = 0; /* hint ID of bottom left object */ fill word; array ObjectArray { unsigned integer; /* ID of object */ unsigned integer frmNavObjectFlags; /* object flags */ unsigned integer; /* ID of above object */ unsigned integer; /* ID of below object */ }; }; //Here is navigation rules for form TargetForm resource 'fnav' (TargetForm) { objectFocusStartState, TargetExitGraphicButton, { TargetExitGraphicButton, 0, TargetTableGadget, 0, TargetEditGraphicButton, 0, TargetTableGadget, 0, TargetSaveGraphicButton, 0, TargetTableGadget, 0, TargetTableGadget, 0, TargetTargetTypePopTrigger, TargetExitGraphicButton, TargetTargetTypePopTrigger, 0, 0, TargetTableGadget } }; Regards, Gregory -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
Re: Managing new blue focus ring
"Ben Combee" <[EMAIL PROTECTED]> a écrit dans le message de news: [EMAIL PROTECTED] > > If you use a 'fnav' resource to tell Palm OS that your form should not be > in Object Interaction mode, you shouldn't get the blue ring. This focus > system has a major benefit for smart phone users, where it allows > selecting and activating controls without touching the screen, something > that's quite useful for one-handed operation of lots of programs. > I asked almost that same question on january 18 but got no usefull answers. My forms are made with constructor so I can't add a fnav on them (unless there is a way I don't know about). Is there a way to create it programaticaly at formload time? -- Regis St-Gelais www.laubrass.com -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
Re: Managing new blue focus ring
At 11:29 PM 2/2/2006, you wrote: When I saw my app running on a Palm E2, I noticed my most complicated form was half filled, thanks to the new blue focus ring that made my handler think the form had already been initialized since FrmGetFocus no longer returned noFocus upon starting. I also noted this blue ring can make things look pretty bad when controls have to be positioned close to one another. Can I ask the OS whether it features this blue focus ring? Can this blue focus ring be turned off at all? I ask because I pop up a custom virtual keypad depending on the field that has the focus, but it seems that other controls can now steal the focus from fields. If you use a 'fnav' resource to tell Palm OS that your form should not be in Object Interaction mode, you shouldn't get the blue ring. This focus system has a major benefit for smart phone users, where it allows selecting and activating controls without touching the screen, something that's quite useful for one-handed operation of lots of programs. -- Ben Combee, Senior Software Engineer, Palm, Inc. "Combee on Palm OS" weblog: http://palmos.combee.net/ Developer Forum Archives: http://news.palmos.com/read/all_forums/ -- For information on using the PalmSource Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/