@Override
	public void actionPerformed(ActionEvent e) {
		if (e.getSource() == chooserDirectoryButton) {

			fileChooser.showDialog(this, null);

			directory = fileChooser.getSelectedFile();
			if (directory != null) {
				chosendirectory.setText(directory.toString() + File.separator
						+ log_file_name);
			}
		} else if (e.getSource() == okButton) {
			logLevel = getLevel();
			okPressed = true;
			dispose();
		} else if (e.getSource() == cancelButton) {
			okPressed = false;
			dispose();
		}

	}