From: Kevin Lamonte Date: Thu, 21 Feb 2019 20:40:56 +0000 (-0600) Subject: misc cleanup X-Git-Tag: fanfix-swing-0.0.1~12^2~13^2~183 X-Git-Url: https://git.nikiroo.be/?a=commitdiff_plain;h=c88c4ced6e9392a53030a1c680fe114931a1a928;p=fanfix-swing.git misc cleanup --- diff --git a/src/jexer/TEditorWindow.java b/src/jexer/TEditorWindow.java index 49513110..b64f0c71 100644 --- a/src/jexer/TEditorWindow.java +++ b/src/jexer/TEditorWindow.java @@ -386,7 +386,7 @@ public class TEditorWindow extends TScrollableWindow { * @param mouse a mouse-based event * @return whether or not the mouse is on the editor */ - private final boolean mouseOnEditor(final TMouseEvent mouse) { + private boolean mouseOnEditor(final TMouseEvent mouse) { if ((mouse.getAbsoluteX() >= getAbsoluteX() + 1) && (mouse.getAbsoluteX() < getAbsoluteX() + getWidth() - 1) && (mouse.getAbsoluteY() >= getAbsoluteY() + 1) diff --git a/src/jexer/TList.java b/src/jexer/TList.java index 0ed7a070..3aed01ed 100644 --- a/src/jexer/TList.java +++ b/src/jexer/TList.java @@ -29,7 +29,6 @@ package jexer; import java.util.ArrayList; -import java.util.Collections; import java.util.List; import jexer.bits.CellAttributes; diff --git a/src/jexer/TTerminalWindow.java b/src/jexer/TTerminalWindow.java index a243a43c..897dca73 100644 --- a/src/jexer/TTerminalWindow.java +++ b/src/jexer/TTerminalWindow.java @@ -854,7 +854,7 @@ public class TTerminalWindow extends TScrollableWindow * @param mouse a mouse-based event * @return whether or not the mouse is on the emulator */ - private final boolean mouseOnEmulator(final TMouseEvent mouse) { + private boolean mouseOnEmulator(final TMouseEvent mouse) { synchronized (emulator) { if (!emulator.isReading()) { diff --git a/src/jexer/TWindow.java b/src/jexer/TWindow.java index 16945496..3f860d63 100644 --- a/src/jexer/TWindow.java +++ b/src/jexer/TWindow.java @@ -32,7 +32,6 @@ import java.util.HashSet; import java.util.Set; import jexer.backend.Screen; -import jexer.bits.Cell; import jexer.bits.CellAttributes; import jexer.bits.GraphicsChars; import jexer.event.TCommandEvent; @@ -1195,6 +1194,7 @@ public class TWindow extends TWidget { * Close window. Note that windows without a close box can still be * closed by calling the close() method. */ + @Override public void close() { application.closeWindow(this); } diff --git a/src/jexer/backend/ECMA48Terminal.java b/src/jexer/backend/ECMA48Terminal.java index 0cbd4f05..518024c5 100644 --- a/src/jexer/backend/ECMA48Terminal.java +++ b/src/jexer/backend/ECMA48Terminal.java @@ -45,7 +45,6 @@ import java.util.Collections; import java.util.HashMap; import java.util.List; import java.util.LinkedList; -import java.util.Map; import jexer.TImage; import jexer.bits.Cell; diff --git a/src/jexer/backend/TWindowBackend.java b/src/jexer/backend/TWindowBackend.java index a34ba78b..ed701ad0 100644 --- a/src/jexer/backend/TWindowBackend.java +++ b/src/jexer/backend/TWindowBackend.java @@ -31,7 +31,6 @@ package jexer.backend; import java.util.LinkedList; import java.util.List; -import jexer.bits.CellAttributes; import jexer.event.TInputEvent; import jexer.event.TKeypressEvent; import jexer.event.TMouseEvent; diff --git a/src/jexer/tterminal/ECMA48.java b/src/jexer/tterminal/ECMA48.java index 00aa05bc..a4197fb9 100644 --- a/src/jexer/tterminal/ECMA48.java +++ b/src/jexer/tterminal/ECMA48.java @@ -4095,12 +4095,12 @@ public class ECMA48 implements Runnable { if (collectBuffer.charAt(0) == '>') { extendedFlag = 1; if (collectBuffer.length() >= 2) { - i = Integer.parseInt(args.toString()); + i = Integer.parseInt(args); } } else if (collectBuffer.charAt(0) == '=') { extendedFlag = 2; if (collectBuffer.length() >= 2) { - i = Integer.parseInt(args.toString()); + i = Integer.parseInt(args); } } else { // Unknown code, bail out @@ -4542,7 +4542,7 @@ public class ECMA48 implements Runnable { args = collectBuffer.substring(0, collectBuffer.length() - 2); } - String [] p = args.toString().split(";"); + String [] p = args.split(";"); if (p.length > 0) { if ((p[0].equals("0")) || (p[0].equals("2"))) { if (p.length > 1) { diff --git a/src/jexer/ttree/TDirectoryTreeItem.java b/src/jexer/ttree/TDirectoryTreeItem.java index 5f265ee5..9bdec01d 100644 --- a/src/jexer/ttree/TDirectoryTreeItem.java +++ b/src/jexer/ttree/TDirectoryTreeItem.java @@ -35,7 +35,6 @@ import java.util.List; import java.util.LinkedList; import jexer.TWidget; -import jexer.ttree.TTreeViewWidget; /** * TDirectoryTreeItem is a single item in a disk directory tree view.