Apache OpenOffice (AOO) Bugzilla – Issue 111214
Implement new ControlCommand for Editfield control in Complex Toolbar Framework
Last modified: 2017-05-20 11:28:08 UTC
The following enhancement is requested for the Editfield control in the Complex Toolbar framework. Implement a "SetFocus" ControlCommand for the EditField, which will set the focus of the UI to this element.
cd->robertzhou: Please take over. You are familiar with the code and this is a nice enhancement for developers.
cd: Set target and confirm issue.
Created attachment 79720 [details] Patch to add SetFocus command to EditField on complex toolbar
Created attachment 79721 [details] Extension provides complex toolbar for testing This extension contains complex toolbar for Writer document having an edit field and two buttons, written in Python. - Install the package and then restart the office. - Open new Writer document -> "Add-On 1" toolbar is shown (maybe its name is different). - Push "SetText" button to check the extension working well -> "abc" is shown in the edit field on the toolbar means ok. - Push "SetFocus" button on the toolbar -> focus gained to the edit field. The attached extension does not work with multiple documents, only for testing purpose. Arguments field of css.frame.ControlCommand set to State field of css.frame.FeatureStateEvent passed to statusChanged method can not be void. If void is specified, differently processed in ComplexToolbarController::statusChanged method, empty []com.sun.star.beans.NamedValue can be used to set focus to target edit field.
Not only for edit field but for other controls should be able to get focus by the same way.
Reset assigne to the default "issues@openoffice.apache.org".