protected FileSystemTree(final GraphingPanel graphingPanel,
			final FileSystemTreeModel fsTreeModel) {

		super(fsTreeModel);

		popmenu = new JPopupMenu();

		final JMenuItem i0_graph = new JMenuItem("Graph");
		final JMenuItem i1_open_folder = new JMenuItem("Open Containing Folder");
		final JMenuItem i2_open_browser = new JMenuItem("Open in Browser");
		final JMenuItem i3_open_viewer = new JMenuItem("Open in Viewer");
		final JMenuItem i4_copy = new JMenuItem("Copy");

		i2_open_browser.setIcon(ImageCreator.IMG_OPENINBROWSER);
		i4_copy.setIcon(ImageCreator.IMG_COPY);

		popmenu.add(i0_graph);
		popmenu.addSeparator();
		popmenu.add(i1_open_folder);
		popmenu.add(i2_open_browser);
		popmenu.add(i3_open_viewer);
		popmenu.addSeparator();
		popmenu.add(i4_copy);

		// Graph
		i0_graph.addActionListener(new ActionListener() {

			@Override
			public void actionPerformed(final ActionEvent aEvent) {

				final String stringFile = 
					getFileFromPath(FileSystemTree.this.getSelectionPath());
				
				if(stringFile.startsWith(GR_PANEL)) {
					
					// An error occured
					Logger.log(stringFile, 4);
					
				} else {
					
					final File pathFile = new File(stringFile);
					
					if (pathFile.isFile()) {
						Logger
						.log(GR_PANEL + "Cannot graph individual files",	4);
						
					} else {

						// Let the graphing begin
						graphingPanel.getTabbedPlotter().plot(pathFile);

					}
					
				}


			}

		});

		// Open Containing Folder
		i1_open_folder.addActionListener(new ActionListener() {
			public void actionPerformed(final ActionEvent openEvt) {

				final String stringFile = 
					getFileFromPath(FileSystemTree.this.getSelectionPath());
				
				if(stringFile.startsWith(GR_PANEL)) {
					
					// An error occured
					Logger.log(stringFile, 4);
					
				} else {
					
					final File pathFile = new File(stringFile);
					final File parentFile = pathFile.getParentFile();

					Browser.init();
					
					try {
						
						Browser.displayURL(parentFile.toURI().toString());
						
					} catch (final IOException ex) {
						Logger
						.log(GR_PANEL + 
								"Could not open containing folder: " + parentFile.toString(),
								3);
					}
					
				}

			}
		});
		
		// Open in Browser
		i2_open_browser.addActionListener(new ActionListener() {
			public void actionPerformed(final ActionEvent openEvt) {

				final String stringFile = 
					getFileFromPath(FileSystemTree.this.getSelectionPath());
				
				if(stringFile.startsWith(GR_PANEL)) {
					
					// An error occured
					Logger.log(stringFile, 4);
					
				} else {
					
					final File pathFile = new File(stringFile);
					Browser.init();
					
					try {
						
						Browser.displayURL(pathFile.toURI().toString());
						
					} catch (final IOException ex) {
						Logger.log(
								GR_PANEL + "Could not open file in browser: " + pathFile.toString(),
							3
						);
					}
					
				}

			}
		});
		
		// Open in Viewer
		i3_open_viewer.addActionListener(new ActionListener() {
			public void actionPerformed(final ActionEvent openEvt) {

				final String stringFile = 
					getFileFromPath(FileSystemTree.this.getSelectionPath());
				
				if(stringFile.startsWith(GR_PANEL)) {
					
					// An error occured
					Logger.log(stringFile, 4);
					
				} else {
					
					new WindowViewerFrame(graphingPanel, stringFile);
					
				}

			}
		});
				
		// Copy
		i4_copy.addActionListener(new ActionListener() {

			@Override
			public void actionPerformed(final ActionEvent cpEvent) {

				final String stringFile = 
					getFileFromPath(FileSystemTree.this.getSelectionPath());

				if(stringFile.startsWith(GR_PANEL)) {
					
					// An error occured
					Logger.log(stringFile, 4);
					
				} else {

					final JTextArea myTempArea = new JTextArea(stringFile);
					myTempArea.selectAll();
					myTempArea.copy();
				}
			} // actionPerformed

		});


		addMouseListener(this);

	}