aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/kr/syeyoung/dungeonsguide/roomedit/panes/GeneralEditPane.java
diff options
context:
space:
mode:
authorsyeyoung <42869671+cyoung06@users.noreply.github.com>2020-11-25 22:22:24 +0900
committersyeyoung <42869671+cyoung06@users.noreply.github.com>2020-11-25 22:22:24 +0900
commit3a3b70806358e5e44232e793c84879514b1857b4 (patch)
tree2e3b77b56c1b0234b4deef384b3c8dd9eb2752cf /src/main/java/kr/syeyoung/dungeonsguide/roomedit/panes/GeneralEditPane.java
parenta34fa2c68fd4a1c47fd22d5de5b87959210eceab (diff)
downloadSkyblock-Dungeons-Guide-3a3b70806358e5e44232e793c84879514b1857b4.tar.gz
Skyblock-Dungeons-Guide-3a3b70806358e5e44232e793c84879514b1857b4.tar.bz2
Skyblock-Dungeons-Guide-3a3b70806358e5e44232e793c84879514b1857b4.zip
conttexaltasdhuewbgsidqeaghosguh[ujw-fia
Diffstat (limited to 'src/main/java/kr/syeyoung/dungeonsguide/roomedit/panes/GeneralEditPane.java')
-rw-r--r--src/main/java/kr/syeyoung/dungeonsguide/roomedit/panes/GeneralEditPane.java20
1 files changed, 18 insertions, 2 deletions
diff --git a/src/main/java/kr/syeyoung/dungeonsguide/roomedit/panes/GeneralEditPane.java b/src/main/java/kr/syeyoung/dungeonsguide/roomedit/panes/GeneralEditPane.java
index eec9a63b..51ccc1d5 100644
--- a/src/main/java/kr/syeyoung/dungeonsguide/roomedit/panes/GeneralEditPane.java
+++ b/src/main/java/kr/syeyoung/dungeonsguide/roomedit/panes/GeneralEditPane.java
@@ -2,6 +2,7 @@ package kr.syeyoung.dungeonsguide.roomedit.panes;
import kr.syeyoung.dungeonsguide.dungeon.roomfinder.DungeonRoom;
import kr.syeyoung.dungeonsguide.dungeon.roomfinder.DungeonRoomInfoRegistry;
+import kr.syeyoung.dungeonsguide.roomedit.EditingContext;
import kr.syeyoung.dungeonsguide.roomedit.MPanel;
import kr.syeyoung.dungeonsguide.roomedit.elements.*;
import kr.syeyoung.dungeonsguide.roomprocessor.ProcessorFactory;
@@ -20,6 +21,7 @@ public class GeneralEditPane extends MPanel {
private MLabelAndElement shape2;
private MButton save;
+ private MButton end;
private MLabelAndElement roomProcessor;
@@ -84,6 +86,19 @@ System.out.println("building");
});
}
{
+ end = new MButton();
+ end.setText("End Editing Session");
+ end.setOnActionPerformed(new Runnable() {
+ @Override
+ public void run() {
+ EditingContext.endEditingSession();
+ }
+ });
+ end.setBackgroundColor(Color.green);
+ end.setBounds(new Rectangle(0,120,bounds.width, 20));
+ add(end);
+ }
+ {
if (dungeonRoom.getDungeonRoomInfo().isRegistered()) return;
save = new MButton();
save.setText("Save RoomData");
@@ -95,7 +110,7 @@ System.out.println("building");
}
});
save.setBackgroundColor(Color.green);
- save.setBounds(new Rectangle(1,120,bounds.width-2, 20));
+ save.setBounds(new Rectangle(0,140,bounds.width, 20));
add(save);
System.out.println(save.getBounds());
}
@@ -109,6 +124,7 @@ System.out.println("building");
@Override
public void onBoundsUpdate() {
if (save != null)
- save.setBounds(new Rectangle(0,120,bounds.width, 20));
+ save.setBounds(new Rectangle(0,140,bounds.width, 20));
+ end.setBounds(new Rectangle(1,120,bounds.width-2, 20));
}
}