From bbc74e15134239f2660433e5f01f78edad21d497 Mon Sep 17 00:00:00 2001 From: Arthur <78031901+Arthur7770@users.noreply.github.com> Date: Tue, 23 Mar 2021 17:45:20 +0100 Subject: [PATCH] First close tab button implementation --- src/lsystem/screen/main/Listener.java | 8 ++++++++ src/lsystem/screen/main/MainFrame.java | 11 ++++++++--- src/lsystem/screen/main/Tab.java | 18 ++++++++++-------- 3 files changed, 26 insertions(+), 11 deletions(-) diff --git a/src/lsystem/screen/main/Listener.java b/src/lsystem/screen/main/Listener.java index cde62d9..913a63d 100644 --- a/src/lsystem/screen/main/Listener.java +++ b/src/lsystem/screen/main/Listener.java @@ -33,6 +33,14 @@ public class Listener implements ActionListener, KeyListener { @Override public void actionPerformed(ActionEvent e) { switch (type) { + case "Close": + frame.getTab().removeTabAt(index-1); + frame.decreaseTab(); + for(int i = 0; i