[NEW_BEHAVIOUR] (Author : Christian Wegner) Focus (switch to) the dirty document while asking to save unsaved document when user close Notepad++.

git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@611 f5eea248-9336-0410-98b8-ebc06183d4e3
This commit is contained in:
Don Ho 2010-02-11 23:53:06 +00:00
parent 0d2efe29ea
commit 6ae357c289

View File

@ -474,6 +474,9 @@ bool Notepad_plus::fileCloseAll()
} }
else if (buf->isDirty()) else if (buf->isDirty())
{ {
_mainDocTab.activateBuffer(id);
_mainEditView.activateBuffer(id);
int res = doSaveOrNot(buf->getFullPathName()); int res = doSaveOrNot(buf->getFullPathName());
if (res == IDYES) if (res == IDYES)
{ {
@ -496,6 +499,9 @@ bool Notepad_plus::fileCloseAll()
} }
else if (buf->isDirty()) else if (buf->isDirty())
{ {
_subDocTab.activateBuffer(id);
_subEditView.activateBuffer(id);
int res = doSaveOrNot(buf->getFullPathName()); int res = doSaveOrNot(buf->getFullPathName());
if (res == IDYES) if (res == IDYES)
{ {
@ -546,6 +552,9 @@ bool Notepad_plus::fileCloseAllButCurrent()
} }
else if (buf->isDirty()) else if (buf->isDirty())
{ {
_mainDocTab.activateBuffer(id);
_mainEditView.activateBuffer(id);
int res = doSaveOrNot(buf->getFullPathName()); int res = doSaveOrNot(buf->getFullPathName());
if (res == IDYES) if (res == IDYES)
{ {
@ -570,6 +579,9 @@ bool Notepad_plus::fileCloseAllButCurrent()
} }
else if (buf->isDirty()) else if (buf->isDirty())
{ {
_subDocTab.activateBuffer(id);
_subEditView.activateBuffer(id);
int res = doSaveOrNot(buf->getFullPathName()); int res = doSaveOrNot(buf->getFullPathName());
if (res == IDYES) if (res == IDYES)
{ {