[PATCH] [WinHelp]: removed the topics button, and forward search and topics to the same prop sheet

Eric Pouech eric.pouech at orange.fr
Sat Jul 5 14:33:19 CDT 2008




A+
---

 programs/winhlp32/Bg.rc         |    1 -
 programs/winhlp32/Cs.rc         |    1 -
 programs/winhlp32/Da.rc         |    1 -
 programs/winhlp32/De.rc         |    1 -
 programs/winhlp32/En.rc         |    9 ++++++++-
 programs/winhlp32/Eo.rc         |    1 -
 programs/winhlp32/Es.rc         |    1 -
 programs/winhlp32/Fi.rc         |    1 -
 programs/winhlp32/Fr.rc         |    1 -
 programs/winhlp32/Hu.rc         |    1 -
 programs/winhlp32/It.rc         |    1 -
 programs/winhlp32/Ko.rc         |    1 -
 programs/winhlp32/Nl.rc         |    1 -
 programs/winhlp32/No.rc         |    1 -
 programs/winhlp32/Pl.rc         |    1 -
 programs/winhlp32/Pt.rc         |    2 --
 programs/winhlp32/Rm.rc         |    1 -
 programs/winhlp32/Ru.rc         |    1 -
 programs/winhlp32/Si.rc         |    1 -
 programs/winhlp32/Sk.rc         |    1 -
 programs/winhlp32/Sv.rc         |    1 -
 programs/winhlp32/Tr.rc         |    1 -
 programs/winhlp32/Wa.rc         |    1 -
 programs/winhlp32/Zh.rc         |    1 -
 programs/winhlp32/macro.c       |    4 ++--
 programs/winhlp32/winhelp.c     |   41 +++++++++++++++++++++++++++++++++++----
 programs/winhlp32/winhelp.h     |    2 +-
 programs/winhlp32/winhelp_res.h |    2 +-
 28 files changed, 49 insertions(+), 33 deletions(-)


diff --git a/programs/winhlp32/Bg.rc b/programs/winhlp32/Bg.rc
index 4cb04e5..88200df 100644
--- a/programs/winhlp32/Bg.rc
+++ b/programs/winhlp32/Bg.rc
@@ -77,7 +77,6 @@ STID_HLPFILE_ERROR_s, 	"Ãðåøêà ïðè ÷åòåíå íà ïîìîùíèÿ ôàéë `%s'"
 STID_CONTENTS, 		"&Ñúäúðæàíèå"
 STID_SEARCH, 		"&Òúðñè"
 STID_BACK, 		"&Íàçàä"
-STID_TOPICS,		"&Òåìè"
 STID_ALL_FILES, 	"Âñè÷êè ôàéëîâå (*.*)"
 STID_HELP_FILES_HLP, 	"Ïîìîùíè ôàéëîâå (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Cs.rc b/programs/winhlp32/Cs.rc
index 98d2d81..ca5e658 100644
--- a/programs/winhlp32/Cs.rc
+++ b/programs/winhlp32/Cs.rc
@@ -82,7 +82,6 @@ STID_HLPFILE_ERROR_s, 	"Nelze pøeèíst soubor nápovìdy `%s'"
 STID_CONTENTS, 		"&Obsah"
 STID_SEARCH, 		"&Hledat"
 STID_BACK, 		"&Zpìt"
-STID_TOPICS,		"&Témata"
 STID_ALL_FILES, 	"Všechny soubory (*.*)"
 STID_HELP_FILES_HLP, 	"Soubory nápovìdy (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Da.rc b/programs/winhlp32/Da.rc
index 9e5c489..7054068 100644
--- a/programs/winhlp32/Da.rc
+++ b/programs/winhlp32/Da.rc
@@ -89,7 +89,6 @@ STID_HLPFILE_ERROR_s, 	"Fejl ved indlæsning af filen `%s'"
 STID_CONTENTS, 		"&Indhold"
 STID_SEARCH, 		"&Søg"
 STID_BACK, 		"&Tilbage"
