path = buffer.getVFS().getFileParent(
path = buffer.getVFS().getParentOfPath(
	public VFSBrowser(View view, String path, int mode, boolean multipleSelection)	{		super(new BorderLayout());		listenerList = new EventListenerList();		this.mode = mode;		this.multipleSelection = multipleSelection;		this.view = view;		Box topBox = new Box(BoxLayout.Y_AXIS);		topBox.add(createToolBar());		GridBagLayout layout = new GridBagLayout();		JPanel pathAndFilterPanel = new JPanel(layout);		GridBagConstraints cons = new GridBagConstraints();		cons.gridwidth = cons.gridheight = 1;		cons.gridx = cons.gridy = 0;		cons.fill = GridBagConstraints.BOTH;		JLabel label = new JLabel(jEdit.getProperty("vfs.browser.path"),			SwingConstants.RIGHT);		label.setBorder(new EmptyBorder(0,0,0,12));		layout.setConstraints(label,cons);		pathAndFilterPanel.add(label);		pathField = new HistoryTextField("vfs.browser.path",true);		// because its preferred size can be quite wide, we		// don't want it to make the browser way too big,		// so set the preferred width to 0.		Dimension prefSize = pathField.getPreferredSize();		prefSize.width = 0;		pathField.setPreferredSize(prefSize);		pathField.addActionListener(new ActionHandler());		cons.gridx = 1;		cons.weightx = 1.0f;		layout.setConstraints(pathField,cons);		pathAndFilterPanel.add(pathField);		label = new JLabel(jEdit.getProperty("vfs.browser.filter"),			SwingConstants.RIGHT);		label.setBorder(new EmptyBorder(0,0,0,12));		cons.gridx = 0;		cons.weightx = 0.0f;		cons.gridy = 1;		layout.setConstraints(label,cons);		pathAndFilterPanel.add(label);		filterField = new HistoryTextField("vfs.browser.filter",true);		filterField.addActionListener(new ActionHandler());		cons.gridx = 1;		cons.weightx = 1.0f;		layout.setConstraints(filterField,cons);		pathAndFilterPanel.add(filterField);		topBox.add(pathAndFilterPanel);		add(BorderLayout.NORTH,topBox);		propertiesChanged();		HistoryModel filterModel = HistoryModel.getModel("vfs.browser.filter");		String filter;		if(filterModel.getSize() == 0)			filter = jEdit.getProperty("vfs.browser.default-filter");		else			filter = filterModel.getItem(0);		try		{			filenameFilter = new RE(MiscUtilities.globToRE(filter),				RE.REG_ICASE);			filterField.setText(filter);			// so that the default will be added to the history			filterField.addCurrentToHistory();		}		catch(Exception e)		{			// leave the filter field blank		}		if(path == null)		{			String defaultPath = jEdit.getProperty("vfs.browser.defaultPath");			String userHome = System.getProperty("user.home");			if(defaultPath.equals("home"))				path = userHome;			else if(defaultPath.equals("buffer"))			{				if(view != null)				{					Buffer buffer = view.getBuffer();					path = buffer.getVFS().getFileParent(						buffer.getPath());				}				else					path = userHome;			}			else if(defaultPath.equals("last"))			{				HistoryModel pathModel = HistoryModel.getModel("vfs.browser.path");				if(pathModel.getSize() == 0)					path = userHome;				else					path = pathModel.getItem(0);			}			else			{				// unknown value??!!!				path = userHome;			}		}		setDirectory(path);	}