Hugh McMaster : regedit: Allow editing of all hex data types.

Alexandre Julliard julliard at winehq.org
Tue Aug 8 07:36:37 CDT 2017


Module: wine
Branch: master
Commit: efb8d0b497abe771d4da264c6ff6b504a3ad8500
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=efb8d0b497abe771d4da264c6ff6b504a3ad8500

Author: Hugh McMaster <hugh.mcmaster at outlook.com>
Date:   Mon Aug  7 12:29:01 2017 +0000

regedit: Allow editing of all hex data types.

Signed-off-by: Hugh McMaster <hugh.mcmaster at outlook.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 programs/regedit/edit.c | 21 +++++++++++----------
 1 file changed, 11 insertions(+), 10 deletions(-)

diff --git a/programs/regedit/edit.c b/programs/regedit/edit.c
index c72f39d..3694627 100644
--- a/programs/regedit/edit.c
+++ b/programs/regedit/edit.c
@@ -303,14 +303,6 @@ BOOL ModifyValue(HWND hwnd, HKEY hKeyRoot, LPCWSTR keyPath, LPCWSTR valueName)
 	    }
 	    heap_free(valueA);
 	}
-    } else if ( type == REG_BINARY ) {
-        struct edit_params params;
-        params.hKey = hKey;
-        params.lpszValueName = valueName;
-        params.pData = stringValueData;
-        params.cbData = len;
-        result = DialogBoxParamW(NULL, MAKEINTRESOURCEW(IDD_EDIT_BINARY), hwnd,
-            bin_modify_dlgproc, (LPARAM)&params);
     } else if ( type == REG_MULTI_SZ ) {
         WCHAR char1 = '\r', char2 = '\n';
         WCHAR *tmpValueData = NULL;
@@ -362,8 +354,17 @@ BOOL ModifyValue(HWND hwnd, HKEY hKeyRoot, LPCWSTR keyPath, LPCWSTR valueName)
             if (lRet == ERROR_SUCCESS) result = TRUE;
             else error_code_messagebox(hwnd, IDS_SET_VALUE_FAILED);
         }
-    } else {
-        error_code_messagebox(hwnd, IDS_UNSUPPORTED_TYPE, type);
+    }
+    else /* hex data types */
+    {
+        struct edit_params params;
+
+        params.hKey = hKey;
+        params.lpszValueName = valueName;
+        params.pData = stringValueData;
+        params.cbData = len;
+        result = DialogBoxParamW(NULL, MAKEINTRESOURCEW(IDD_EDIT_BINARY), hwnd,
+                                 bin_modify_dlgproc, (LPARAM)&params);
     }
 
     /* Update the listview item with the new data string */




More information about the wine-cvs mailing list