From 9ab7b2da91f5179846dc95d4ed69a1d167ba2e63 Mon Sep 17 00:00:00 2001 From: natureh Date: Thu, 14 Jul 2011 18:41:42 +0200 Subject: [PATCH] Cleaning useless code in windirmonitor.cc --- rtgui/windirmonitor.cc | 27 ++------------------------- 1 file changed, 2 insertions(+), 25 deletions(-) diff --git a/rtgui/windirmonitor.cc b/rtgui/windirmonitor.cc index 2274e1671..b1da29732 100644 --- a/rtgui/windirmonitor.cc +++ b/rtgui/windirmonitor.cc @@ -33,7 +33,6 @@ static void CALLBACK current_directory_monitor_callback (DWORD error, DWORD nByt // Analysis of the modifications do { Glib::ustring fname = ""; - Glib::ustring action = ""; int strLen = 0; // Get a pointer to the first change record... @@ -44,31 +43,9 @@ static void CALLBACK current_directory_monitor_callback (DWORD error, DWORD nByt fnameC[strLen] = 0; fname = fnameC; - // See http://msdn.microsoft.com/en-us/library/aa364391(v=vs.85).aspx for available options + // See http://msdn.microsoft.com/en-us/library/aa364391(v=vs.85).aspx for available event type if necessary if (options.has_retained_extention(fname)) - { - switch (pInfo->Action) - { - case (FILE_ACTION_ADDED): - action = "FILE_ACTION_ADDED"; - break; - case (FILE_ACTION_REMOVED): - action = "FILE_ACTION_REMOVED"; - break; - case (FILE_ACTION_MODIFIED): - action = "FILE_ACTION_MODIFIED"; - break; - case (FILE_ACTION_RENAMED_OLD_NAME): - action = "FILE_ACTION_RENAMED_OLD_NAME"; - break; - case (FILE_ACTION_RENAMED_NEW_NAME): - action = "FILE_ACTION_RENAMED_NEW_NAME"; - break; - default: - break; - } - notify = true; - } + notify = true; // More than one change may happen at the same time. Load the next change and continue... dwOffset += pInfo->NextEntryOffset;