[ENHANCEMENT] prevent switched-in document from parsing for function list and document map while these 2 panels are hidden.

git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@1159 f5eea248-9336-0410-98b8-ebc06183d4e3
This commit is contained in:
Don Ho 2013-12-19 11:22:33 +00:00
parent fa5e33a50e
commit 0e36da7399
3 changed files with 7 additions and 2 deletions

View File

@ -4639,13 +4639,13 @@ void Notepad_plus::notifyBufferActivated(BufferID bufid, int view)
_pFileSwitcherPanel->activateItem((int)bufid, currentView());
}
if (_pDocMap)
if (_pDocMap && (!_pDocMap->isClosed()) && _pDocMap->isVisible())
{
_pDocMap->reloadMap();
_pDocMap->setSyntaxLiliting();
}
if (_pFuncList)
if (_pFuncList && (!_pFuncList->isClosed()) && _pFuncList->isVisible())
{
_pFuncList->reload();
}

View File

@ -319,6 +319,7 @@ BOOL CALLBACK DocumentMap::run_dlgProc(UINT message, WPARAM wParam, LPARAM lPara
{
_vzDlg.display();
reloadMap();
setSyntaxLiliting();
return TRUE;
}

View File

@ -416,6 +416,10 @@ void FunctionListPanel::notified(LPNMHDR notification)
break;
}
}
else if (notification->code == DMN_SWITCHIN)
{
reload();
}
else if (notification->code == DMN_CLOSE)
{
::SendMessage(_hParent, WM_COMMAND, IDM_VIEW_FUNC_LIST, 0);