Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » e(fx)clipse » focus on window
focus on window [message #1693634] Mon, 27 April 2015 07:27 Go to next message
Bart Cichy is currently offline Bart CichyFriend
Messages: 13
Registered: March 2015
Location: Poland
Junior Member
Hello
I have a very similar problem (with different implementation and on the e(fx)clipse):
https://www.eclipse.org/forums/index.php/m/941058/?msg_941058
Quote:
I have to create multiwindowed e4 app. (...) I'm trying to focus on one of the windows programmaticaly...

I tried (sample code):
MTrimmedWindow window001 = getWindow( 1 ); //with focus / on top
MTrimmedWindow window002 = getWindow( 2 );
MTrimmedWindow window003 = getWindow( 3 );

EModelService.bringToTop( window001 );
window001.setOnTop( true );
window001.getContext().activate();

I can't get a Stage from window to try Stage.requestFocus().

I suppose that can be a bug...

Regards
Re: focus on window [message #1693643 is a reply to message #1693634] Mon, 27 April 2015 08:52 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 6651
Registered: July 2009
Senior Member
Can you file a bug-report - I'll try to look at this as soon as possible.

Tom

On 27.04.15 09:27, Bart Cichy wrote:
> Hello
> I have a very similar problem (with different implementation and on the
> e(fx)clipse):
> https://www.eclipse.org/forums/index.php/m/941058/?msg_941058
> Quote:
>> I have to create multiwindowed e4 app. (...) I'm trying to focus on
>> one of the windows programmaticaly...
>
> I tried (sample code):
>
> MTrimmedWindow window001 = getWindow( 1 ); //with focus / on top
> MTrimmedWindow window002 = getWindow( 2 );
> MTrimmedWindow window003 = getWindow( 3 );
>
> EModelService.bringToTop( window001 );
> window001.setOnTop( true );
> window001.getContext().activate();
>
> I can't get a Stage from window to try Stage.requestFocus().
>
> I suppose that can be a bug...
>
> Regards
Re: focus on window [message #1693644 is a reply to message #1693643] Mon, 27 April 2015 08:53 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 6651
Registered: July 2009
Senior Member
As a temporary work around have you tried to activate a part in the
window in question through the EPartService?

Tom

On 27.04.15 10:52, Tom Schindl wrote:
> Can you file a bug-report - I'll try to look at this as soon as possible.
>
> Tom
>
> On 27.04.15 09:27, Bart Cichy wrote:
>> Hello
>> I have a very similar problem (with different implementation and on the
>> e(fx)clipse):
>> https://www.eclipse.org/forums/index.php/m/941058/?msg_941058
>> Quote:
>>> I have to create multiwindowed e4 app. (...) I'm trying to focus on
>>> one of the windows programmaticaly...
>>
>> I tried (sample code):
>>
>> MTrimmedWindow window001 = getWindow( 1 ); //with focus / on top
>> MTrimmedWindow window002 = getWindow( 2 );
>> MTrimmedWindow window003 = getWindow( 3 );
>>
>> EModelService.bringToTop( window001 );
>> window001.setOnTop( true );
>> window001.getContext().activate();
>>
>> I can't get a Stage from window to try Stage.requestFocus().
>>
>> I suppose that can be a bug...
>>
>> Regards
>
Re: focus on window [message #1693647 is a reply to message #1693644] Mon, 27 April 2015 09:17 Go to previous messageGo to next message
Bart Cichy is currently offline Bart CichyFriend
Messages: 13
Registered: March 2015
Location: Poland
Junior Member
Yes, I tried. unfortunately does not work too. Of course flag MTrimmedWinwod.isOnTop() is on true (after bringToTop(), setOnTop( true ), but the window is in background.
bug: 465545
Re: focus on window [message #1693711 is a reply to message #1693647] Mon, 27 April 2015 18:50 Go to previous message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 6651
Registered: July 2009
Senior Member
The bug is fixed now so:

----8<----
MTrimmedWindow window001 = getWindow( 1 ); //with focus / on top
MTrimmedWindow window002 = getWindow( 2 );
MTrimmedWindow window003 = getWindow( 3 );

EModelService.bringToTop( window001 );
----8<----

should do the job now.

Tom


On 27.04.15 11:17, Bart Cichy wrote:
> Yes, I tried. unfortunately does not work too. Of course flag
> MTrimmedWinwod.isOnTop() is on true (after bringToTop(), setOnTop( true
> ), but the window is in background.
> bug: 465545
Previous Topic:Change the Label/Tooltip for MenuItem and ToolItem depended on Selection
Next Topic:FXCanvas not found during plugin export.
Goto Forum:
  


Current Time: Sat Jan 25 00:34:53 GMT 2025

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

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

Back to the top