Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Re: enable/disable toolbar button by "selection"
Re: enable/disable toolbar button by "selection" [message #484052] Fri, 04 September 2009 05:45
Neha is currently offline NehaFriend
Messages: 52
Registered: July 2009
Member
Hi ,
just remove the default handler class from the command created
and specify the class in your handler created.
"Alexander Filitz" <alexanderfilitz@hotmail.com> wrote in message
news:c736fef7424981b3e17dc1d25f4098ec$1@www.eclipse.org...
> hello
>
> I got a View with a TableViewer which is using Databinding to show some
> call information. After reading some tutorials about ui.commands i created
> a menu and toolbar for my commands. Now i want to enable some commands
> when a column of the TableViewer is selected, but my extensions are not
> working.
>
> This is what i've used:
>
> ui.handlers:
> (handler)->(enabledWhen)->oneSelection(reference)
> expressions.definitions:
> oneSelection(definition)->selection(with)->1(count)
>
> AND
>
> TableViewer viewer = new TableViewer(parent, SWT.MULTI |
> SWT.FULL_SELECTION);
> ..
> ..
> getSite().setSelectionProvider(viewer);
>
> the funny thing is, when i use the same reference in the ui.menus
> extension (visibleWhen) its working fine. when i select a column the
> button(command) get visible!
>
> maybe someone got an idea what i've made wrong?
> thanks
>
> Alex
>
>
Previous Topic:update rcp application (3.5)
Next Topic:Re: Edit, Cut, Copy
Goto Forum:
  


Current Time: Fri Apr 26 18:49:41 GMT 2024

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

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

Back to the top