/** Closes all components. * @return <code>true</code> if every component is successfully closed or <code>false</code> if the user cancelled the request * @see org.openide.cookies.CloseCookie#close */ public boolean close () { return close (true); }
/** Closes all components. * @return <code>true</code> if every component is successfully closed or <code>false</code> if the user cancelled the request * @see org.openide.cookies.CloseCookie#close */ public boolean close () { return close (true); }
/** Closes all opened editors (if the user agrees) and * flushes content of the document to the file. * * @param ask ask whether to save the document or not? * @return <code>false</code> if the operation is cancelled */ protected boolean close (boolean ask) { if (!super.close (ask)) { // if not all editors has been closed return false; } notifyClosed (); return true; }
/** Closes all opened editors (if the user agrees) and * flushes content of the document to the file. * * @param ask ask whether to save the document or not? * @return <code>false</code> if the operation is cancelled */ protected boolean close (boolean ask) { if (!super.close (ask)) { // if not all editors has been closed return false; } notifyClosed (); return true; }
/** Closes the support in AWT thread. */ public void run () { // loosing validity CloneableOpenSupport os = support (); if (os != null) { // mark the object as not being modified, so nobody // will ask for save env.unmarkModified (); os.close (false); } }
/** Closes the support in AWT thread. */ public void run () { // loosing validity CloneableOpenSupport os = support (); if (os != null) { // mark the object as not being modified, so nobody // will ask for save env.unmarkModified (); os.close (false); } }
/** Closes all opened editors (if the user agrees) and * flushes content of the document to the file. * * @param ask ask whether to save the document or not? * @return <code>false</code> if the operation is cancelled */ @Override protected boolean close(boolean ask) { CloneableEditorSupport redirect = CloneableEditorSupportRedirector.findRedirect(this); if (redirect != null) { return redirect.close(ask); } if (!super.close(ask)) { // if not all editors has been closed return false; } notifyClosed(); return true; }