private Boolean openFile() {
		if (graphDrawingArea.wasModified()) {
			switch (JOptionPane.showConfirmDialog(this, "O projeto atual foi alterado.\nAbrir um novo arquivo fará com que o arquivo atual seja perdido.\nDeseja continuar?", "Atenção!", JOptionPane.YES_NO_OPTION, JOptionPane.WARNING_MESSAGE, ((Icon)new ImageIcon(theLogo)))) {
				case JOptionPane.YES_OPTION :
					String filename = "";
					JFileChooser chooser = new JFileChooser();
					int itsOkOrNot;
					itsOkOrNot = chooser.showOpenDialog(this);
					if(itsOkOrNot == JFileChooser.APPROVE_OPTION) {
						filename = chooser.getSelectedFile().getAbsolutePath();//+chooser.getSelectedFile().getName();
						System.out.println("[JGrape.java] Arquivo selecionado: "+filename);
						FileInputStream fis = null;
						ObjectInputStream in = null;
						try {
							fis = new FileInputStream(filename);
							in = new ObjectInputStream(fis);
							thisPane.remove(graphDrawingArea);
							graphDrawingArea=((GraphPanel)in.readObject());
							thisPane.add(graphDrawingArea);
							thisPane.repaint();
							graphDrawingArea.repaint();
							repaint();
							
							in.close();
							graphDrawingArea.setConsoleMessage("Arquivo aberto: "+filename);
							return true;
						} catch(IOException ex) {
							ex.printStackTrace();
							graphDrawingArea.setConsoleMessage("Erro ao abrir arquivo.");
							return false;
						} catch(ClassNotFoundException ex) {
							ex.printStackTrace();
							graphDrawingArea.setConsoleMessage("Erro ao abrir arquivo.");
							return false;
						}
					}
					
				case JOptionPane.NO_OPTION:
					//nothing
					return false;
					
				default:
					//nothing
					return false;
			}
		} else {
			String filename = "";
			JFileChooser chooser = new JFileChooser();
			int itsOkOrNot;
			itsOkOrNot = chooser.showOpenDialog(this);
			if(itsOkOrNot == JFileChooser.APPROVE_OPTION) {
				filename = chooser.getSelectedFile().getAbsolutePath();
				FileInputStream fis = null;
				ObjectInputStream in = null;
				try {
					fis = new FileInputStream(filename);
					in = new ObjectInputStream(fis);
					thisPane.remove(graphDrawingArea);
					graphDrawingArea=((GraphPanel)in.readObject());
					thisPane.add(graphDrawingArea);
					thisPane.repaint();
					graphDrawingArea.repaint();
					repaint();
					
					in.close();
					return true;
				} catch(IOException ex) {
					ex.printStackTrace();
					return false;
				} catch(ClassNotFoundException ex) {
					ex.printStackTrace();
					return false;
				}
			}
		}
		return false;
	}