Why do Eclipse plugin IHandler APIs return false by default? -


i new eclipse plugins , able use following links create eclipse plugin makes contribution default text editor.

the plugin works fine, have 2 questions regarding ihandler interface. long time realized plugin handler not called. saw default isenabled() returns false. after enabled true, saw handler called once. saw ishandled() set false. setting both true solved problems.

so questions is:

why both these apis default return false? (it seems strange me plugin developer want have default false.)

i tried understanding descriptions in official documentation, still don't why should return false default.

is there should aware of?

for example, if have multi page editor, might have multiple tabs.

each tab may have different actions. in case, may want handler associated tab return true , false other tabs.

similarly explorer might want not nodes enable actions. example, clicking of file should enable action, not on clicking of folder.

so selective enabling, isenabled() returns false default. can provide own logic enable or disable.


Comments

Popular posts from this blog

javascript - DIV "hiding" when changing dropdown value -

Does Firefox offer AppleScript support to get URL of windows? -

android - How to install packaged app on Firefox for mobile? -