From 9c0ae3b169bc28510aeb290eebe48bc82dcdf9d2 Mon Sep 17 00:00:00 2001 From: Marc Englund Date: Tue, 2 Dec 2008 09:47:46 +0000 Subject: [PATCH] "Force layout" -button added. svn changeset:6063/svn branch:trunk --- .../toolkit/terminal/gwt/client/IDebugConsole.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/com/itmill/toolkit/terminal/gwt/client/IDebugConsole.java b/src/com/itmill/toolkit/terminal/gwt/client/IDebugConsole.java index facc3f3b2e..c6464df23d 100755 --- a/src/com/itmill/toolkit/terminal/gwt/client/IDebugConsole.java +++ b/src/com/itmill/toolkit/terminal/gwt/client/IDebugConsole.java @@ -42,6 +42,7 @@ public final class IDebugConsole extends IToolkitOverlay implements Console { private Button clear = new Button("Clear console"); private Button restart = new Button("Restart app"); + private Button forceLayout = new Button("Force layout"); private HorizontalPanel actions; private boolean collapsed = false; @@ -57,6 +58,8 @@ public final class IDebugConsole extends IToolkitOverlay implements Console { private int origLeft; + private ApplicationConnection client; + private static final String help = "Drag=move, shift-drag=resize, doubleclick=min/max." + "Use debug=quiet to log only to browser console."; @@ -64,6 +67,8 @@ public final class IDebugConsole extends IToolkitOverlay implements Console { ApplicationConfiguration cnf, boolean showWindow) { super(false, false); + this.client = client; + panel = new FlowPanel(); if (showWindow) { DOM.appendChild(getContainerElement(), caption); @@ -89,6 +94,7 @@ public final class IDebugConsole extends IToolkitOverlay implements Console { actions = new HorizontalPanel(); actions.add(clear); actions.add(restart); + actions.add(forceLayout); panel.add(actions); @@ -127,6 +133,12 @@ public final class IDebugConsole extends IToolkitOverlay implements Console { } }); + + forceLayout.addClickListener(new ClickListener() { + public void onClick(Widget sender) { + IDebugConsole.this.client.forceLayout(); + } + }); } log("Toolkit application servlet version: " + cnf.getSerletVersion()); -- 2.39.5