private void initListeners() {

        ToolsTableListener listener = new ToolsTableListener(toolsTable, toolsTableModel, this);
        toolsTable.getSelectionModel().addListSelectionListener(listener);
        toolsTable.addMouseListener(listener);
        toolsTable.addMouseMotionListener(listener);


        serverPrefsBrowseButton.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                File selectedFile = null;

                JFileChooser fileChooser = new JFileChooser();
                fileChooser.setFileSelectionMode(JFileChooser.FILES_ONLY);
                fileChooser.setFileHidingEnabled(false);
                String s = serverPrefsField.getText();
                File f = new File(s);

                if ( f.exists() )
                    fileChooser.setCurrentDirectory(f);
                
                if (fileChooser.showOpenDialog(sif) == JFileChooser.APPROVE_OPTION)
                    selectedFile = fileChooser.getSelectedFile();

                if (selectedFile != null)
                    serverPrefsField.setText(selectedFile.getPath());
            }

        });


        serverLibCheckbox.addItemListener(new ItemListener() {

            public void itemStateChanged(ItemEvent e) {
                boolean installPipeline = Boolean.parseBoolean(Configuration.getConfig(Configuration.CONFIG_INSTALL_PIPELINE));

                if (installPipeline || !serverLibCheckbox.isSelected()) {
                    serverPrefsLabel.setVisible(false);
                    serverPrefsField.setVisible(false);
                    serverPrefsBrowseButton.setVisible(false);
                } else {
                    serverPrefsLabel.setVisible(true);
                    serverPrefsField.setVisible(true);
                    serverPrefsBrowseButton.setVisible(true);
                }
            }

        });

        toolsTableModel.addTableModelListener(new TableModelListener() {

            public void tableChanged(TableModelEvent e) {
                List<String> sizeList = new LinkedList<String>();

                for ( int i = 0; i < toolsTable.getRowCount(); i++ ) {

                    Boolean isSelected = (Boolean)toolsTable.getValueAt(i, ToolsTableModel.COLUMN_SELECTED);

                    if ( !isSelected )
                        continue;

                    sizeList.add((String)toolsTable.getValueAt(i, ToolsTableModel.COLUMN_SIZE));
                }
                String totalSize = Configuration.calculateTotalSize(sizeList);
                totalSizeLabel.setText("Total size: " + totalSize);
            }

        });



    }