Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » how do I access a handler method from a view?(Making a plugin, need help!)
how do I access a handler method from a view? [message #652793] Sun, 06 February 2011 19:38 Go to next message
Joel is currently offline JoelFriend
Messages: 8
Registered: January 2011
Junior Member
Hi, I am currently developing a plugin.

I have a view that has a dispose method. In this dispose method I want to be able to call a method called isEnabled from a handler class. The handler class is a command, that is set to a menu.

Does anyone know how i can do this?

[Updated on: Sun, 06 February 2011 19:59]

Report message to a moderator

Re: how do I access a handler method from a view? [message #652879 is a reply to message #652793] Mon, 07 February 2011 13:07 Go to previous message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

You want the eclipse.platform or eclipse.platform.rcp forum/newsgroup.

In theory you can get the current enabled state for a command (in 3.x)

ICommandService cs
= (ICommandService) getSite().getService(ICommandService.class);
Command cmd = cs.getCommand("");
if (cmd.isDefined()) {
cmd.isEnabled() returns the enabled state as last set by
the active handler.


Paul Webster .platform.doc.isv/guide/workbench.htm

Previous Topic:organize Resources
Next Topic:Problem with republish not getting triggered
Goto Forum:

Current Time: Sun May 27 10:09:10 GMT 2018

Powered by FUDForum. Page generated in 0.01559 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top