|
|
|
Re: MenuItems have a wrong order in Menu [message #1060600 is a reply to message #1060588] |
Mon, 27 May 2013 09:07 |
Ivan Furnadjiev Messages: 2426 Registered: July 2009 Location: Sofia, Bulgaria |
Senior Member |
|
|
Hi Yury,
yes... you are right. I can reproduce it with RAP from master. Please
open a bugzilla to track the progress on this issue. Please attach the
patch there too.
Thanks,
Ivan
On 5/27/2013 11:09 AM, Yury Mising name wrote:
> Hello, Ivan!
>
> I have created the patch for org.eclipse.rap.demo to reproduce the problem (attached here).
> Steps to reproduce:
> 1. Open About dialog - Help->About. It calls the update method for file menu (in my cases this method is called due to activity management).
> 2. Open File menu -
>
> you will see that "New MenuItem" is the first menu item there, but it was inserted on the second position.
>
> fileMenu.add( new ContributionItem() {
>
> @Override
> public void fill( Menu menu, int index ) {
> MenuItem item = new MenuItem( menu, SWT.PUSH, 1 );
> item.setText( "New MenuItem" );
> }
>
> @Override
> public boolean isDynamic() {
> return true;
> }
> } );
>
>
> If you change the ContributionItem.isDynamic to return false - the item will be inserted correctly.
>
> Best regards,
> Yury.
--
Ivan Furnadjiev
Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/
Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.02930 seconds