[CMAKE]
[reactos.git] / base / applications / regedit / listview.c
index c6fcd02..fcf9f52 100644 (file)
@@ -455,7 +455,7 @@ BOOL ListWndNotifyProc(HWND hWnd, WPARAM wParam, LPARAM lParam, BOOL *Result)
                         LONG lResult;
 
                         keyPath = GetItemPath(g_pChildWnd->hTreeWnd, 0, &hKeyRoot);
-                        lResult = RegRenameValue(hKeyRoot, keyPath, Info->item.pszText, lineinfo->name);
+                        lResult = RenameValue(hKeyRoot, keyPath, Info->item.pszText, lineinfo->name);
                         lineinfo->name = realloc(lineinfo->name, (_tcslen(Info->item.pszText)+1)*sizeof(TCHAR));
                         if (lineinfo->name != NULL)
                             _tcscpy(lineinfo->name, Info->item.pszText);
@@ -556,18 +556,12 @@ BOOL RefreshListView(HWND hwndLV, HKEY hKey, LPCTSTR keyPath)
         /*                } */
         /*                dwValSize = max_val_size; */
         while (RegEnumValue(hNewKey, dwIndex, ValName, &dwValNameLen, NULL, &dwValType, ValBuf, &dwValSize) == ERROR_SUCCESS) {
-            /* Remove unwanted path from key name */
-            TCHAR *pLastBl = _tcsrchr(ValName, TEXT('\\'));
-            if (pLastBl != NULL)
-                ++pLastBl;
-            else
-                pLastBl = ValName;
             /* Add a terminating 0 character. Usually this is only necessary for strings. */
             ValBuf[dwValSize] = 0;
 #ifdef UNICODE
             ValBuf[dwValSize + 1] = 0;
 #endif
-            AddEntryToList(hwndLV, pLastBl, dwValType, ValBuf, dwValSize, -1, TRUE);
+            AddEntryToList(hwndLV, ValName, dwValType, ValBuf, dwValSize, -1, TRUE);
             dwValNameLen = max_val_name_len;
             dwValSize = max_val_size;
             dwValType = 0L;