From 2fbaf8774aece20938f4ea373876c70372ba8366 Mon Sep 17 00:00:00 2001 From: Frida Tveit Date: Wed, 4 Jan 2017 17:49:30 +0000 Subject: [PATCH] Removed unneeded uses of 'this' in FrameComponentInit --- .../gui/windows/FrameComponentInit.java | 44 +++++++++---------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/src/main/java/net/sf/javaanpr/gui/windows/FrameComponentInit.java b/src/main/java/net/sf/javaanpr/gui/windows/FrameComponentInit.java index b996766..0c0138a 100644 --- a/src/main/java/net/sf/javaanpr/gui/windows/FrameComponentInit.java +++ b/src/main/java/net/sf/javaanpr/gui/windows/FrameComponentInit.java @@ -32,12 +32,12 @@ public class FrameComponentInit extends JFrame { * Creates new form FrameComponentInit. */ public FrameComponentInit() { - this.initComponents(); + initComponents(); Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize(); - int width = this.getWidth(); - int height = this.getHeight(); - this.setLocation((screenSize.width - width) / 2, (screenSize.height - height) / 2); - this.setVisible(true); + int width = getWidth(); + int height = getHeight(); + setLocation((screenSize.width - width) / 2, (screenSize.height - height) / 2); + setVisible(true); } /** @@ -45,24 +45,24 @@ public FrameComponentInit() { * content of this method is always regenerated by the Form Editor. */ private void initComponents() { - this.label = new JLabel(); - this.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); - this.setTitle("Initializing system logic"); - this.setAlwaysOnTop(true); - this.setCursor(new java.awt.Cursor(java.awt.Cursor.WAIT_CURSOR)); - this.setFocusable(false); - this.setResizable(false); - this.setUndecorated(true); - this.label.setFont(new java.awt.Font("Arial", 0, 14)); - this.label.setHorizontalAlignment(SwingConstants.CENTER); - this.label.setText("Starting application, please wait ..."); - this.label.setBorder(BorderFactory.createBevelBorder(BevelBorder.RAISED)); - GroupLayout layout = new GroupLayout(this.getContentPane()); - this.getContentPane().setLayout(layout); + label = new JLabel(); + setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); + setTitle("Initializing system logic"); + setAlwaysOnTop(true); + setCursor(new java.awt.Cursor(java.awt.Cursor.WAIT_CURSOR)); + setFocusable(false); + setResizable(false); + setUndecorated(true); + label.setFont(new java.awt.Font("Arial", 0, 14)); + label.setHorizontalAlignment(SwingConstants.CENTER); + label.setText("Starting application, please wait ..."); + label.setBorder(BorderFactory.createBevelBorder(BevelBorder.RAISED)); + GroupLayout layout = new GroupLayout(getContentPane()); + getContentPane().setLayout(layout); layout.setHorizontalGroup(layout.createParallelGroup(GroupLayout.LEADING) - .add(this.label, GroupLayout.DEFAULT_SIZE, 431, Short.MAX_VALUE)); + .add(label, GroupLayout.DEFAULT_SIZE, 431, Short.MAX_VALUE)); layout.setVerticalGroup(layout.createParallelGroup(GroupLayout.LEADING) - .add(this.label, GroupLayout.DEFAULT_SIZE, 50, Short.MAX_VALUE)); - this.pack(); + .add(label, GroupLayout.DEFAULT_SIZE, 50, Short.MAX_VALUE)); + pack(); } }