Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Combo box in Window ActionBar
Combo box in Window ActionBar [message #1396560] Tue, 08 July 2014 13:32 Go to next message
Matteo Renesto is currently offline Matteo RenestoFriend
Messages: 2
Registered: July 2014
Junior Member
Hallo,

I've recently faced some issues when I tried to put a combo box inside a window toolbar (or ActionBar as you may want to call it). My idea was to have the combo box just on the right of the window tab (with the title..).

What happens is that when I click on the combo, aiming to choose an option, it flickers and doesn't allow me to select anything. In the back-end my action handler is never called, because there is no event SWT.Selection.

On the other hand, it works correctly if i put my combobox in the main application toolbar, but this is not what I want to do.

Has anybody already put a combobox into a window toolbar?

Could it be that this issue is related to a set-focus lose-focus problem?

Thanks
Re: Combo box in Window ActionBar [message #1400421 is a reply to message #1396560] Mon, 14 July 2014 07:12 Go to previous messageGo to next message
Ivan Furnadjiev is currently offline Ivan FurnadjievFriend
Messages: 2426
Registered: July 2009
Location: Sofia, Bulgaria
Senior Member
Hi,
maybe it's the same issue like in this bug [1] even the bug is about a
Combo in ViewPart toolbar.

[1] 439044: Combo / DateTime controls in the toolbar of a view with
focus don't work
https://bugs.eclipse.org/bugs/show_bug.cgi?id=439044

Best,
Ivan

--
Ivan Furnadjiev

Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/

Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
Re: Combo box in Window ActionBar [message #1401161 is a reply to message #1400421] Tue, 15 July 2014 08:00 Go to previous messageGo to next message
Matteo Renesto is currently offline Matteo RenestoFriend
Messages: 2
Registered: July 2014
Junior Member
Hi,
thanks. It looks indeed the very same problem. I checked the bug list, but somehow i should have missed this one.

However, I managed to create a sample application in which it actually works. This is quite strange...

See attached imaged.

Matteo

EDIT:
I just read your answer on the bug tracker. I just managed to "avoid" the issue by preventing to set focus on the viewer in my view. (In fact in a view without a viewer it works correctly..)

  • Attachment: compoview.jpg
    (Size: 33.75KB, Downloaded 124 times)

[Updated on: Tue, 15 July 2014 08:24]

Report message to a moderator

Re: Combo box in Window ActionBar [message #1401229 is a reply to message #1401161] Tue, 15 July 2014 10:07 Go to previous messageGo to next message
Ivan Furnadjiev is currently offline Ivan FurnadjievFriend
Messages: 2426
Registered: July 2009
Location: Sofia, Bulgaria
Senior Member
Hi,
this will work if ViewPart#setFocus does not set the focus (empty
implementation).
Best,
Ivan

--
Ivan Furnadjiev

Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/

Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
Re: Combo box in Window ActionBar [message #1645533 is a reply to message #1396560] Mon, 02 March 2015 15:09 Go to previous message
Frank.K Mising name is currently offline Frank.K Mising nameFriend
Messages: 15
Registered: January 2013
Junior Member
I just faced the same problem with Combobox in toolbars. Searched the web a little bit and found a solution using an action that has a menu (created with IMenuCreator).
The popup works fine this way and the flickering is gone.

The reason for my post is now that I am using an action instead of a real Combo, the size is automatically calculated based on the current text of the action. As the string content varies depending on the menu selection, it changes its size whenever another value was selected.

I guess the reason is that the toolbar layout is set to FlowLayout or something similar and I couldn't find a way to either set it to e.g. GridLayout or set the size or LayoutData of the Action.

Is there a way to work around this issue?

[Updated on: Mon, 02 March 2015 15:10]

Report message to a moderator

Previous Topic:TableViewer in IE9, problem with arrow-down keys
Next Topic:Using the LocalResourceManager causes NPE after RAP update 2.3
Goto Forum:
  


Current Time: Thu Apr 25 10:36:08 GMT 2024

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

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

Back to the top