What do I need to do to listen to TableView row editor?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

What do I need to do to listen to TableView row editor?

ycp101
I have a row editor. When a TextInput is double-clicked one of the cell,
it will be selected and a cursor will be blinking. So, it becomes
editable. I want to know what cell becomes editable with blinking
cursor. There should be a listener for it but I could not find in
TableViewRowEidtor or TextInput. The sample code is below.

<rowEditor>
  <content:TableViewRowEditor>
    <cellEditors>
      <marketName>
        <TextInput bxml:id="a" textKey="x" prompt="a"/>
      </marketName>
      <orderDateString>
        <TextInput bxml:id="b" textKey="y" prompt="b"/>
      </orderDateString>
    </cellEditors>                        
  </content:TableViewRowEditor>
</rowEditor>


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: What do I need to do to listen to TableView row editor?

ycp101
I found it by trying a few of listeners.

tableViewFilter.getComponentStateListeners().add(new ComponentStateListener.Adapter() {
        public void focusedChanged(Component component, Component obverseComponent) {
            if (obverseComponent instanceof TextInput) {
                TextInput ti = (TextInput) obverseComponent;
                // do
            }
        }
    });

Thanks for lots of hints in this mailing list
Loading...