Author: mjansen
Date: Sun Jul 31 11:59:15 2016
New Revision: 72063
URL:
http://svn.reactos.org/svn/reactos?rev=72063&view=rev
Log:
[BROWSEUI] Correct the 'Is this legal' url as suggested by Ken Rochard. Also
rewrite the function to remove todo's, and make it localizable. CORE-11721 #resolve
#comment Thanks!
Modified:
trunk/reactos/dll/win32/browseui/lang/bg-BG.rc
trunk/reactos/dll/win32/browseui/lang/de-DE.rc
trunk/reactos/dll/win32/browseui/lang/en-US.rc
trunk/reactos/dll/win32/browseui/lang/es-ES.rc
trunk/reactos/dll/win32/browseui/lang/fr-FR.rc
trunk/reactos/dll/win32/browseui/lang/he-IL.rc
trunk/reactos/dll/win32/browseui/lang/it-IT.rc
trunk/reactos/dll/win32/browseui/lang/pl-PL.rc
trunk/reactos/dll/win32/browseui/lang/pt-BR.rc
trunk/reactos/dll/win32/browseui/lang/ro-RO.rc
trunk/reactos/dll/win32/browseui/lang/ru-RU.rc
trunk/reactos/dll/win32/browseui/lang/sq-AL.rc
trunk/reactos/dll/win32/browseui/lang/tr-TR.rc
trunk/reactos/dll/win32/browseui/lang/uk-UA.rc
trunk/reactos/dll/win32/browseui/lang/zh-CN.rc
trunk/reactos/dll/win32/browseui/lang/zh-TW.rc
trunk/reactos/dll/win32/browseui/resource.h
trunk/reactos/dll/win32/browseui/shellbrowser.cpp
Modified: trunk/reactos/dll/win32/browseui/lang/bg-BG.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/bg…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/bg-BG.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/bg-BG.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -273,3 +273,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Back|Forward|Up|Search|Folders|Move To|Copy
To|Delete|Undo|Views|Stop|Refresh|Home|Map Drive|Disconnect|Favorites|History|Full
Screen|Properties|Cut|Copy|Paste|Folder Options||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/de-DE.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/de…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/de-DE.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/de-DE.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -292,3 +292,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Zurück|Vorwärts|Ãbergeordneter
Ordner|Suchen|Ordner|Verschieben nach|Kopieren
nach|Löschen|Rückgängig|Ansicht|Stop|Aktualisieren|Startseite|Netzlaufwerk
verbinden|Netzlaufwerk
trennen|Favoriten|Verlauf|Vollbild|Eigenschaften|Ausschneiden|Kopieren|Einfügen|Ordneroptionen||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/en-US.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/en…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/en-US.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/en-US.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -291,3 +291,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Back|Forward|Up|Search|Folders|Move To|Copy
To|Delete|Undo|Views|Stop|Refresh|Home|Map Drive|Disconnect|Favorites|History|Full
Screen|Properties|Cut|Copy|Paste|Folder Options||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/es-ES.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/es…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/es-ES.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/es-ES.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -275,3 +275,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Atrás|Adelante|Subir|Búsqueda|Carpetas|Mover a|Copiar
a|Borrar|Deshacer|Vistas|Detener|Recargar|Inicio|Montar
disco|Desconectar|Favoritos|Historial|Pantalla
completa|Propiedades|Cortar|Copiar|Pegar|Opciones de carpeta||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/fr-FR.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/fr…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/fr-FR.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/fr-FR.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -291,3 +291,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Retour|Avancer|Dossier parent|Recherche|Dossiers|Aller
vers|Copier dans|Supprimer|Annuler|Affichage|Stop|Rafraîchir|Home|Map
Drive|Déconnecter|Favoris|Historique|Plein
écran|Propriétés|Couper|Copier|Coller|Options des dossiers||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Désolé"
+ IDS_SORRY_MESSAGE, "ReactOS ne peut pas atteindre '%s' (erreur
0x%lx).\nVeuillez vérifier qu'un navigateur web est installé."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/he-IL.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/he…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/he-IL.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/he-IL.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -275,3 +275,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Back|Forward|Up|Search|Folders|Move To|Copy
To|Delete|Undo|Views|Stop|Refresh|Home|Map Drive|Disconnect|Favorites|History|Full
Screen|Properties|Cut|Copy|Paste|Folder Options||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/it-IT.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/it…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/it-IT.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/it-IT.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -273,3 +273,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Indietro|Avanti|Livello superiore|Cerca|Cartelle|Sposta
in|Copia in|Elimina|Annulla|Visualizza|Ferma|Aggiorna|Pagina iniziale|Mappa
disco|Disconnette|Preferiti|Cronologia|Schermo
intero|Proprietà |Taglia|Copia|Incolla|Opzioni cartella||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/pl-PL.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/pl…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/pl-PL.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/pl-PL.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -281,3 +281,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Wstecz|Dalej|W górÄ|Wyszukaj|Foldery|PrzemieÅÄ
do|Kopiuj do|UsuÅ|Cofnij|Widoki|Stop|OdÅwież|Strona gÅówna|Mapa dysków|RozÅÄ
cz|Ulubione|Historia|PeÅny ekran|WÅaÅciwoÅci|Wytnij|Kopiuj|Wklej|Opcje
folderów||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/pt-BR.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/pt…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/pt-BR.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/pt-BR.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -275,3 +275,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Voltar|Avançar|Acima|Pesquisar|Pastas|Mover para|Copiar
para|Excluir|Desfazer|Modos de exibição|Parar|Atualizar|Página inicial|Mapear
unidade|Desconectar|Favoritos|Histórico|Tela
inteira|Propriedades|Recortar|Copiar|Colar|Opções de pasta||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/ro-RO.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/ro…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/ro-RO.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/ro-RO.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -275,3 +275,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Ãnapoi|Ãnainte|Sus|CÄutare|Dosare|Mutare în|Copiere
în|Ètergere|Desfacere|AfiÈÄri|Oprire|ÃmprospÄtare|AcasÄ|Conectare unitate de
stocare|Deconectare|Favorite|Istoric|Pe tot
ecranul|ProprietÄÈi|Decupare|Copiere|Lipire|OpÈiuni de dosar||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/ru-RU.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/ru…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/ru-RU.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/ru-RU.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -275,3 +275,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Ðазад|ÐпеÑед|ÐвеÑÑ
|ÐоиÑк|Ðапки|ÐеÑемеÑÑиÑÑ Ð²|ÐопиÑоваÑÑ
в|УдалиÑÑ|ÐÑмениÑÑ|Ðид|ÐÑÑановиÑÑ|ÐбновиÑÑ|Ðомой|ÐодклÑÑиÑÑ
диÑк|ÐÑклÑÑиÑÑ|ÐзбÑанное|ÐÑÑнал|Ðо веÑÑ
ÑкÑан|СвойÑÑва|ÐÑÑезаÑÑ|ÐопиÑоваÑÑ|ÐÑÑавиÑÑ|СвойÑÑва
папки||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/sq-AL.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/sq…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/sq-AL.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/sq-AL.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -292,3 +292,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Back|Forward|Up|Search|Folders|Move To|Copy
To|Delete|Undo|Views|Stop|Refresh|Home|Map Drive|Disconnect|Favorites|History|Full
Screen|Properties|Cut|Copy|Paste|Folder Options||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/tr-TR.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/tr…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/tr-TR.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/tr-TR.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -273,3 +273,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Back|Forward|Up|Search|Folders|Move To|Copy
To|Delete|Undo|Views|Stop|Refresh|Home|Map Drive|Disconnect|Favorites|History|Full
Screen|Properties|Cut|Copy|Paste|Folder Options||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/uk-UA.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/uk…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/uk-UA.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/uk-UA.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -275,3 +275,10 @@
BEGIN
IDS_STANDARD_TOOLBAR, "|Back|Forward|Up|Search|Folders|Move To|Copy
To|Delete|Undo|Views|Stop|Refresh|Home|Map Drive|Disconnect|Favorites|History|Full
Screen|Properties|Cut|Copy|Paste|Folder Options||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/zh-CN.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/zh…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/zh-CN.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/zh-CN.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -293,3 +293,10 @@
BEGIN
IDS_STANDARD_TOOLBAR,
"|è¿å|åè¿|åä¸|æç´¢|æ件夹|移å¨å°|å¤å¶å°|å é¤|æ¤æ¶|è§å¾|åæ¢|å·æ°|é¦é¡µ|æ å°ç£ç|æå¼è¿æ¥|æ¶è夹|åå²|å
¨å±å¹|å±æ§|åªä¸|å¤å¶|è´´ä¸|æ件夹é项||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/lang/zh-TW.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/lang/zh…
==============================================================================
--- trunk/reactos/dll/win32/browseui/lang/zh-TW.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/lang/zh-TW.rc [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -293,3 +293,10 @@
BEGIN
IDS_STANDARD_TOOLBAR,
"|è¿å|åé²|åä¸|æç´¢|è³æ夾|移åå°|è¤è£½å°|åªé¤|æ¤æ¶|檢è¦|åæ¢|éæ°æ´ç|é¦é |å°æ ç£ç¢|æ·éé£ç·|æ¶è夾|æ·å²|å
¨è¢å¹|屬æ§|åªä¸|è¤è£½|è²¼ä¸|è³æ夾é¸é
||"
END
+
+STRINGTABLE
+BEGIN
+ IDS_LEGAL_URL, "https://www.reactos.org/joining/faqs"
+ IDS_SORRY_CAPTION, "Sorry"
+ IDS_SORRY_MESSAGE, "ReactOS could not browse to '%s' (error
0x%lx).\nPlease make sure there is a web browser installed."
+END
Modified: trunk/reactos/dll/win32/browseui/resource.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/resourc…
==============================================================================
--- trunk/reactos/dll/win32/browseui/resource.h [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/resource.h [iso-8859-1] Sun Jul 31 11:59:15 2016
@@ -93,6 +93,7 @@
#define IDR_AUTOCOMPLETE 141
#define IDR_ACLISTISF 142
+#define IDS_LEGAL_URL 12299
#define IDS_SMALLICONS 12301
#define IDS_LARGEICONS 12302
#define IDS_SHOWTEXTLABELS 12303
@@ -105,6 +106,8 @@
#define IDS_ADDRESSBANDLABEL 12902
#define IDS_FOLDERSLABEL 12919
#define IDS_HISTORYTEXT 13169
+#define IDS_SORRY_CAPTION 14001
+#define IDS_SORRY_MESSAGE 14002
#define IDS_UP 58434
#define IDS_BACK 58689
#define IDS_FORWARD 58690
Modified: trunk/reactos/dll/win32/browseui/shellbrowser.cpp
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/browseui/shellbr…
==============================================================================
--- trunk/reactos/dll/win32/browseui/shellbrowser.cpp [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/browseui/shellbrowser.cpp [iso-8859-1] Sun Jul 31 11:59:15
2016
@@ -3592,26 +3592,34 @@
LRESULT CShellBrowser::OnIsThisLegal(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL
&bHandled)
{
- /* TODO: Implement properly */
-
- LPCWSTR strSite =
L"https://www.reactos.org/user-faq"-faq";
-
- /* TODO: Make localizable */
- LPCWSTR strCaption = L"Sorry";
- LPCWSTR strMessage = L"ReactOS could not browse to '%s' (error %d).
Please make sure there is a web browser installed.";
- WCHAR tmpMessage[512];
-
- /* TODO: Read from the registry */
- LPCWSTR strVerb = NULL; /* default */
- LPCWSTR strPath = strSite;
- LPCWSTR strParams = NULL;
-
- /* The return value is defined as HINSTANCE for backwards compatibility only, the
cast is needed */
- int result = (int) ShellExecuteW(m_hWnd, strVerb, strPath, strParams, NULL,
SW_SHOWNORMAL);
- if (result <= 32)
- {
- StringCchPrintfW(tmpMessage, 512, strMessage, strSite, result);
- MessageBoxExW(m_hWnd, tmpMessage, strCaption, MB_OK, 0);
+ WCHAR wszSite[256];
+ HINSTANCE hResourceInstance = _AtlBaseModule.GetResourceInstance();
+
+ if (!LoadStringW(hResourceInstance, IDS_LEGAL_URL, wszSite, _countof(wszSite)))
+ StringCchCopyW(wszSite, _countof(wszSite),
L"https://www.reactos.org/joining/faqs")aqs");
+
+ SHELLEXECUTEINFOW execInfo = { sizeof(execInfo), 0 };
+ execInfo.lpVerb = L"open";
+ execInfo.lpFile = wszSite;
+ execInfo.hwnd = m_hWnd;
+ execInfo.nShow = SW_SHOWNORMAL;
+
+ if (!ShellExecuteExW(&execInfo))
+ {
+ WCHAR wszCaption[256];
+ WCHAR wszMessage[512];
+
+ DWORD error = GetLastError();
+
+ if (!LoadStringW(hResourceInstance, IDS_SORRY_MESSAGE, wszCaption,
_countof(wszCaption)))
+ StringCchCopyW(wszCaption, _countof(wszCaption), L"ReactOS could not
browse to '%s' (error 0x%lx). Please make sure there is a web browser
installed.");
+
+ StringCchPrintfW(wszMessage, _countof(wszMessage), wszCaption, wszSite, error);
+
+ if (!LoadStringW(hResourceInstance, IDS_SORRY_CAPTION, wszCaption,
_countof(wszCaption)))
+ StringCchCopyW(wszCaption, _countof(wszCaption), L"Sorry");
+
+ MessageBoxW(wszMessage, wszCaption, MB_OK);
}
return 0;