Add NPPN_GLOBALMODIFIED to notify plugins that the current document is just modified by Replace All action.
//scnNotification->nmhdr.code = NPPN_GLOBALMODIFIED;
//scnNotification->nmhdr.hwndFrom = BufferID;
//scnNotification->nmhdr.idFrom = 0; // preserved for the future use, must be zero
For solving the performance issue (from v8.6.4), Notepad++ doesn't trigger SCN_MODIFIED & other Scitilla notifications during Replace All action anymore.
Plugin devs should monitor NPPN_GLOBALMODIFIED instead. This notification is implemented in Notepad++ v8.6.5.
Ref: https://github.com/notepad-plus-plus/notepad-plus-plus/pull/14685#issuecomment-1955229867Fix#14767, close#14768
//scnNotification->nmhdr.idFrom = BufferID; //where pluginMessage is pointer of type wchar_t
#define NPPN_GLOBALMODIFIED (NPPN_FIRST + 30) // To notify plugins that the current document is just modified by Replace All action. For solving the performance issue (from v8.6.4),
// Notepad++ doesn't trigger SCN_MODIFIED & other Scitilla notifications during Replace All action anymore.
// Plugin devs should monitor NPPN_GLOBALMODIFIED instead. This notification is implemented in Notepad++ v8.6.5.
if(op==ProcessReplaceAll&&nbProcessed>0)// All the notification of modification (SCN_MODIFIED) were removed during the operations, so we set modified status true here