Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Shell titlebar minimize button
Shell titlebar minimize button [message #88836] Tue, 20 May 2008 13:49 Go to next message
NkD Missing name is currently offline NkD Missing nameFriend
Messages: 61
Registered: July 2009
Member
I have problem with minimize button in shell's title bar.

Scenario for snippet:
1. click at button "Open". Shell is correctly open and show to user.
2. click at SWT.MIN button in top right corner (titlebar) in opened
shell. Shell correctly disappear.
3. click at button "Show". Nothing happens. BUG. I analyze why shell do
not show at this moment and I think that shell have bad setting
attributes (minimize, visible and maybe others) because it was not set
in scenario step 2.

addition:

4. click at button "Hide". Nothing happens. Correct. This step I make
only for correct minimize attribute on shell.
5. click at button "Show". Shell is visible.


Snippet:

import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.ui.part.ViewPart;

public class TestView extends ViewPart{

@Override
public void createPartControl(Composite parent) {
final Shell shell = new
Shell(Display.getCurrent().getActiveShell(), SWT.SHELL_TRIM);
shell.setBounds(50, 50, 200, 200);

Button btnOpen = new Button(parent, SWT.PUSH);
btnOpen.setText("Open");
btnOpen.addSelectionListener(new SelectionAdapter(){
public void widgetSelected(SelectionEvent e) {
shell.open();
}
});

Button btnHide = new Button(parent, SWT.PUSH);
btnHide.setText("Hide");
btnHide.addSelectionListener(new SelectionAdapter(){
public void widgetSelected(SelectionEvent e) {
shell.setMinimized(true);
}
});

Button btnShow = new Button(parent, SWT.PUSH);
btnShow.setText("Show");
btnShow.addSelectionListener(new SelectionAdapter(){
public void widgetSelected(SelectionEvent e) {
shell.setMinimized(false);
}
});
}

@Override
public void setFocus() {
//nothing
}

}
Re: Shell titlebar minimize button [message #88917 is a reply to message #88836] Tue, 20 May 2008 18:55 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: rherrmann.innoopract.com

Hi,

thanks for pointing this out, which version of RAP did you use?

Cheers,
Rüdiger

Michal NkD Nikodím wrote:
> I have problem with minimize button in shell's title bar.
>
> Scenario for snippet:
> 1. click at button "Open". Shell is correctly open and show to user.
> 2. click at SWT.MIN button in top right corner (titlebar) in opened
> shell. Shell correctly disappear.
> 3. click at button "Show". Nothing happens. BUG. I analyze why shell do
> not show at this moment and I think that shell have bad setting
> attributes (minimize, visible and maybe others) because it was not set
> in scenario step 2.
>
> addition:
>
> 4. click at button "Hide". Nothing happens. Correct. This step I make
> only for correct minimize attribute on shell.
> 5. click at button "Show". Shell is visible.
>
>
> Snippet:
>
> import org.eclipse.swt.SWT;
> import org.eclipse.swt.events.SelectionAdapter;
> import org.eclipse.swt.events.SelectionEvent;
> import org.eclipse.swt.widgets.Button;
> import org.eclipse.swt.widgets.Composite;
> import org.eclipse.swt.widgets.Display;
> import org.eclipse.swt.widgets.Shell;
> import org.eclipse.ui.part.ViewPart;
>
> public class TestView extends ViewPart{
>
> @Override
> public void createPartControl(Composite parent) {
> final Shell shell = new
> Shell(Display.getCurrent().getActiveShell(), SWT.SHELL_TRIM);
> shell.setBounds(50, 50, 200, 200);
>
> Button btnOpen = new Button(parent, SWT.PUSH);
> btnOpen.setText("Open");
> btnOpen.addSelectionListener(new SelectionAdapter(){
> public void widgetSelected(SelectionEvent e) {
> shell.open();
> }
> });
>
> Button btnHide = new Button(parent, SWT.PUSH);
> btnHide.setText("Hide");
> btnHide.addSelectionListener(new SelectionAdapter(){
> public void widgetSelected(SelectionEvent e) {
> shell.setMinimized(true);
> }
> });
>
> Button btnShow = new Button(parent, SWT.PUSH);
> btnShow.setText("Show");
> btnShow.addSelectionListener(new SelectionAdapter(){
> public void widgetSelected(SelectionEvent e) {
> shell.setMinimized(false);
> }
> });
> }
>
> @Override
> public void setFocus() {
> //nothing
> }
>
> }
Re: Shell titlebar minimize button [message #88947 is a reply to message #88917] Wed, 21 May 2008 01:51 Go to previous messageGo to next message
NkD Missing name is currently offline NkD Missing nameFriend
Messages: 61
Registered: July 2009
Member
Tested on Rap M3 and Rap Head (synchronized cca 5 days ago). Both version
have same problem.
Re: Shell titlebar minimize button [message #89082 is a reply to message #88947] Wed, 21 May 2008 10:57 Go to previous message
Eclipse UserFriend
Originally posted by: rherrmann.innoopract.com

Hi,

I filed this bugzilla to track progress on this:
233188: [Shell] opening/restoring after minimizing via min-button
does not work
https://bugs.eclipse.org/bugs/show_bug.cgi?id=233188

Cheers,
Rüdiger

Michal Nikodim wrote:
> Tested on Rap M3 and Rap Head (synchronized cca 5 days ago). Both
> version have same problem.
>
Previous Topic:Prevent user from closing view
Next Topic:[ANN] RAP 1.1 RC1 released
Goto Forum:
  


Current Time: Tue Sep 24 06:29:07 GMT 2024

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

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

Back to the top