Le 20/08/15 14:55, Zheng, Kai a écrit :
> I don’t see a good way here. If there is some event pub-sub mechanism already 
> it can leverage, we would avoid coupling between
> the dialog and widget. Otherwise, looks like we have to pass some handle from 
> the dialog down to the widget, may be some more
> general interface like below, instead of the dialog type.

Thanks Kai.

As you said, there is no way. The Dialog class does not expose the
buttons Map, and the getButton( int ) method is protected.

I have done what I wanted by adding a reference to the Dialog instance
in a Context structure that I'm already passing to all the widgets I'm
using in this Dialog, and added a getOkButton() to teh Dialog. That does
the trick.


Reply via email to