-STID_TOPICS, 		"&Emner"
 STID_ALL_FILES, 	"Alle filer (*.*)"
 STID_HELP_FILES_HLP, 	"Hjælpe filer (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Kan ikke finde '%s'. Vil du selv finde filen?"
diff --git a/programs/winhlp32/De.rc b/programs/winhlp32/De.rc
index 4686275..de9455a 100644
--- a/programs/winhlp32/De.rc
+++ b/programs/winhlp32/De.rc
@@ -89,7 +89,6 @@ STID_HLPFILE_ERROR_s, 	"Fehler beim Lesen der Hilfe-Datei `%s'"
 STID_CONTENTS, 		"&Inhalt"
 STID_SEARCH, 		"&Suchen"
 STID_BACK, 		"&Zurück"
-STID_TOPICS, 		"&Themen"
 STID_ALL_FILES, 	"Alle Dateien (*.*)"
 STID_HELP_FILES_HLP, 	"Hilfe-Dateien (*.hlp)"
 STID_FILE_NOT_FOUND_s	"'%s' konnte nicht gefunden werden. Wollen Sie selber nach dieser Datei suchen?"
diff --git a/programs/winhlp32/En.rc b/programs/winhlp32/En.rc
index 4407d78..d289abd 100644
--- a/programs/winhlp32/En.rc
+++ b/programs/winhlp32/En.rc
@@ -76,6 +76,14 @@ CAPTION "Index"
     PUSHBUTTON "&Cancel", IDCANCEL, 120, 170, 50, 12
 }
 
