public SteganoDialog(Controller controller) {
		super();
		setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);

		bundle = Application.getResourceBundle();

		setTitle("Steganography");

		// Closing the window is equal to pressing the Abort-Button
		WindowListener windowListener = (new WindowAdapter() {
			public void windowClosing(WindowEvent evt) {
				pressedAbort();
			}
		});
		addWindowListener(windowListener);

		ActionListener actionListener = (new ActionListener() {
			public void actionPerformed(ActionEvent evt) {
				if (evt.getSource() == btEncrypt)
					pressedEncrypt();
				else if (evt.getSource() == btDecrypt)
					pressedDecrypt();
				else if (evt.getSource() == btAbort)
					pressedAbort();
			}
		});

		// Enter is equal to pressing the Send-Button and
		// Escape is equal to pressing the Abort-Button
		KeyListener keyListener = (new KeyAdapter() {
			@Override
			public void keyPressed(KeyEvent evt) {
				if (evt.getKeyCode() == KeyEvent.VK_ESCAPE)
					pressedAbort();
			}
		});
		addKeyListener(keyListener);

		imgPickerTxt = new JLabel("Image:");
		filePickertxt = new JLabel("File:");
		stegInfo = new JLabel("Hide a file in an image!");
		filePickertxt.setHorizontalAlignment(JLabel.RIGHT);

		pfPasswd = new JPasswordField("");
		btEncrypt = new JButton("Encrypt");
		btDecrypt = new JButton("Decrypt");
		btAbort = new JButton(bundle.getString("cancel"));
		imgchooser = new JFileChooser();
		fchooser = new JFileChooser();
		btImgChoose = new JButton("Choose Image");
		btFChoose = new JButton("Choose file");
		txtImage = new JTextField("");
		txtFile = new JTextField("");
		btImgChoose.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent e) {
				try {
					if (fchooser.showOpenDialog(null) == JFileChooser.APPROVE_OPTION)
						txtImage.setText(fchooser.getSelectedFile().getCanonicalPath());
				} catch (IOException ioex) {
					displayError(bundle.getString("error"), ioex.getLocalizedMessage());
				}
			}
		});

		btFChoose.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent e) {
				try {
					if (fchooser.showOpenDialog(null) == JFileChooser.APPROVE_OPTION)
						txtFile.setText(fchooser.getSelectedFile().getCanonicalPath());
				} catch (IOException ioex) {
					displayError(bundle.getString("error"), ioex.getLocalizedMessage());
				}
			}
		});

		imgPickerTxt.setHorizontalAlignment(JLabel.RIGHT);

		btEncrypt.addActionListener(actionListener);
		btDecrypt.addActionListener(actionListener);

		btAbort.addActionListener(actionListener);
		btAbort.addKeyListener(keyListener);

		JPanel pnlMain = new JPanel();
		pnlMain.setBorder(BorderFactory.createEmptyBorder(8, 8, 10, 8));
		pnlMain.setLayout(new GridLayout(4, 1, 4, 4));

		pnlMain.add(stegInfo);
		JPanel imgPickPnl = new JPanel();
		imgPickPnl.setLayout(new GridLayout(1, 3, 2, 2));
		imgPickPnl.add(imgPickerTxt);
		imgPickPnl.add(txtImage);
		imgPickPnl.add(btImgChoose);
		pnlMain.add(imgPickPnl);

		JPanel fPickPanel = new JPanel();
		fPickPanel.setLayout(new GridLayout(1, 3, 2, 2));
		fPickPanel.add(filePickertxt);
		fPickPanel.add(txtFile);
		fPickPanel.add(btFChoose);
		pnlMain.add(fPickPanel);

		JPanel buttonPannel = new JPanel();
		buttonPannel.setLayout(new GridLayout(1, 3, 2, 2));
		buttonPannel.add(btEncrypt);
		buttonPannel.add(btDecrypt);
		buttonPannel.add(btAbort);
		pnlMain.add(buttonPannel);
		Container contFrame = getContentPane();
		contFrame.setLayout(new BorderLayout());
		contFrame.add(pnlMain, "Center");

		pack();

	}