if(isPerformingIO()) { GUIUtilities.error(view,"buffer-multiple-io",null); return false; }  setBooleanProperty(BufferIORequest.ERROR_OCCURRED,false);  if(path == null && getFlag(NEW_FILE)) return saveAs(view,rename);  if(path == null && file != null) { long newModTime = file.lastModified();  if(newModTime != modTime && jEdit.getBooleanProperty("view.checkModStatus")) { Object[] args = { this.path }; int result = GUIUtilities.confirm(view, "filechanged-save",args, JOptionPane.YES_NO_OPTION, JOptionPane.WARNING_MESSAGE); if(result != JOptionPane.YES_OPTION) return false; } }  setFlag(IO,true); EditBus.send(new BufferUpdate(this,view,BufferUpdate.SAVING));  final String oldPath = this.path; final String newPath = (path == null ? this.path : path);  VFS vfs = VFSManager.getVFSForPath(newPath);  if(!checkFileForSave(view,vfs,newPath)) { setFlag(IO,false); return false; }  if(!vfs.save(view,this,newPath)) { setFlag(IO,false); return false; }   VFSManager.runInAWTThread(new Runnable() { public void run() { setFlag(IO,false); finishSaving(view,oldPath,newPath,rename, getBooleanProperty(BufferIORequest .ERROR_OCCURRED)); } });  return true;
return save(view,path,true);
	public boolean save(final View view, String path, final boolean rename)	{		if(isPerformingIO())		{			GUIUtilities.error(view,"buffer-multiple-io",null);			return false;		}		setBooleanProperty(BufferIORequest.ERROR_OCCURRED,false);		if(path == null && getFlag(NEW_FILE))			return saveAs(view,rename);		if(path == null && file != null)		{			long newModTime = file.lastModified();			if(newModTime != modTime				&& jEdit.getBooleanProperty("view.checkModStatus"))			{				Object[] args = { this.path };				int result = GUIUtilities.confirm(view,					"filechanged-save",args,					JOptionPane.YES_NO_OPTION,					JOptionPane.WARNING_MESSAGE);				if(result != JOptionPane.YES_OPTION)					return false;			}		}		setFlag(IO,true);		EditBus.send(new BufferUpdate(this,view,BufferUpdate.SAVING));		final String oldPath = this.path;		final String newPath = (path == null ? this.path : path);		VFS vfs = VFSManager.getVFSForPath(newPath);		if(!checkFileForSave(view,vfs,newPath))		{			setFlag(IO,false);			return false;		}		if(!vfs.save(view,this,newPath))		{			setFlag(IO,false);			return false;		}		// Once save is complete, do a few other things		VFSManager.runInAWTThread(new Runnable()		{			public void run()			{				setFlag(IO,false);				finishSaving(view,oldPath,newPath,rename,					getBooleanProperty(BufferIORequest					.ERROR_OCCURRED));			}		});		return true;	} //}}}