VeraCrypt
aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Mount/Mount.c26
1 files changed, 17 insertions, 9 deletions
diff --git a/src/Mount/Mount.c b/src/Mount/Mount.c
index 265f651a..12ee7985 100644
--- a/src/Mount/Mount.c
+++ b/src/Mount/Mount.c
@@ -3297,7 +3297,7 @@ BOOL CALLBACK PreferencesDlgProc (HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM
3297 int menuItem = TrackPopupMenu (popup, TPM_RETURNCMD | TPM_LEFTBUTTON, rect.left + 2, rect.top + 2, 0, hwndDlg, NULL); 3297 int menuItem = TrackPopupMenu (popup, TPM_RETURNCMD | TPM_LEFTBUTTON, rect.left + 2, rect.top + 2, 0, hwndDlg, NULL);
3298 DestroyMenu (popup); 3298 DestroyMenu (popup);
3299 3299
3300 SendMessage (MainDlg, WM_COMMAND, menuItem, NULL); 3300 SendMessage (MainDlg, WM_COMMAND, menuItem, (LPARAM) hwndDlg);
3301 return 1; 3301 return 1;
3302 } 3302 }
3303 else 3303 else
@@ -7952,27 +7952,31 @@ BOOL CALLBACK MainDialogProc (HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPa
7952 7952
7953 if (lw == IDM_HOTKEY_SETTINGS) 7953 if (lw == IDM_HOTKEY_SETTINGS)
7954 { 7954 {
7955 HWND hwndParent = (lParam != 0)? (HWND) lParam : hwndDlg;
7955 DialogBoxParamW (hInst, 7956 DialogBoxParamW (hInst,
7956 MAKEINTRESOURCEW (IDD_HOTKEYS_DLG), hwndDlg, 7957 MAKEINTRESOURCEW (IDD_HOTKEYS_DLG), hwndParent,
7957 (DLGPROC) HotkeysDlgProc, (LPARAM) 0); 7958 (DLGPROC) HotkeysDlgProc, (LPARAM) 0);
7958 return 1; 7959 return 1;
7959 } 7960 }
7960 7961
7961 if (lw == IDM_PERFORMANCE_SETTINGS) 7962 if (lw == IDM_PERFORMANCE_SETTINGS)
7962 { 7963 {
7963 DialogBoxParamW (hInst, MAKEINTRESOURCEW (IDD_PERFORMANCE_SETTINGS), hwndDlg, (DLGPROC) PerformanceSettingsDlgProc, 0); 7964 HWND hwndParent = (lParam != 0)? (HWND) lParam : hwndDlg;
7965 DialogBoxParamW (hInst, MAKEINTRESOURCEW (IDD_PERFORMANCE_SETTINGS), hwndParent, (DLGPROC) PerformanceSettingsDlgProc, 0);
7964 return 1; 7966 return 1;
7965 } 7967 }
7966 7968
7967 if (lw == IDM_DEFAULT_KEYFILES) 7969 if (lw == IDM_DEFAULT_KEYFILES)
7968 { 7970 {
7969 KeyfileDefaultsDlg (hwndDlg); 7971 HWND hwndParent = (lParam != 0)? (HWND) lParam : hwndDlg;
7972 KeyfileDefaultsDlg (hwndParent);
7970 return 1; 7973 return 1;
7971 } 7974 }
7972 7975
7973 if (lw == IDM_DEFAULT_MOUNT_PARAMETERS) 7976 if (lw == IDM_DEFAULT_MOUNT_PARAMETERS)
7974 { 7977 {
7975 DialogBoxParamW (hInst, MAKEINTRESOURCEW (IDD_DEFAULT_MOUNT_PARAMETERS), hwndDlg, (DLGPROC) DefaultMountParametersDlgProc, 0); 7978 HWND hwndParent = (lParam != 0)? (HWND) lParam : hwndDlg;
7979 DialogBoxParamW (hInst, MAKEINTRESOURCEW (IDD_DEFAULT_MOUNT_PARAMETERS), hwndParent, (DLGPROC) DefaultMountParametersDlgProc, 0);
7976 return 1; 7980 return 1;
7977 } 7981 }
7978 7982
@@ -8088,19 +8092,22 @@ BOOL CALLBACK MainDialogProc (HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPa
8088 8092
8089 if (lw == IDM_TOKEN_PREFERENCES) 8093 if (lw == IDM_TOKEN_PREFERENCES)
8090 { 8094 {
8091 SecurityTokenPreferencesDialog (hwndDlg); 8095 HWND hwndParent = (lParam != 0)? (HWND) lParam : hwndDlg;
8096 SecurityTokenPreferencesDialog (hwndParent);
8092 return 1; 8097 return 1;
8093 } 8098 }
8094 8099
8095 if (lw == IDM_SYSENC_SETTINGS || lw == IDM_SYS_ENC_SETTINGS) 8100 if (lw == IDM_SYSENC_SETTINGS || lw == IDM_SYS_ENC_SETTINGS)
8096 { 8101 {
8097 DialogBoxParamW (hInst, MAKEINTRESOURCEW (bSystemIsGPT? IDD_EFI_SYSENC_SETTINGS : IDD_SYSENC_SETTINGS), hwndDlg, (DLGPROC) BootLoaderPreferencesDlgProc, 0); 8102 HWND hwndParent = (lParam != 0)? (HWND) lParam : hwndDlg;
8103 DialogBoxParamW (hInst, MAKEINTRESOURCEW (bSystemIsGPT? IDD_EFI_SYSENC_SETTINGS : IDD_SYSENC_SETTINGS), hwndParent, (DLGPROC) BootLoaderPreferencesDlgProc, 0);
8098 return 1; 8104 return 1;
8099 } 8105 }
8100 8106
8101 if (lw == IDM_SYS_FAVORITES_SETTINGS) 8107 if (lw == IDM_SYS_FAVORITES_SETTINGS)
8102 { 8108 {
8103 OrganizeFavoriteVolumes (hwndDlg, true); 8109 HWND hwndParent = (lParam != 0)? (HWND) lParam : hwndDlg;
8110 OrganizeFavoriteVolumes (hwndParent, true);
8104 return 1; 8111 return 1;
8105 } 8112 }
8106 8113
@@ -8176,7 +8183,8 @@ BOOL CALLBACK MainDialogProc (HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPa
8176 if (lw == IDM_LANGUAGE) 8183 if (lw == IDM_LANGUAGE)
8177 { 8184 {
8178 BOOL p; 8185 BOOL p;
8179 if (DialogBoxParamW (hInst, MAKEINTRESOURCEW (IDD_LANGUAGE), hwndDlg, 8186 HWND wndParent = (lParam != 0)? (HWND) lParam : hwndDlg;
8187 if (DialogBoxParamW (hInst, MAKEINTRESOURCEW (IDD_LANGUAGE), wndParent,
8180 (DLGPROC) LanguageDlgProc, (LPARAM) 0) == IDOK) 8188 (DLGPROC) LanguageDlgProc, (LPARAM) 0) == IDOK)
8181 { 8189 {
8182 LoadLanguageFile (); 8190 LoadLanguageFile ();