Skip to content

Commit 7c3e97c

Browse files
author
jossonsmith
committed
Add moving and resizing notification of Shell
1 parent a2e76b6 commit 7c3e97c

File tree

1 file changed

+10
-3
lines changed
  • sources/net.sf.j2s.java.org.eclipse.swt/src/org/eclipse/swt/widgets

1 file changed

+10
-3
lines changed

sources/net.sf.j2s.java.org.eclipse.swt/src/org/eclipse/swt/widgets/Decorations.java

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -560,9 +560,16 @@ public boolean isDraggable(HTMLEventWrapper e) {
560560
return false;
561561
}
562562
}
563-
public boolean updateShellBounds(int x, int y, final int width,
564-
final int height) {
565-
setBounds(x, y, width, height);
563+
public boolean updateShellBounds(int x, int y, int w, int h) {
564+
boolean moved = (x != left || y != top);
565+
boolean resized = (w != width || h != height);
566+
setBounds(x, y, w, h);
567+
if (moved) {
568+
sendEvent(SWT.Move);
569+
}
570+
if (resized) {
571+
sendEvent(SWT.Resize);
572+
}
566573
return true;
567574
}
568575
});

0 commit comments

Comments
 (0)