+IDD_SEARCH DIALOG DISCARDABLE 0, 0, 200, 190 LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT
+STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU
+FONT 8, "MS Shell Dlg"
+CAPTION "Search"
+{
+    LTEXT  "Not implemented yet", -1, 10, 10, 180, 150
+}
+
 /* Strings */
 STRINGTABLE DISCARDABLE LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT
 {
@@ -88,7 +96,6 @@ STID_HLPFILE_ERROR_s, 	"Error while reading the help file `%s'"
 STID_CONTENTS, 		"&Contents"
 STID_SEARCH, 		"&Search"
 STID_BACK, 		"&Back"
-STID_TOPICS,		"&Topics"
 STID_ALL_FILES, 	"All files (*.*)"
 STID_HELP_FILES_HLP, 	"Help files (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Eo.rc b/programs/winhlp32/Eo.rc
index f3f0ecb..4da1a99 100644
--- a/programs/winhlp32/Eo.rc
+++ b/programs/winhlp32/Eo.rc
@@ -80,7 +80,6 @@ STID_HLPFILE_ERROR_s, 	"Eraro dum la legado de helpdosiero `%s'"
 STID_CONTENTS, 	"&Enhavo"
 STID_SEARCH, 		"&Seræu"
 STID_BACK, 		"&Retro"
-STID_TOPICS,		"&Temoj"
 STID_ALL_FILES, 	"Tutaj dosieroj (*.*)"
 STID_HELP_FILES_HLP, 	"Helpaj dosieroj (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Es.rc b/programs/winhlp32/Es.rc
index d514b7a..04cf048 100644
--- a/programs/winhlp32/Es.rc
+++ b/programs/winhlp32/Es.rc
@@ -79,7 +79,6 @@ STID_HLPFILE_ERROR_s, 	"Error al leer el archivo de ayuda `%s'"
 STID_CONTENTS, 		"&Índice"
 STID_SEARCH, 		"&Buscar"
 STID_BACK, 		"&Anterior"
-STID_TOPICS,		"&Temas"
 STID_ALL_FILES, 	"Todos los archivos (*.*)"
 STID_HELP_FILES_HLP, 	"Archivos de ayuda (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Fi.rc b/programs/winhlp32/Fi.rc
index 588c253..e2cba6c 100644
--- a/programs/winhlp32/Fi.rc
+++ b/programs/winhlp32/Fi.rc
@@ -80,7 +80,6 @@ STID_HLPFILE_ERROR_s, 	"Virhe luettaessa ohjetiedostoa `%s'"
 STID_CONTENTS, 		"&Sisällys"
 STID_SEARCH, 		"&Etsi"
 STID_BACK, 		"&Takaisin"
-STID_TOPICS,		"T&opics"
 STID_ALL_FILES, 	"Kaikki tiedostot (*.*)"
 STID_HELP_FILES_HLP, 	"Ohjetiedostot (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Fr.rc b/programs/winhlp32/Fr.rc
index 1a976ad..66bf3e2 100644
--- a/programs/winhlp32/Fr.rc
+++ b/programs/winhlp32/Fr.rc
@@ -91,7 +91,6 @@ STID_HLPFILE_ERROR_s, 	"Une erreur est survenue en lisant le fichier d'aide « %s
 STID_CONTENTS, 		"&Index"
 STID_SEARCH, 		"&Rechercher"
 STID_BACK, 		"&Précédent"
-STID_TOPICS,		"&Sujets"
 STID_ALL_FILES, 	"Tous fichiers (*.*)"
 STID_HELP_FILES_HLP, 	"Fichiers d'aide (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Impossible de trouver « %s ». Souhaitez-vous rechercher ce fichier vous-même ?"
diff --git a/programs/winhlp32/Hu.rc b/programs/winhlp32/Hu.rc
index 3c08f06..8dc3fe1 100644
--- a/programs/winhlp32/Hu.rc
+++ b/programs/winhlp32/Hu.rc
@@ -80,7 +80,6 @@ STID_HLPFILE_ERROR_s, 	"Hiba a `%s' file olvasásakor"
 STID_CONTENTS, 		"&Tartalom"
 STID_SEARCH, 		"&Keresés"
 STID_BACK, 		"&Vissza"
-STID_TOPICS,		"&Témakörök"
 STID_ALL_FILES, 	"Minden fájl (*.*)"
 STID_HELP_FILES_HLP, 	"Súgó fájlok (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/It.rc b/programs/winhlp32/It.rc
index bfeccf1..b733588 100644
--- a/programs/winhlp32/It.rc
+++ b/programs/winhlp32/It.rc
@@ -79,7 +79,6 @@ STID_HLPFILE_ERROR_s, 	"Errore di lettura del file della Guida `%s'"
 STID_CONTENTS, 		"&Sommario"
 STID_SEARCH, 		"&Trova"
 STID_BACK, 		"&Precedente"
-STID_TOPICS,		"&Argomenti"
 STID_ALL_FILES, 	"Tutti i file (*.*)"
 STID_HELP_FILES_HLP, 	"File della Guida (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Ko.rc b/programs/winhlp32/Ko.rc
index 290bfc2..e234408 100644
--- a/programs/winhlp32/Ko.rc
+++ b/programs/winhlp32/Ko.rc
@@ -91,7 +91,6 @@ STID_HLPFILE_ERROR_s, 	"µµ¿ò¸» ÆÄÀÏ `%s'¸¦ Àд µµÁß ¿À·ù ¹ß»ý"
 STID_CONTENTS, 		"¸ñÂ÷(&C)"
 STID_SEARCH, 		"ã±â(&S)"
 STID_BACK, 		"µÚ·Î(&B)"
-STID_TOPICS,		"¸ñÂ÷(&T)"
 STID_ALL_FILES, 	"¸ðµç ÆÄÀÏ (*.*)"
 STID_HELP_FILES_HLP, 	"µµ¿ò¸» ÆÄÀÏ (*.hlp)"
 STID_FILE_NOT_FOUND_s	"%sÀ» ãÀ» ¼ö ¾ø½À´Ï´Ù'. ÀÌ ÆÄÀÏÀ» Á÷Á¢ ã°Ú½À´Ï±î?"
diff --git a/programs/winhlp32/Nl.rc b/programs/winhlp32/Nl.rc
index d5b7268..410f6be 100644
--- a/programs/winhlp32/Nl.rc
+++ b/programs/winhlp32/Nl.rc
@@ -88,7 +88,6 @@ STID_HLPFILE_ERROR_s, 	"Fout bij het lezen van het helpbestand `%s'"
 STID_CONTENTS, 		"&Inhoud"
 STID_SEARCH, 		"&Zoeken"
 STID_BACK, 		"&Terug"
-STID_TOPICS,		"&Onderwerpen"
 STID_ALL_FILES, 	"Alle bestanden (*.*)"
 STID_HELP_FILES_HLP, 	"Helpbestanden (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Kan '%s' niet openen. Wilt u zelf dit bestand zoeken?"
diff --git a/programs/winhlp32/No.rc b/programs/winhlp32/No.rc
index 54e65c8..08c7e4b 100644
--- a/programs/winhlp32/No.rc
+++ b/programs/winhlp32/No.rc
@@ -87,7 +87,6 @@ STID_HLPFILE_ERROR_s, 	"Feil ved lesing av hjelpefilen '%s'"
 STID_CONTENTS, 		"&Innhold"
 STID_SEARCH, 		"&Søk"
 STID_BACK, 		"Til&bake"
-STID_TOPICS,		"&Emner"
 STID_ALL_FILES, 	"Alle filer (*.*)"
 STID_HELP_FILES_HLP, 	"Hjelp-filer (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Pl.rc b/programs/winhlp32/Pl.rc
index ca80974..07dcdf7 100644
--- a/programs/winhlp32/Pl.rc
+++ b/programs/winhlp32/Pl.rc
@@ -89,7 +89,6 @@ STID_HLPFILE_ERROR_s, 	"B³¹d w trakcie odczytu pliku pomocy `%s'"
 STID_CONTENTS, 		"&ZawartoϾ"
 STID_SEARCH, 		"&Szukaj"
 STID_BACK, 		"&Wstecz"
-STID_TOPICS,		"&Tematy"
 STID_ALL_FILES, 	"Wszystkie pliki (*.*)"
 STID_HELP_FILES_HLP, 	"Pliki pomocy (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Nie znaleziono pliku '%s'. Czy chcesz poszukaæ tego pliku samodzielnie?"
diff --git a/programs/winhlp32/Pt.rc b/programs/winhlp32/Pt.rc
index 939d844..c27a893 100644
--- a/programs/winhlp32/Pt.rc
+++ b/programs/winhlp32/Pt.rc
@@ -134,7 +134,6 @@ STID_HLPFILE_ERROR_s, 	"Erro encontrado na leitura do arquivo de ajuda '%s'"
 STID_CONTENTS, 		"&Conteúdo"
 STID_SEARCH, 		"&Procurar"
 STID_BACK, 		"&Voltar"
-STID_TOPICS,		"&Tópicos"
 STID_ALL_FILES, 	"Todos os arquivos (*.*)"
 STID_HELP_FILES_HLP, 	"Arquivos de ajuda (*.hlp)"
 STID_FILE_NOT_FOUND_s   "Cannot find '%s'. Do you want to find this file yourself?"
@@ -155,7 +154,6 @@ STID_HLPFILE_ERROR_s, 	"Erro encontrado na leitura do ficheiro de ajuda '%s'"
 STID_CONTENTS, 		"&Conteúdo"
 STID_SEARCH, 		"&Procurar"
 STID_BACK, 		"&Voltar"
-STID_TOPICS,		"&Tópicos"
 STID_ALL_FILES, 	"Todos os ficheiros (*.*)"
 STID_HELP_FILES_HLP, 	"Ficheiros de ajuda (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Não é possível encontrar '%s'. Deseja procurar este ficheiro você mesmo?"
diff --git a/programs/winhlp32/Rm.rc b/programs/winhlp32/Rm.rc
index df90d77..3e4579a 100644
--- a/programs/winhlp32/Rm.rc
+++ b/programs/winhlp32/Rm.rc
@@ -82,7 +82,6 @@ STID_HLPFILE_ERROR_s,   "Sbagl cun leger la datoteca d'ag�d `%s'"
 STID_CONTENTS,          "&Cuntgn�"
 STID_SEARCH,            "&Tscherchar"
 STID_BACK,              "&Inavo"
-STID_TOPICS,            "T&opics"
 STID_ALL_FILES,         "Tuot las datotecas (*.*)"
 STID_HELP_FILES_HLP,    "Datotecas d'ag�d (*.hlp)"
 STID_FILE_NOT_FOUND_s   "Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Ru.rc b/programs/winhlp32/Ru.rc
index 59e9ca3..54d869d 100644
--- a/programs/winhlp32/Ru.rc
+++ b/programs/winhlp32/Ru.rc
@@ -87,7 +87,6 @@ STID_HLPFILE_ERROR_s, 	"Îøèáêà ïðè ÷òåíèè ôàéëà ïîìîùè `%s'"
 STID_CONTENTS, 		"&Ñîäåðæàíèå"
 STID_SEARCH, 		"&Íàéòè"
 STID_BACK, 		"&Íàçàä"
-STID_TOPICS,		"&Óêàçàòåëü"
 STID_ALL_FILES, 	"Âñå ôàéëû (*.*)"
 STID_HELP_FILES_HLP, 	"Ôàéëû ñïðàâêè (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Íå ìîãó íàéòè '%s'. Âû õîòèòå íàéòè ýòîò ôàéë ñàìîñòîÿòåëüíî?"
diff --git a/programs/winhlp32/Si.rc b/programs/winhlp32/Si.rc
index 8d4a0f4..091064b 100644
--- a/programs/winhlp32/Si.rc
+++ b/programs/winhlp32/Si.rc
@@ -89,7 +89,6 @@ STID_HLPFILE_ERROR_s, 	"Napaka pri branju datoteke s pomočjo `%s'"
 STID_CONTENTS, 		"&Teme pomoči"
 STID_SEARCH, 		"&Iskanje"
 STID_BACK, 		"&Nazaj"
-STID_TOPICS,		"&Vsebina"
 STID_ALL_FILES, 	"Vse datoteke (*.*)"
 STID_HELP_FILES_HLP, 	"Datoteke s pomočjo (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Ne najdem datoteke '%s'. Ali jo želite poiskati sami?"
diff --git a/programs/winhlp32/Sk.rc b/programs/winhlp32/Sk.rc
index e849e92..f882eb7 100644
--- a/programs/winhlp32/Sk.rc
+++ b/programs/winhlp32/Sk.rc
@@ -75,7 +75,6 @@ STID_HLPFILE_ERROR_s,       "Chyba poèas èítania súboru `%s'"
 STID_CONTENTS,              "&Obsah"
 STID_SEARCH,                "&H¾ada"
 STID_BACK,                  "&Spä"
-STID_TOPICS,		    "&Topics"
 STID_ALL_FILES,             "Všetky súbory (*.*)"
 STID_HELP_FILES_HLP,        "Súbory pomoci (*.hlp)"
 STID_FILE_NOT_FOUND_s       "Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Sv.rc b/programs/winhlp32/Sv.rc
index bd479c4..412ce00 100644
--- a/programs/winhlp32/Sv.rc
+++ b/programs/winhlp32/Sv.rc
@@ -80,7 +80,6 @@ STID_HLPFILE_ERROR_s, 	"Fel vid läsning av hjälpfilen `%s'"
 STID_CONTENTS, 		"&Innehåll"
 STID_SEARCH, 		"&Sök"
 STID_BACK, 		"&Bakåt"
-STID_TOPICS,		"&Ämnen"
 STID_ALL_FILES, 	"Alla filer (*.*)"
 STID_HELP_FILES_HLP, 	"Hjälpfiler (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Kan inte hitta '%s'. Vill du söka efter denna fil?"
diff --git a/programs/winhlp32/Tr.rc b/programs/winhlp32/Tr.rc
index 205129e..77a3766 100644
--- a/programs/winhlp32/Tr.rc
+++ b/programs/winhlp32/Tr.rc
@@ -77,7 +77,6 @@ STID_HLPFILE_ERROR_s, 	"'%s' yardým dosyasý açýlýrken hata"
 STID_CONTENTS, 		"&Ýçindekiler"
 STID_SEARCH, 		"&Ara"
 STID_BACK, 		"&Geri"
-STID_TOPICS,		"&Konular"
 STID_ALL_FILES, 	"Tüm dosyalar (*.*)"
 STID_HELP_FILES_HLP, 	"Yardým dosyalarý (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Wa.rc b/programs/winhlp32/Wa.rc
index 49c66fb..72d22d6 100644
--- a/programs/winhlp32/Wa.rc
+++ b/programs/winhlp32/Wa.rc
@@ -82,7 +82,6 @@ STID_HLPFILE_ERROR_s, 	"Yåk n' a nén stî å moumint di lere li fitchî d' aide `%s
 STID_CONTENTS, 		"Å&dvins"
 STID_SEARCH, 		"C&werî"
 STID_BACK, 		"Èn &Erî"
-STID_TOPICS,		"&Topics"
 STID_ALL_FILES, 	"Tos les fitchîs (*.*)"
 STID_HELP_FILES_HLP, 	"Fitchîs d' aide (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/Zh.rc b/programs/winhlp32/Zh.rc
index c7dd7d6..d15e311 100644
--- a/programs/winhlp32/Zh.rc
+++ b/programs/winhlp32/Zh.rc
@@ -78,7 +78,6 @@ STID_HLPFILE_ERROR_s, 	"¶ÁÈë°ïÖúÎļþ ¡®%s¡¯ ʱ·¢Éú´íÎó"
 STID_CONTENTS, 		"ÄÚÈÝ£¨&C£©"
 STID_SEARCH, 		"ËÑË÷£¨&S£©"
 STID_BACK, 		"·µ»Ø£¨&B£©"
-STID_TOPICS,		"Ö÷Ì⣨&T£©"
 STID_ALL_FILES, 	"ËùÓÐÎļþ (*.*)"
 STID_HELP_FILES_HLP, 	"°ïÖúÎļþ (*.hlp)"
 STID_FILE_NOT_FOUND_s	"Cannot find '%s'. Do you want to find this file yourself?"
diff --git a/programs/winhlp32/macro.c b/programs/winhlp32/macro.c
index 66eac0f..06aa2d7 100644
--- a/programs/winhlp32/macro.c
+++ b/programs/winhlp32/macro.c
@@ -517,7 +517,7 @@ void CALLBACK MACRO_Find(void)
 
 void CALLBACK MACRO_Finder(void)
 {
-    WINHELP_CreateIndexWindow();
+    WINHELP_CreateIndexWindow(FALSE);
 }
 
 void CALLBACK MACRO_FloatingMenu(void)
@@ -880,7 +880,7 @@ void CALLBACK MACRO_SaveMark(LPCSTR str)
 
 void CALLBACK MACRO_Search(void)
 {
-    WINE_FIXME("()\n");
+    WINHELP_CreateIndexWindow(TRUE);
 }
 
 void CALLBACK MACRO_SetContents(LPCSTR str, LONG u)
diff --git a/programs/winhlp32/winhelp.c b/programs/winhlp32/winhelp.c
index effa0bd..d794f72 100644
--- a/programs/winhlp32/winhelp.c
+++ b/programs/winhlp32/winhelp.c
@@ -632,8 +632,6 @@ BOOL WINHELP_CreateHelpWindow(WINHELP_WNDPAGE* wpage, int nCmdShow, BOOL remembe
         LoadString(Globals.hInstance, STID_BACK, buffer, sizeof(buffer));
         MACRO_CreateButton("BTN_BACK", buffer, "Back()");
         if (win->back.index <= 1) MACRO_DisableButton("BTN_BACK");
-        LoadString(Globals.hInstance, STID_TOPICS, buffer, sizeof(buffer));
-        MACRO_CreateButton("BTN_TOPICS", buffer, "Finder()");
     }
 
     if (!bReUsed)
@@ -1623,12 +1621,41 @@ INT_PTR CALLBACK WINHELP_IndexDlgProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM
 }
 
 /**************************************************************************
+ * WINHELP_SearchDlgProc
+ *
+ */
+INT_PTR CALLBACK WINHELP_SearchDlgProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam)
+{
+    static struct index_data* id;
+
+    switch (msg)
+    {
+    case WM_INITDIALOG:
+        id = (struct index_data*)((PROPSHEETPAGE*)lParam)->lParam;
+        return TRUE;
+    case WM_NOTIFY:
+	switch (((NMHDR*)lParam)->code)
+	{
+	case PSN_APPLY:
+            SetWindowLongPtr(hWnd, DWLP_MSGRESULT, PSNRET_NOERROR);
+            return TRUE;
+        default:
+            return FALSE;
+        }
+        break;
+    default:
+        break;
+    }
+    return FALSE;
+}
+
+/**************************************************************************
  * WINHELP_CreateIndexWindow
  *
  * Displays a dialog with keywords of current help file.
  *
  */
