|[cdt-dev] Disabling Menuitems at IDE startup|
I need to show some custom action items in Run menu of eclipse IDE as disabled initially i.e; at the start up of work bench - like default action items in Run menu - Toggle Breakpoint, Toggle Line Breakpoint, Debug actions like Run, Debug,Resume etc.
We have a custom perspective derived from the extension point org.eclipse.ui.perspectives. I tried to disable the required action items in createInitialLayout() function. When we run the code for the first time the control is passing through this function and the required result is obtained. But next time it’s is not entering this function. But again if we delete the runtime of previous session and run the code it works fine.
Also I tried by setting the “enablesFor ” attribute of action in org.elipse.ui.actionSets as 1. But the result was unpredictable. Even though it gets disabled initially, if any item in views like breakpoint, _expression_, RSE etc is selected it gets enabled. So I can’t trust this.
Can any one please suggest a method to disable the menu items initially?
Thanks in advance
This message and any attachments is intended for the sole use of the intended recipient. It may contain confidential information. Any unauthorized use, dissemination or modification is strictly prohibited. If you are not the intended recipient, please notify the sender immediately then delete it from all your systems, and do not copy, use or print. Internet communications are not secure and it is the responsibility of the recipient to make sure that it is virus/malicious code exempt.
The company/sender cannot be responsible for any unauthorized alterations or modifications made to the contents. If you require any form of confirmation of the contents, please contact the company/sender. The company/sender is not liable for any errors or omissions in the content of this message.
Back to the top