diff -r d40099dbbdd1 -r 5816c7f61a2a java/abc-drupal-gui/src/cz/frantovo/abcDrupal/gui/HlavniOkno.java --- a/java/abc-drupal-gui/src/cz/frantovo/abcDrupal/gui/HlavniOkno.java Thu Dec 31 18:41:04 2009 +0100 +++ b/java/abc-drupal-gui/src/cz/frantovo/abcDrupal/gui/HlavniOkno.java Fri Jan 01 16:44:46 2010 +0100 @@ -25,6 +25,7 @@ /** Creates new form HlavniOkno */ public HlavniOkno() { initComponents(); + setLocationRelativeTo(null); nactiPromenneProstredi(); } @@ -54,7 +55,7 @@ jdbcCil = new javax.swing.JTextField(); jScrollPane1 = new javax.swing.JScrollPane(); vystup = new javax.swing.JTextArea(); - jButton1 = new javax.swing.JButton(); + nahratData = new javax.swing.JButton(); setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); setTitle("ABC-Drupal"); @@ -63,9 +64,9 @@ jLabel2.setText("Cíl"); - jdbcZdroj.setText("jdbcZdroj"); + jdbcZdroj.setText("jdbc:mysql://127.0.0.1:3306/itbiz?user=itbiz&password=nbusr123"); - jdbcCil.setText("jdbcCil"); + jdbcCil.setText("jdbc:mysql://127.0.0.1:3306/abclinuxu?user=abclinuxu&password=nbusr123"); vystup.setColumns(20); vystup.setEditable(false); @@ -73,10 +74,10 @@ vystup.setEnabled(false); jScrollPane1.setViewportView(vystup); - jButton1.setText("Nahrát data"); - jButton1.addActionListener(new java.awt.event.ActionListener() { + nahratData.setText("Nahrát data"); + nahratData.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { - jButton1ActionPerformed(evt); + nahratDataActionPerformed(evt); } }); @@ -96,7 +97,7 @@ .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jdbcCil, javax.swing.GroupLayout.DEFAULT_SIZE, 560, Short.MAX_VALUE) .addComponent(jdbcZdroj, javax.swing.GroupLayout.DEFAULT_SIZE, 560, Short.MAX_VALUE))) - .addComponent(jButton1)) + .addComponent(nahratData)) .addContainerGap()) ); layout.setVerticalGroup( @@ -113,17 +114,17 @@ .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 152, Short.MAX_VALUE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) - .addComponent(jButton1) + .addComponent(nahratData) .addContainerGap()) ); pack(); }// //GEN-END:initComponents - private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton1ActionPerformed + private void nahratDataActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_nahratDataActionPerformed Konvertor k = new Konvertor(jdbcZdroj.getText(), jdbcCil.getText(), this); k.konvertuj(); - }//GEN-LAST:event_jButton1ActionPerformed + }//GEN-LAST:event_nahratDataActionPerformed /** * @param args the command line arguments @@ -147,12 +148,12 @@ } } // Variables declaration - do not modify//GEN-BEGIN:variables - private javax.swing.JButton jButton1; private javax.swing.JLabel jLabel1; private javax.swing.JLabel jLabel2; private javax.swing.JScrollPane jScrollPane1; private javax.swing.JTextField jdbcCil; private javax.swing.JTextField jdbcZdroj; + private javax.swing.JButton nahratData; private javax.swing.JTextArea vystup; // End of variables declaration//GEN-END:variables