Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » BPMN Modeler » Change Labels of PopupBar
Change Labels of PopupBar [message #11409] Wed, 22 April 2009 08:06 Go to next message
Verena is currently offline VerenaFriend
Messages: 17
Registered: July 2009
Junior Member
Hi,

I'm trying to change the labels of the popupbar - I'm not sure wether this
is the correct name. I mean the kind-of-contextmenu-thing that appears
after dragging a connection. I need to change the labels of the entries
there - is there any chance to do that?

In the same context I need to change the ToolTips of the other "Tool" that
provides the graphical views of the available elementtypes (I also do not
know a name for that) and appears on CTRL+Space.

Thanks for help,

--Verena
Re: Change Labels of PopupBar [message #11446 is a reply to message #11409] Wed, 22 April 2009 10:53 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: atoulme.intalio.com

Verena wrote:
> Hi,
>
> I'm trying to change the labels of the popupbar - I'm not sure wether
> this is the correct name. I mean the kind-of-contextmenu-thing that
> appears after dragging a connection. I need to change the labels of the
> entries there - is there any chance to do that?
It's a PopupMenuCommand showing a list of IElementType for you to pick one.

You need to hack the ConnectionAndEndLabelProviderEx in the
PromptForConnectionAndEndCommandEx class that is used in the
PromptForConnectionAndEndCommandEx edit policy.

Best to extend ContainerNodeEditPolicyEx, override
getPromptForConnectionAndEndCommand and return there your own command
with your hacked label provider.
>
> In the same context I need to change the ToolTips of the other "Tool"
> that provides the graphical views of the available elementtypes (I also
> do not know a name for that) and appears on CTRL+Space.
>
That's named the popup bar. You need to override PopupBarEditPolicyEx
and look at the populatePopupBars method.

Thanks,

Antoine
Re: Change Labels of PopupBar [message #11483 is a reply to message #11446] Wed, 22 April 2009 14:43 Go to previous messageGo to next message
Verena is currently offline VerenaFriend
Messages: 17
Registered: July 2009
Junior Member
Antoine Toulme wrote:

> Verena wrote:
>> Hi,
>>
>> I'm trying to change the labels of the popupbar - I'm not sure wether
>> this is the correct name. I mean the kind-of-contextmenu-thing that
>> appears after dragging a connection. I need to change the labels of the
>> entries there - is there any chance to do that?
> It's a PopupMenuCommand showing a list of IElementType for you to pick one.

> You need to hack the ConnectionAndEndLabelProviderEx in the
> PromptForConnectionAndEndCommandEx class that is used in the
> PromptForConnectionAndEndCommandEx edit policy.

> Best to extend ContainerNodeEditPolicyEx, override
> getPromptForConnectionAndEndCommand and return there your own command

I tried that, but it is never called. Do I need to 'register' that
somewhere?

> with your hacked label provider.
>>
>> In the same context I need to change the ToolTips of the other "Tool"
>> that provides the graphical views of the available elementtypes (I also
>> do not know a name for that) and appears on CTRL+Space.
>>
> That's named the popup bar. You need to override PopupBarEditPolicyEx
> and look at the populatePopupBars method.

This one goes the same - never called. I'd probably have to do something
to tell the 'Framework' that this one should be used, but I have no idea
where.

Thanks gaain for your help.
Re: Change Labels of PopupBar [message #11520 is a reply to message #11483] Wed, 22 April 2009 21:32 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: atoulme.intalio.com

Do a Ctrl+Shift+G on ContainerNodeEditPolicyEx to see where it is used:
in the edit parts when they create their edit policies. Same for
PopupBarEditPolicyEx.

That's where you hook them up.

Thanks,

Antoine

Verena wrote:
> Antoine Toulme wrote:
>
>> Verena wrote:
>>> Hi,
>>>
>>> I'm trying to change the labels of the popupbar - I'm not sure wether
>>> this is the correct name. I mean the kind-of-contextmenu-thing that
>>> appears after dragging a connection. I need to change the labels of the
>>> entries there - is there any chance to do that?
>> It's a PopupMenuCommand showing a list of IElementType for you to pick
>> one.
>
>> You need to hack the ConnectionAndEndLabelProviderEx in the
>> PromptForConnectionAndEndCommandEx class that is used in the
>> PromptForConnectionAndEndCommandEx edit policy.
>
>> Best to extend ContainerNodeEditPolicyEx, override
>> getPromptForConnectionAndEndCommand and return there your own command
>
> I tried that, but it is never called. Do I need to 'register' that
> somewhere?
>
>> with your hacked label provider.
>>>
>>> In the same context I need to change the ToolTips of the other "Tool"
>>> that provides the graphical views of the available elementtypes (I also
>>> do not know a name for that) and appears on CTRL+Space.
>>>
>> That's named the popup bar. You need to override PopupBarEditPolicyEx
>> and look at the populatePopupBars method.
>
> This one goes the same - never called. I'd probably have to do something
> to tell the 'Framework' that this one should be used, but I have no idea
> where.
>
> Thanks gaain for your help.
>
Re: Change Labels of PopupBar [message #11556 is a reply to message #11520] Fri, 24 April 2009 06:40 Go to previous message
Verena is currently offline VerenaFriend
Messages: 17
Registered: July 2009
Junior Member
Thanks a lot - it works now.
Previous Topic:Deletion of Task
Next Topic:Changing the Activity name through a listener
Goto Forum:
  


Current Time: Tue Mar 19 06:31:06 GMT 2024

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

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

Back to the top