-BOOL WINHELP_CreateIndexWindow(void)
+BOOL WINHELP_CreateIndexWindow(BOOL is_search)
 {
     HPROPSHEETPAGE      psPage[3];
     PROPSHEETPAGE       psp;
@@ -1660,6 +1687,11 @@ BOOL WINHELP_CreateIndexWindow(void)
     psp.pfnDlgProc = WINHELP_IndexDlgProc;
     psPage[0] = CreatePropertySheetPage(&psp);
 
+    psp.u.pszTemplate = MAKEINTRESOURCE(IDD_SEARCH);
+    psp.lParam = (LPARAM)&id;
+    psp.pfnDlgProc = WINHELP_SearchDlgProc;
+    psPage[1] = CreatePropertySheetPage(&psp);
+
     memset(&psHead, 0, sizeof(psHead));
     psHead.dwSize = sizeof(psHead);
 
@@ -1667,7 +1699,8 @@ BOOL WINHELP_CreateIndexWindow(void)
     strcat(buf, Globals.active_win->info->caption);
 
     psHead.pszCaption = buf;
-    psHead.nPages = 1;
+    psHead.nPages = 2;
+    psHead.u2.nStartPage = is_search ? 1 : 0;
     psHead.hwndParent = Globals.active_win->hMainWnd;
     psHead.u3.phpage = psPage;
     psHead.dwFlags = PSH_NOAPPLYNOW;
diff --git a/programs/winhlp32/winhelp.h b/programs/winhlp32/winhelp.h
index 0555539..7d959af 100644
--- a/programs/winhlp32/winhelp.h
+++ b/programs/winhlp32/winhelp.h
@@ -146,7 +146,7 @@ BOOL WINHELP_CreateHelpWindow(WINHELP_WNDPAGE*, int, BOOL);
 BOOL WINHELP_OpenHelpWindow(HLPFILE_PAGE* (*)(HLPFILE*, LONG, ULONG*),
                             HLPFILE*, LONG, HLPFILE_WINDOWINFO*, int);
 BOOL WINHELP_GetOpenFileName(LPSTR, int);
-BOOL WINHELP_CreateIndexWindow(void);
+BOOL WINHELP_CreateIndexWindow(BOOL);
 void WINHELP_DeleteBackSet(WINHELP_WINDOW*);
 INT  WINHELP_MessageBoxIDS_s(UINT, LPCSTR, UINT, WORD);
 HLPFILE* WINHELP_LookupHelpFile(LPCSTR lpszFile);
diff --git a/programs/winhlp32/winhelp_res.h b/programs/winhlp32/winhelp_res.h
index eb57a96..c5d6215 100644
--- a/programs/winhlp32/winhelp_res.h
+++ b/programs/winhlp32/winhelp_res.h
@@ -45,7 +45,6 @@
 #define STID_CONTENTS 		0x126
 #define STID_SEARCH	 	0x127
 #define STID_BACK 		0x128
-#define STID_TOPICS 		0x12A
 #define STID_ALL_FILES 		0x12B
 #define STID_HELP_FILES_HLP	0x12C
 #define STID_DIALOG_TEST	0x12D
@@ -55,5 +54,6 @@
 
 #define IDD_INDEX               0x150
 #define IDC_INDEXLIST           0x151
+#define IDD_SEARCH              0x152
 
 #define IDI_WINHELP             0xF00





More information about the wine-patches mailing list