Once i have setRightSoftkeyLabel(), publically for every page.. now i would like to remove that functionality on single page...please provide solution.
Once i have setRightSoftkeyLabel(), publically for every page.. now i would like to remove that functionality on single page...please provide solution.
Regards,
Ravindra Suthar
I recommend not thinking in terms of "pages" when it comes to widgets. Softkey labels are not set "per page" but rather globally within a widget. You are free to set the softkey label to whatever you want, whenever you want, as well as to restore it to the default functionality. You can call the setRightSoftkeyLebel() function at absolutely any point in time that you want to change the label and callback function.
I have set it globally... but in single page i need different. So, That is little problematic.
Regards,
Ravindra Suthar
Hi, I have similar problem....
I use setRightSoftkeyLabel in main html, it works. But after going to other html page (by <a href="XXX.html">), and call setRightSoftkeyLabel again, it cannot change the right label... I've checked and seems that window.menu returns false and therefore cannot work properly...
any idea?
Don't use links to move away from the main HTML. Rather fetch stuff with XHR and modify the current DOM of the main HTML. That way you keep being within the widget context rather than moving into a web context where you don't have access to the widget object.
In general you should not think of widgets as being composed of "HTML pages" with links between the pages etc. Rather think of a widget as JavaScript code and a DOM tree that you can manipulate to produce whatever visual user interface you want to have at any given time.
Hi,
Thumb-rule while creating the widget-UI advised not to use multiple pages for multiple views in the application
Generally, will have each page for each view. Rather doing that way, divide MainHTML page into multiple views by using "<div>" or any suitable HTML Tags. And have a logic to show/hide the suitable view.
And finally, answer to the first question "How to remove setRightSoftkeyLabel() functionality?". Check the following code
Thanks,Code:// to set setRightSoftkeyLabel("Settings", "showSetting();"); // to remove the Right-Softkey-Label and assigned function // pass EMPTY label STRING and NULL or non FUNCTION TYPE arguments setRightSoftkeyLabel("", null);
Raghava
@Moderator: This is repeated entry, please delete this reply
Last edited by raghava.chinnappa; 2008-11-25 at 04:58. Reason: Repeated entry