/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package eu.ggnet.saft.sample.support; import eu.ggnet.saft.core.Alert; import eu.ggnet.saft.api.ui.ClosedListener; import eu.ggnet.saft.api.ui.Frame; /** * * @author oliver.guenther */ @Frame public class PanelAsFrame extends javax.swing.JPanel implements ClosedListener { /** * Creates new form PanelAsFrame */ public PanelAsFrame() { initComponents(); } @Override public void closed() { Alert.show(this + " got closed !"); } /** * 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() { jLabel1 = new javax.swing.JLabel(); setLayout(new java.awt.BorderLayout()); jLabel1.setFont(new java.awt.Font("DejaVu Sans", 0, 24)); // NOI18N jLabel1.setText("Panel that shoud be a frame with ClosedListener"); add(jLabel1, java.awt.BorderLayout.CENTER); }// </editor-fold>//GEN-END:initComponents // Variables declaration - do not modify//GEN-BEGIN:variables private javax.swing.JLabel jLabel1; // End of variables declaration//GEN-END:variables }