https://git.reactos.org/?p=reactos.git;a=commitdiff;h=7550e9efbf6786319480a…
commit 7550e9efbf6786319480a7893514da5cd9b931ef
Author: Eric Kohl <eric.kohl(a)reactos.org>
AuthorDate: Sun Aug 4 11:18:42 2019 +0200
Commit: Eric Kohl <eric.kohl(a)reactos.org>
CommitDate: Sun Aug 4 11:20:04 2019 +0200
[DEVMGR] Add the code to uninstall a device from the property page
---
dll/win32/devmgr/lang/bg-BG.rc | 11 +++
dll/win32/devmgr/lang/cs-CZ.rc | 11 +++
dll/win32/devmgr/lang/de-DE.rc | 12 +++-
dll/win32/devmgr/lang/el-GR.rc | 11 +++
dll/win32/devmgr/lang/en-US.rc | 12 ++++
dll/win32/devmgr/lang/es-ES.rc | 11 +++
dll/win32/devmgr/lang/et-EE.rc | 12 ++++
dll/win32/devmgr/lang/fr-FR.rc | 11 +++
dll/win32/devmgr/lang/he-IL.rc | 11 +++
dll/win32/devmgr/lang/hu-HU.rc | 11 +++
dll/win32/devmgr/lang/id-ID.rc | 11 +++
dll/win32/devmgr/lang/it-IT.rc | 12 +++-
dll/win32/devmgr/lang/ja-JP.rc | 12 ++++
dll/win32/devmgr/lang/no-NO.rc | 12 +++-
dll/win32/devmgr/lang/pl-PL.rc | 12 +++-
dll/win32/devmgr/lang/pt-BR.rc | 12 +++-
dll/win32/devmgr/lang/pt-PT.rc | 12 +++-
dll/win32/devmgr/lang/ro-RO.rc | 12 +++-
dll/win32/devmgr/lang/ru-RU.rc | 11 +++
dll/win32/devmgr/lang/sk-SK.rc | 11 +++
dll/win32/devmgr/lang/sq-AL.rc | 11 +++
dll/win32/devmgr/lang/tr-TR.rc | 11 +++
dll/win32/devmgr/lang/uk-UA.rc | 11 +++
dll/win32/devmgr/lang/zh-CN.rc | 12 ++++
dll/win32/devmgr/lang/zh-TW.rc | 12 ++++
dll/win32/devmgr/properties/advprop.cpp | 117 +++++++++++++++++++++++++++++++-
dll/win32/devmgr/resource.h | 1 +
27 files changed, 396 insertions(+), 9 deletions(-)
diff --git a/dll/win32/devmgr/lang/bg-BG.rc b/dll/win32/devmgr/lang/bg-BG.rc
index 47ca6224d5d..b85967b01d7 100644
--- a/dll/win32/devmgr/lang/bg-BG.rc
+++ b/dll/win32/devmgr/lang/bg-BG.rc
@@ -241,6 +241,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/cs-CZ.rc b/dll/win32/devmgr/lang/cs-CZ.rc
index e5f8a3903a0..0cc466fd7ff 100644
--- a/dll/win32/devmgr/lang/cs-CZ.rc
+++ b/dll/win32/devmgr/lang/cs-CZ.rc
@@ -245,6 +245,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/de-DE.rc b/dll/win32/devmgr/lang/de-DE.rc
index 529044e83a5..115a3df9a8b 100644
--- a/dll/win32/devmgr/lang/de-DE.rc
+++ b/dll/win32/devmgr/lang/de-DE.rc
@@ -242,7 +242,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
-
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Entfernen des Geräts bestätigen"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warnung: Sie sind dabei, das Gerät aus der Systemkonfiguration zu
deinstalleren.", -1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Abbrechen", IDCANCEL, 166, 100, 50, 14
+END
/*
This code relates to the device manager GUI
diff --git a/dll/win32/devmgr/lang/el-GR.rc b/dll/win32/devmgr/lang/el-GR.rc
index 8aabbd38839..fbdb1cea4d9 100644
--- a/dll/win32/devmgr/lang/el-GR.rc
+++ b/dll/win32/devmgr/lang/el-GR.rc
@@ -242,6 +242,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/en-US.rc b/dll/win32/devmgr/lang/en-US.rc
index faaadd6af82..f239176dbf7 100644
--- a/dll/win32/devmgr/lang/en-US.rc
+++ b/dll/win32/devmgr/lang/en-US.rc
@@ -240,6 +240,18 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
+
/*
This code relates to the device manager GUI
diff --git a/dll/win32/devmgr/lang/es-ES.rc b/dll/win32/devmgr/lang/es-ES.rc
index 1a011c8ba7c..9a7d536b91f 100644
--- a/dll/win32/devmgr/lang/es-ES.rc
+++ b/dll/win32/devmgr/lang/es-ES.rc
@@ -249,6 +249,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/et-EE.rc b/dll/win32/devmgr/lang/et-EE.rc
index 498e86a6611..ef09d0d5320 100644
--- a/dll/win32/devmgr/lang/et-EE.rc
+++ b/dll/win32/devmgr/lang/et-EE.rc
@@ -247,6 +247,18 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
+
/*
This code relates to the device manager GUI
diff --git a/dll/win32/devmgr/lang/fr-FR.rc b/dll/win32/devmgr/lang/fr-FR.rc
index 79c33bba606..25424994447 100644
--- a/dll/win32/devmgr/lang/fr-FR.rc
+++ b/dll/win32/devmgr/lang/fr-FR.rc
@@ -241,6 +241,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/he-IL.rc b/dll/win32/devmgr/lang/he-IL.rc
index c8d0401390b..ac762438d4d 100644
--- a/dll/win32/devmgr/lang/he-IL.rc
+++ b/dll/win32/devmgr/lang/he-IL.rc
@@ -242,6 +242,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/hu-HU.rc b/dll/win32/devmgr/lang/hu-HU.rc
index 3e8f7f8443b..cda88fb50ac 100644
--- a/dll/win32/devmgr/lang/hu-HU.rc
+++ b/dll/win32/devmgr/lang/hu-HU.rc
@@ -241,6 +241,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/id-ID.rc b/dll/win32/devmgr/lang/id-ID.rc
index a7d33717db7..1a4426ce1c3 100644
--- a/dll/win32/devmgr/lang/id-ID.rc
+++ b/dll/win32/devmgr/lang/id-ID.rc
@@ -242,6 +242,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/it-IT.rc b/dll/win32/devmgr/lang/it-IT.rc
index 2920ecab544..65efa6c68b6 100644
--- a/dll/win32/devmgr/lang/it-IT.rc
+++ b/dll/win32/devmgr/lang/it-IT.rc
@@ -242,7 +242,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
-
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/ja-JP.rc b/dll/win32/devmgr/lang/ja-JP.rc
index 3ddfe6f5d50..636bde2dd78 100644
--- a/dll/win32/devmgr/lang/ja-JP.rc
+++ b/dll/win32/devmgr/lang/ja-JP.rc
@@ -240,6 +240,18 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 9, "MS UI Gothic"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
+
/*
This code relates to the device manager GUI
diff --git a/dll/win32/devmgr/lang/no-NO.rc b/dll/win32/devmgr/lang/no-NO.rc
index f6ef8e0face..ec6f3c51665 100644
--- a/dll/win32/devmgr/lang/no-NO.rc
+++ b/dll/win32/devmgr/lang/no-NO.rc
@@ -242,7 +242,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
-
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/pl-PL.rc b/dll/win32/devmgr/lang/pl-PL.rc
index e85ee6b6371..9446c0f3310 100644
--- a/dll/win32/devmgr/lang/pl-PL.rc
+++ b/dll/win32/devmgr/lang/pl-PL.rc
@@ -250,7 +250,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
-
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/pt-BR.rc b/dll/win32/devmgr/lang/pt-BR.rc
index 204129cee1b..03cb0496efc 100644
--- a/dll/win32/devmgr/lang/pt-BR.rc
+++ b/dll/win32/devmgr/lang/pt-BR.rc
@@ -242,7 +242,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
-
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/pt-PT.rc b/dll/win32/devmgr/lang/pt-PT.rc
index 55986eb0356..b178c102192 100644
--- a/dll/win32/devmgr/lang/pt-PT.rc
+++ b/dll/win32/devmgr/lang/pt-PT.rc
@@ -242,7 +242,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
-
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/ro-RO.rc b/dll/win32/devmgr/lang/ro-RO.rc
index c5fd765ac33..6c8612b840f 100644
--- a/dll/win32/devmgr/lang/ro-RO.rc
+++ b/dll/win32/devmgr/lang/ro-RO.rc
@@ -245,7 +245,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
-
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/ru-RU.rc b/dll/win32/devmgr/lang/ru-RU.rc
index 0c0612f76d4..e3c3cf8e57b 100644
--- a/dll/win32/devmgr/lang/ru-RU.rc
+++ b/dll/win32/devmgr/lang/ru-RU.rc
@@ -242,6 +242,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/sk-SK.rc b/dll/win32/devmgr/lang/sk-SK.rc
index c41ee067209..97460c1c198 100644
--- a/dll/win32/devmgr/lang/sk-SK.rc
+++ b/dll/win32/devmgr/lang/sk-SK.rc
@@ -245,6 +245,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/sq-AL.rc b/dll/win32/devmgr/lang/sq-AL.rc
index 84cfc841ff1..86cf64be38d 100644
--- a/dll/win32/devmgr/lang/sq-AL.rc
+++ b/dll/win32/devmgr/lang/sq-AL.rc
@@ -244,6 +244,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/tr-TR.rc b/dll/win32/devmgr/lang/tr-TR.rc
index 9af97e2193c..a42c7f3328a 100644
--- a/dll/win32/devmgr/lang/tr-TR.rc
+++ b/dll/win32/devmgr/lang/tr-TR.rc
@@ -242,6 +242,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/uk-UA.rc b/dll/win32/devmgr/lang/uk-UA.rc
index eb8b5ba55b3..40e7b3549a7 100644
--- a/dll/win32/devmgr/lang/uk-UA.rc
+++ b/dll/win32/devmgr/lang/uk-UA.rc
@@ -248,6 +248,17 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 8, "MS Shell Dlg"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
/*
diff --git a/dll/win32/devmgr/lang/zh-CN.rc b/dll/win32/devmgr/lang/zh-CN.rc
index b4bd5e427b3..706d2a42f19 100644
--- a/dll/win32/devmgr/lang/zh-CN.rc
+++ b/dll/win32/devmgr/lang/zh-CN.rc
@@ -242,6 +242,18 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 9, "宋体"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
+
/*
This code relates to the device manager GUI
diff --git a/dll/win32/devmgr/lang/zh-TW.rc b/dll/win32/devmgr/lang/zh-TW.rc
index 31af160a308..7b61164998b 100644
--- a/dll/win32/devmgr/lang/zh-TW.rc
+++ b/dll/win32/devmgr/lang/zh-TW.rc
@@ -242,6 +242,18 @@ BEGIN
LTEXT "", IDC_DEVNAME, 37, 9, 174, 16, SS_NOPREFIX
END
+IDD_UNINSTALLDRIVER DIALOGEX 0, 0, 224, 121
+STYLE DS_SHELLFONT | DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUPWINDOW | WS_VISIBLE |
WS_DLGFRAME
+CAPTION "Confirm Device Removal"
+FONT 9, "新細明體"
+BEGIN
+ ICON "", IDC_DEVICON, 7, 7, 20, 20
+ LTEXT "", IDC_DEVNAME, 40, 9, 174, 16, SS_NOPREFIX
+ LTEXT "Warning: You are about to uninstall this device from your system.",
-1, 7, 37, 204, 50
+ DEFPUSHBUTTON "OK", IDOK, 110, 100, 50, 14
+ PUSHBUTTON "Cancel", IDCANCEL, 166, 100, 50, 14
+END
+
/*
This code relates to the device manager GUI
diff --git a/dll/win32/devmgr/properties/advprop.cpp
b/dll/win32/devmgr/properties/advprop.cpp
index 29a3579bcba..8df086fe4ba 100644
--- a/dll/win32/devmgr/properties/advprop.cpp
+++ b/dll/win32/devmgr/properties/advprop.cpp
@@ -429,6 +429,104 @@ DriverDetailsDlgProc(IN HWND hwndDlg,
}
+static
+INT_PTR
+CALLBACK
+UninstallDriverDlgProc(IN HWND hwndDlg,
+ IN UINT uMsg,
+ IN WPARAM wParam,
+ IN LPARAM lParam)
+{
+ PDEVADVPROP_INFO dap;
+ INT_PTR Ret = FALSE;
+
+ dap = (PDEVADVPROP_INFO)GetWindowLongPtr(hwndDlg, DWLP_USER);
+
+ if (dap != NULL || uMsg == WM_INITDIALOG)
+ {
+ switch (uMsg)
+ {
+ case WM_INITDIALOG:
+ dap = (PDEVADVPROP_INFO)lParam;
+ if (dap != NULL)
+ {
+ SetWindowLongPtr(hwndDlg, DWLP_USER, (DWORD_PTR)dap);
+
+ /* Set the device image */
+ SendDlgItemMessage(hwndDlg,
+ IDC_DEVICON,
+ STM_SETICON,
+ (WPARAM)dap->hDevIcon,
+ 0);
+
+ /* Set the device name */
+ SetDlgItemText(hwndDlg,
+ IDC_DEVNAME,
+ dap->szDevName);
+ }
+
+ Ret = TRUE;
+ break;
+
+ case WM_COMMAND:
+ switch (LOWORD(wParam))
+ {
+ case IDOK:
+ EndDialog(hwndDlg, IDOK);
+ break;
+
+ case IDCANCEL:
+ EndDialog(hwndDlg, IDCANCEL);
+ break;
+ }
+ break;
+
+ case WM_CLOSE:
+ EndDialog(hwndDlg, IDCANCEL);
+ break;
+ }
+ }
+
+ return Ret;
+}
+
+
+static
+VOID
+UninstallDriver(
+ _In_ HWND hwndDlg,
+ _In_ PDEVADVPROP_INFO dap)
+{
+ SP_REMOVEDEVICE_PARAMS RemoveDevParams;
+
+ if (DialogBoxParam(hDllInstance,
+ MAKEINTRESOURCE(IDD_UNINSTALLDRIVER),
+ hwndDlg,
+ UninstallDriverDlgProc,
+ (ULONG_PTR)dap) == IDCANCEL)
+ return;
+
+ RemoveDevParams.ClassInstallHeader.cbSize = sizeof(SP_CLASSINSTALL_HEADER);
+ RemoveDevParams.ClassInstallHeader.InstallFunction = DIF_REMOVE;
+ RemoveDevParams.Scope = DI_REMOVEDEVICE_GLOBAL;
+ RemoveDevParams.HwProfile = 0;
+
+ SetupDiSetClassInstallParamsW(dap->DeviceInfoSet,
+ &dap->DeviceInfoData,
+ &RemoveDevParams.ClassInstallHeader,
+ sizeof(SP_REMOVEDEVICE_PARAMS));
+
+ SetupDiCallClassInstaller(DIF_REMOVE,
+ dap->DeviceInfoSet,
+ &dap->DeviceInfoData);
+
+ SetupDiSetClassInstallParamsW(dap->DeviceInfoSet,
+ &dap->DeviceInfoData,
+ NULL,
+ 0);
+}
+
+
static
VOID
UpdateDriver(
@@ -500,6 +598,9 @@ UpdateDriverDlg(IN HWND hwndDlg,
{
HDEVINFO DeviceInfoSet;
PSP_DEVINFO_DATA DeviceInfoData;
+ DWORD dwStatus = 0;
+ DWORD dwProblem = 0;
+ CONFIGRET cr;
if (dap->CurrentDeviceInfoSet != INVALID_HANDLE_VALUE)
{
@@ -556,6 +657,19 @@ UpdateDriverDlg(IN HWND hwndDlg,
IDC_DRVVERSION,
dap->szTemp);
}
+
+ /* Disable the Uninstall button if the driver cannot be removed */
+ cr = CM_Get_DevNode_Status_Ex(&dwStatus,
+ &dwProblem,
+ dap->DeviceInfoData.DevInst,
+ 0,
+ dap->hMachine);
+ if (cr == CR_SUCCESS)
+ {
+ if ((dwStatus & DN_ROOT_ENUMERATED) != 0 &&
+ (dwStatus & DN_DISABLEABLE) == 0)
+ EnableWindow(GetDlgItem(hwndDlg, IDC_UNINSTALLDRIVER), FALSE);
+ }
}
@@ -596,7 +710,7 @@ AdvProcDriverDlgProc(IN HWND hwndDlg,
break;
case IDC_UNINSTALLDRIVER:
- // FIXME
+ UninstallDriver(hwndDlg, dap);
break;
}
break;
@@ -624,7 +738,6 @@ AdvProcDriverDlgProc(IN HWND hwndDlg,
dap);
}
EnableWindow(GetDlgItem(hwndDlg, IDC_ROLLBACKDRIVER), FALSE);
- EnableWindow(GetDlgItem(hwndDlg, IDC_UNINSTALLDRIVER), FALSE);
Ret = TRUE;
break;
}
diff --git a/dll/win32/devmgr/resource.h b/dll/win32/devmgr/resource.h
index bdb4c460718..f8054f38ccb 100644
--- a/dll/win32/devmgr/resource.h
+++ b/dll/win32/devmgr/resource.h
@@ -217,6 +217,7 @@
#define IDD_DRIVERDETAILS 0x404
#define IDD_DEVICEDETAILS 0x405
#define IDD_DEVICEPOWER 0x406
+#define IDD_UNINSTALLDRIVER 0x407
#define IDC_DEVICON 0x57B
#define IDC_DEVNAME 0x57C