Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Linux Lotus Notes parent window unresponsive
Linux Lotus Notes parent window unresponsive [message #758677] Thu, 24 November 2011 08:20 Go to next message
arthurav2005 is currently offline arthurav2005Friend
Messages: 10
Registered: August 2011
Junior Member
I am using jre 1.6 on linux with swt-gtk-3.5.2
I'm opening a swt dialog from lotus notes.

The source code for the dialog is the following:

            
            Display display = new Display();
            Shell shell = new Shell();
            shell.setText( "Dialog" );
            shell.setSize( 300, 200 );
            shell.open();

            final Button button = new Button( shell, SWT.PUSH );
            button.setText( "Button" );
            button.setBounds( 20, 40, 80, 25 );

            while ( !shell.isDisposed() ) {
                if ( !display.readAndDispatch() )
                    display.sleep();
            }
            display.dispose();


The code is ran after pushing a button in lotus notes. After closing the swt dialog, the parent application becomes unresponsive as if something remained from the dialog.

If on the other side, I attach to the button some code that doesn't open any swt UI element, it works ok and doesn't render lotus notes unreponsive.

The same problem does not appear in lotus notes in windows.

Is this a known linux-related swt problem?

Thank you.

[Updated on: Thu, 24 November 2011 15:29]

Report message to a moderator

Re: Linux Lotus Notes parent window unresponsive [message #758843 is a reply to message #758677] Thu, 24 November 2011 17:11 Go to previous messageGo to next message
arthurav2005 is currently offline arthurav2005Friend
Messages: 10
Registered: August 2011
Junior Member
I have tried to open the shell with SWT.MODELESS | SWT.CLOSE or SWT.MODELESS| SWT.ON_TOP | SWT.CLOSE but the parent window is still inactive on linux.

If only I could make the dialog nonmodal, I think the problem would disappear.
Re: Linux Lotus Notes parent window unresponsive [message #758868 is a reply to message #758843] Thu, 24 November 2011 20:34 Go to previous messageGo to next message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

What if you used Display.getCurrent() to get the display, and don't use Display.dispose() at the end?

PW


Re: Linux Lotus Notes parent window unresponsive [message #758918 is a reply to message #758868] Fri, 25 November 2011 09:26 Go to previous messageGo to next message
arthurav2005 is currently offline arthurav2005Friend
Messages: 10
Registered: August 2011
Junior Member
Display.getCurrent() returns null
Re: Linux Lotus Notes parent window unresponsive [message #758922 is a reply to message #758918] Fri, 25 November 2011 10:09 Go to previous messageGo to next message
arthurav2005 is currently offline arthurav2005Friend
Messages: 10
Registered: August 2011
Junior Member
It shouldn't be related to display as long as it works on windows. I think it is something with swt-gtk but don't know what.
Re: Linux Lotus Notes parent window unresponsive [message #759040 is a reply to message #758922] Fri, 25 November 2011 18:54 Go to previous message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

GTK doesn't support multiple Displays within JVM. Are you launching a new JVM from within notes with that button push? What if you use Display.getDefault() instead of Display.getCurrent()?

PW


Previous Topic:embedded pdf, flash,... does not work in eclipse help with internal browser
Next Topic:Display#loadFont on gtk-linux
Goto Forum:
  


Current Time: Wed Dec 17 20:08:26 GMT 2014

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

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