File tree Expand file tree Collapse file tree 2 files changed +11
-17
lines changed
ui/helper/historyui/undoredoLog Expand file tree Collapse file tree 2 files changed +11
-17
lines changed Original file line number Diff line number Diff line change @@ -111,22 +111,7 @@ private void addLineSegment(LineSegment lineSegment) {
111111 // change selection
112112 panel .getSelectTool ().clearSelection ();
113113 panel .getSelectTool ().selectComponent (lineSegment );
114- // push action to the manager
115- SharedUndoRedoActionManager .getSharedInstance ().pushUndoableAction (
116- new UndoRedoableInterface () {
117-
118- @ Override
119- public void undoAction () {
120- lineSegment .remove (panel );
121- panel .repaint ();
122- }
123-
124- @ Override
125- public void redoAction () {
126- panel .addPaintComponent (lineSegment );
127- panel .repaint ();
128- }
129- });
114+
130115 panel .repaint ();
131116 }
132117}
Original file line number Diff line number Diff line change @@ -42,10 +42,19 @@ public void run() {
4242 undoredoLog .setVisible (true );
4343 undoredoLog .setSize (new Dimension (500 , 400 ));
4444
45+ try {
46+ Thread .sleep (2000 );
47+ } catch (InterruptedException e ) {
48+ // TODO Auto-generated catch block
49+ e .printStackTrace ();
50+ }
51+ undoredoLog .dispose ();
52+
53+
4554
4655 }
4756 });
48- Thread .sleep (Long . MAX_VALUE );
57+ Thread .sleep (5000 );
4958 }
5059
5160
You can’t perform that action at this time.
0 commit comments