diff --git a/PowerEditor/src/Notepad_plus.cpp b/PowerEditor/src/Notepad_plus.cpp index e7c7e05cc..65320ed62 100644 --- a/PowerEditor/src/Notepad_plus.cpp +++ b/PowerEditor/src/Notepad_plus.cpp @@ -3949,7 +3949,12 @@ void Notepad_plus::drawTabbarColoursFromStylerArray() TabBarPlus::setColour(stInact->_bgColor, TabBarPlus::inactiveBg); } -void Notepad_plus::notifyBufferChanged(Buffer * buffer, int mask) { +void Notepad_plus::notifyBufferChanged(Buffer * buffer, int mask) +{ + // To avoid to crash while MS-DOS style is set as default language, + // Checking the validity of current instance is necessary. + if (!this) return; + NppParameters *pNppParam = NppParameters::getInstance(); const NppGUI & nppGUI = pNppParam->getNppGUI(); diff --git a/PowerEditor/src/Notepad_plus.rc b/PowerEditor/src/Notepad_plus.rc index d1f2fd4f7..4067df18c 100644 --- a/PowerEditor/src/Notepad_plus.rc +++ b/PowerEditor/src/Notepad_plus.rc @@ -185,7 +185,7 @@ BEGIN MENUITEM "Sav&e All", IDM_FILE_SAVEALL MENUITEM "Rename...", IDM_FILE_RENAME MENUITEM "&Close", IDM_FILE_CLOSE - MENUITEM "Cl&ose All", IDM_FILE_CLOSEALL + MENUITEM "Clos&e All", IDM_FILE_CLOSEALL MENUITEM "Close All but Active Document", IDM_FILE_CLOSEALL_BUT_CURRENT MENUITEM "Delete from Disk", IDM_FILE_DELETE MENUITEM SEPARATOR diff --git a/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp b/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp index afd2a1c9b..06fbd6393 100644 --- a/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp +++ b/PowerEditor/src/ScitillaComponent/ScintillaEditView.cpp @@ -1501,7 +1501,8 @@ void ScintillaEditView::activateBuffer(BufferID buffer) return; //all done } -void ScintillaEditView::bufferUpdated(Buffer * buffer, int mask) { +void ScintillaEditView::bufferUpdated(Buffer * buffer, int mask) +{ //actually only care about language and lexing etc if (buffer == _currentBuffer) {