[CHARMAP][IMAGESOFT]
[reactos.git] / reactos / base / applications / charmap / charmap.c
index 5b4b402..f3d7829 100644 (file)
@@ -9,15 +9,14 @@
 
 #include <precomp.h>
 
-#define ID_ABOUT    0x1
+#include <commctrl.h>
+#include <richedit.h>
 
-typedef struct {
-    BOOL    IsAdvancedView;
-} SETTINGS;
+#define ID_ABOUT    0x1
 
 HINSTANCE hInstance;
-HWND      hCharmapDlg;
 HWND      hAdvancedDlg;
+HWND      hCharmapDlg;
 HWND      hStatusWnd;
 HICON     hSmIcon;
 HICON     hBgIcon;
@@ -37,7 +36,7 @@ EnumFontNames(ENUMLOGFONTEXW *lpelfe,
 
     /* make sure font doesn't already exist in our list */
     if(SendMessageW(hwndCombo,
-                    CB_FINDSTRING,
+                    CB_FINDSTRINGEXACT,
                     0,
                     (LPARAM)pszName) == CB_ERR)
     {
@@ -103,7 +102,7 @@ FillFontStyleComboList(HWND hwndCombo)
 }
 
 
-static
+extern
 VOID
 ChangeMapFont(HWND hDlg)
 {
@@ -464,6 +463,7 @@ PanelWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam)
         break;
 
     case WM_DESTROY:
+        SaveSettings();
         PostQuitMessage(0);
         return 0;
 
@@ -534,6 +534,7 @@ InitInstance(HINSTANCE hInst)
 
     if (hWnd != NULL)
     {
+        LoadSettings();
         ShowWindow(hWnd, SW_SHOW);
         UpdateWindow(hWnd);
     }