How to select configurable nodes in 'Setting' window programatically?

Hi Team,

How to get current setting instance? My scenario like following;

I have configured my configuration classes in plugin.xml and when I run my plugin it displays as following in my 'Setting' dialog.

Tools

  MyPlugin

    TestNode1

    TestNode2

When user clicks 'TestNode1' or 'TestNode2', dialog will pop up if user cancel it nothing gonna happen and user can not able to click previously clicked child node.

What Im trying to do is if user cancel the pop up dialog selection need to focus to parent node in my example 'MyPlugin'. I used following code fragment and it won't work as expected.

 

DataContext context = DataManager.getInstance().getDataContext();
                if (context != null) {
                    Settings settings = Settings.KEY.getData(context); ---> this will return 'null'
                    settings.select(settings.find(MyPluginConfigurable.class));
                }

 

I appreciate your help regarding this matter.

Thanks,

Navin

1 comment
Comment actions Permalink

Hi Navin,

 

Could you please introspect this DataContext?

Which class implements this interface?

Do you call your example from your configurable?

 

Regards,

SAM

0

Please sign in to leave a comment.