Skip to content

Commit

Permalink
Code enhancement: remove obsolete code
Browse files Browse the repository at this point in the history
The removed code in this commit were added for working around Microsoft ReadDirectoryChanges notification issue:
notepad-plus-plus@1a97d3c
Apparently the issue has been fixed. The following issue has been tested with this commit, no issue found:
notepad-plus-plus#5591 (comment)

This commit could remedy notepad-plus-plus#15819.
  • Loading branch information
donho committed Dec 19, 2024
1 parent de1a040 commit d34c39e
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions PowerEditor/src/NppBigSwitch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2176,17 +2176,6 @@ LRESULT Notepad_plus::process(HWND hwnd, UINT message, WPARAM wParam, LPARAM lPa

case NPPM_INTERNAL_CHECKDOCSTATUS:
{
// This is an workaround to deal with Microsoft issue in ReadDirectoryChanges notification
// If command prompt is used to write file continuously (e.g. ping -t 8.8.8.8 > ping.log)
// Then ReadDirectoryChanges does not detect the change.
// Fortunately, notification is sent if right click or double click happens on that file
// Let's leverage this as workaround to enhance npp file monitoring functionality.
// So calling "doesFileExist" is a workaround here.

Buffer* currBuf = getCurrentBuffer();
if (currBuf && currBuf->isMonitoringOn())
doesFileExist(currBuf->getFullPathName());

const NppGUI & nppgui = nppParam.getNppGUI();
if (nppgui._fileAutoDetection != cdDisabled)
{
Expand Down

0 comments on commit d34c39e

Please sign in to comment.