/src/mpv5/ui/frames/MPCalculator2.java
Java | 100 lines | 47 code | 16 blank | 37 comment | 2 complexity | 633aa5a1c86edf3a1b0fef0546d9b7a8 MD5 | raw file
Possible License(s): LGPL-3.0, Apache-2.0, GPL-3.0, GPL-2.0, AGPL-3.0, JSON, BSD-3-Clause
- /*
- * This file is part of YaBS.
- *
- * YaBS is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * YaBS is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with YaBS. If not, see <http://www.gnu.org/licenses/>.
- */
- /*
- * MPCalculator2.java
- *
- * Created on 12.02.2009, 14:30:32
- */
- package mpv5.ui.frames;
- import java.awt.BorderLayout;
- import mpv5.ui.misc.Position;
- import mpv5.ui.misc.Calc;
- /**
- *
- *
- */
- public class MPCalculator2 extends javax.swing.JFrame {
- private static MPCalculator2 calc;
- private static final long serialVersionUID = 1L;
- /** Creates new form MPCalculator2 */
- private MPCalculator2() {
- initComponents();
- jPanel1.add(new Calc(), BorderLayout.CENTER);
- setSize(340, 300);
- setResizable(false);
- new Position(this);
- }
- public static MPCalculator2 instanceOf() {
- if (calc == null) {
- calc = new MPCalculator2();
- }
- calc.setVisible(true);
- return calc;
- }
- /**
- *
- */
- @Override
- public void dispose() {
- setVisible(false);
- }
- /** This method is called from within the constructor to
- * initialize the form.
- * WARNING: Do NOT modify this code. The content of this method is
- * always regenerated by the Form Editor.
- */
- @SuppressWarnings("unchecked")
- // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
- private void initComponents() {
- jPanel1 = new javax.swing.JPanel();
- setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
- setTitle("Yabs Calc");
- setName("Form"); // NOI18N
- jPanel1.setName("jPanel1"); // NOI18N
- jPanel1.setLayout(new java.awt.BorderLayout());
- javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
- getContentPane().setLayout(layout);
- layout.setHorizontalGroup(
- layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
- .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, 277, Short.MAX_VALUE)
- );
- layout.setVerticalGroup(
- layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
- .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, 139, Short.MAX_VALUE)
- );
- pack();
- }// </editor-fold>//GEN-END:initComponents
- // Variables declaration - do not modify//GEN-BEGIN:variables
- private javax.swing.JPanel jPanel1;
- // End of variables declaration//GEN-END:variables
- }