OSDN Git Service

2006-04-18 Eric House <ehouse@eehouse.org>
authordannysmith <dannysmith>
Tue, 18 Apr 2006 09:35:29 +0000 (09:35 +0000)
committerdannysmith <dannysmith>
Tue, 18 Apr 2006 09:35:29 +0000 (09:35 +0000)
PocketPC support.
* include/aygshell.h: New file [_WIN32_WCE]. Declare most common
functions for using aygshell on PocketPC:
SHCreateMenuBar, SHFindMenuBar, SHCreateNewItem, SHFullScreen,
SHSipInfo, SHHandleWMActivate, SHHandleWMSettingChange

* include/commctrl.h [_WIN32_WCE] Add function prototypes for
command bar API on PocketPC:
CommandBar_Create, CommandBar_Show, CommandBar_AddBitmap,
CommandBar_InsertComboBox, CommandBar_InsertMenubar,
CommandBar_InsertMenubarEx, CommandBar_DrawMenuBar,
CommandBar_GetMenu, CommandBar_AddAdornments, CommandBar_Height,
CommandBar_InsertButton, CommandBar_Destroy.

* include/winbase.h [_WIN32_WCE] (WIN32_FIND_DATA{A|W}): Remove
 fields not present on PocketPC.
(GetCurrentThreadId): Conditionally declare as extern function
without dllimport attribute on PocketPC.
  (ResetEvent): Likwise.
(SetEvent): Likewise.

* include/wingdi.h [_WIN32_WCE]  (GetTextExtentPoint32{A|W}):
Conditionally declare as extern function without dllimport
 attribute on PocketPC.
* winuser.h  [_WIN32_WCE] (DialogBoxParam{A|W}): Conditionally
declare as extern function without dllimport attribute on PocketPC.

winsup/w32api/ChangeLog
winsup/w32api/include/commctrl.h
winsup/w32api/include/winbase.h
winsup/w32api/include/wingdi.h
winsup/w32api/include/winuser.h
winsup/w32api/lib/test.c

index f4bf5ab..62e9ed6 100644 (file)
@@ -1,3 +1,36 @@
+2006-04-18  Eric House  <ehouse@eehouse.org>
+
+       PocketPC support.
+       * include/aygshell.h: New file [_WIN32_WCE]. Declare most common
+       functions for using aygshell on PocketPC:
+       SHCreateMenuBar, SHFindMenuBar, SHCreateNewItem, SHFullScreen,
+       SHSipInfo, SHHandleWMActivate, SHHandleWMSettingChange
+
+       * include/commctrl.h [_WIN32_WCE] Add function prototypes for
+       command bar API on PocketPC:
+       CommandBar_Create, CommandBar_Show, CommandBar_AddBitmap,
+       CommandBar_InsertComboBox, CommandBar_InsertMenubar,
+       CommandBar_InsertMenubarEx, CommandBar_DrawMenuBar,
+       CommandBar_GetMenu, CommandBar_AddAdornments, CommandBar_Height,
+       CommandBar_InsertButton, CommandBar_Destroy.
+
+       * include/winbase.h [_WIN32_WCE] (WIN32_FIND_DATA{A|W}): Remove
+       fields not present on PocketPC.
+       (GetCurrentThreadId): Conditionally declare as extern function
+       without dllimport attribute on PocketPC.
+       (ResetEvent): Likwise.
+       (SetEvent): Likewise.
+
+       * include/wingdi.h [_WIN32_WCE]  (GetTextExtentPoint32{A|W}):
+       Conditionally declare as extern function without dllimport
+        attribute on PocketPC.
+       * winuser.h  [_WIN32_WCE] (DialogBoxParam{A|W}): Conditionally
+       declare as extern function without dllimport attribute on PocketPC.
+
+2006-04-18  Thorsten Dahlheimer (dahlheim@users.sf.net>
+
+       * lib/test.c: Include icm.h.
+
 2006-04-18  Thorsten Dahlheimer (dahlheim@users.sf.net>
 
        * include/wingdi.h (ColorCorrectPalette): Add declaration.
index 46368e0..e5bc461 100644 (file)
@@ -15,6 +15,15 @@ extern "C" {
 #endif
 #endif
 
+#ifndef COMMCTRLAPI
+#ifdef __W32API_USE_DLLIMPORT__
+#define COMMCTRLAPI DECLSPEC_IMPORT
+#else
+#define COMMCTRLAPI
+#endif
+#endif
+
+
 #ifndef SNDMSG
 #ifdef __cplusplus
 #define SNDMSG ::SendMessage
@@ -3705,6 +3714,28 @@ typedef REBARBANDINFOA REBARBANDINFO,*LPREBARBANDINFO;
 #endif
 #endif /* RC_INVOKED */
 
+#ifdef _WIN32_WCE               /* these are PPC only */
+
+COMMCTRLAPI HWND WINAPI CommandBar_Create(HINSTANCE, HWND, int); 
+COMMCTRLAPI BOOL WINAPI CommandBar_Show(HWND, BOOL); 
+COMMCTRLAPI int WINAPI CommandBar_AddBitmap(HWND, HINSTANCE, int, int, int, int); 
+COMMCTRLAPI HWND WINAPI CommandBar_InsertComboBox(HWND, HINSTANCE, int, UINT, WORD, WORD); 
+COMMCTRLAPI BOOL WINAPI CommandBar_InsertMenubar(HWND, HINSTANCE, WORD, WORD );
+COMMCTRLAPI BOOL WINAPI CommandBar_InsertMenubarEx(HWND, HINSTANCE, LPTSTR, WORD);
+COMMCTRLAPI BOOL WINAPI CommandBar_DrawMenuBar(HWND, WORD); 
+COMMCTRLAPI HMENU WINAPI CommandBar_GetMenu(HWND, WORD); 
+COMMCTRLAPI BOOL WINAPI CommandBar_AddAdornments(HWND, DWORD, DWORD); 
+COMMCTRLAPI int WINAPI CommandBar_Height(HWND hwndCB); 
+
+/* These two are not in the DLL */
+#define CommandBar_InsertButton(hwnd,i,lptbbutton)              \
+    SendMessage((hwnd),TB_INSERTBUTTON,(i),(lptbbutton))
+#define CommandBar_Destroy(hwnd)                                \
+    DestroyWindow(hwnd)
+
+
+#endif /* _WIN32_WCE */
+
 #ifdef __cplusplus
 }
 #endif
index 707dbfd..be78b2f 100644 (file)
@@ -819,10 +819,16 @@ typedef struct _WIN32_FIND_DATAA {
        FILETIME ftLastWriteTime;
        DWORD nFileSizeHigh;
        DWORD nFileSizeLow;
+#ifdef _WIN32_WCE
+    DWORD dwOID; 
+#else
        DWORD dwReserved0;
        DWORD dwReserved1;
+#endif
        CHAR cFileName[MAX_PATH];
+#ifndef _WIN32_WCE
        CHAR cAlternateFileName[14];
+#endif
 } WIN32_FIND_DATAA,*PWIN32_FIND_DATAA,*LPWIN32_FIND_DATAA;
 typedef struct _WIN32_FIND_DATAW {
        DWORD dwFileAttributes;
@@ -831,10 +837,16 @@ typedef struct _WIN32_FIND_DATAW {
        FILETIME ftLastWriteTime;
        DWORD nFileSizeHigh;
        DWORD nFileSizeLow;
+#ifdef _WIN32_WCE
+    DWORD dwOID; 
+#else
        DWORD dwReserved0;
        DWORD dwReserved1;
+#endif
        WCHAR cFileName[MAX_PATH];
+#ifndef _WIN32_WCE
        WCHAR cAlternateFileName[14];
+#endif
 } WIN32_FIND_DATAW,*PWIN32_FIND_DATAW,*LPWIN32_FIND_DATAW;
 typedef struct _WIN32_STREAM_ID {
        DWORD dwStreamId;
@@ -1374,7 +1386,11 @@ WINBASEAPI BOOL WINAPI GetCurrentHwProfileW(LPHW_PROFILE_INFOW);
 WINBASEAPI HANDLE WINAPI GetCurrentProcess(void);
 WINBASEAPI DWORD WINAPI GetCurrentProcessId(void);
 WINBASEAPI HANDLE WINAPI GetCurrentThread(void);
+#ifdef _WIN32_WCE
+extern DWORD GetCurrentThreadId(void);
+#else
 WINBASEAPI DWORD WINAPI GetCurrentThreadId(void);
+#endif
 #define GetCurrentTime GetTickCount
 WINBASEAPI BOOL WINAPI GetDefaultCommConfigA(LPCSTR,LPCOMMCONFIG,PDWORD);
 WINBASEAPI BOOL WINAPI GetDefaultCommConfigW(LPCWSTR,LPCOMMCONFIG,PDWORD);
@@ -1804,7 +1820,11 @@ WINBASEAPI BOOL WINAPI ReplaceFileW(LPCWSTR,LPCWSTR,LPCWSTR,DWORD,LPVOID,LPVOID)
 #endif
 WINBASEAPI BOOL WINAPI ReportEventA(HANDLE,WORD,WORD,DWORD,PSID,WORD,DWORD,LPCSTR*,PVOID);
 WINBASEAPI BOOL WINAPI ReportEventW(HANDLE,WORD,WORD,DWORD,PSID,WORD,DWORD,LPCWSTR*,PVOID);
+#ifdef _WIN32_WCE
+extern BOOL ResetEvent(HANDLE);
+#else
 WINBASEAPI BOOL WINAPI ResetEvent(HANDLE);
+#endif
 WINBASEAPI UINT WINAPI ResetWriteWatch(LPVOID,SIZE_T);
 #if (_WIN32_WINNT >= 0x0510)
 WINBASEAPI VOID WINAPI RestoreLastError(DWORD);
@@ -1837,7 +1857,11 @@ WINBASEAPI BOOL WINAPI SetEndOfFile(HANDLE);
 WINBASEAPI BOOL WINAPI SetEnvironmentVariableA(LPCSTR,LPCSTR);
 WINBASEAPI BOOL WINAPI SetEnvironmentVariableW(LPCWSTR,LPCWSTR);
 WINBASEAPI UINT WINAPI SetErrorMode(UINT);
+#ifdef _WIN32_WCE
+extern BOOL SetEvent(HANDLE);
+#else
 WINBASEAPI BOOL WINAPI SetEvent(HANDLE);
+#endif
 WINBASEAPI VOID WINAPI SetFileApisToANSI(void);
 WINBASEAPI VOID WINAPI SetFileApisToOEM(void);
 WINBASEAPI BOOL WINAPI SetFileAttributesA(LPCSTR,DWORD);
index dcf5263..cf2bf24 100644 (file)
@@ -2756,8 +2756,13 @@ WINGDIAPI BOOL WINAPI GetTextExtentExPointA(HDC,LPCSTR,int,int,LPINT,LPINT,LPSIZ
 WINGDIAPI BOOL WINAPI GetTextExtentExPointW( HDC,LPCWSTR,int,int,LPINT,LPINT,LPSIZE );
 WINGDIAPI BOOL WINAPI GetTextExtentPointA(HDC,LPCSTR,int,LPSIZE);
 WINGDIAPI BOOL WINAPI GetTextExtentPointW(HDC,LPCWSTR,int,LPSIZE);
+#ifdef _WIN32_WCE
+extern BOOL GetTextExtentPoint32A(HDC,LPCSTR,int,LPSIZE);
+extern BOOL GetTextExtentPoint32W( HDC,LPCWSTR,int,LPSIZE);
+#else
 WINGDIAPI BOOL WINAPI GetTextExtentPoint32A(HDC,LPCSTR,int,LPSIZE);
 WINGDIAPI BOOL WINAPI GetTextExtentPoint32W( HDC,LPCWSTR,int,LPSIZE);
+#endif
 WINGDIAPI int WINAPI GetTextFaceA(HDC,int,LPSTR);
 WINGDIAPI int WINAPI GetTextFaceW(HDC,int,LPWSTR);
 WINGDIAPI BOOL WINAPI GetTextMetricsA(HDC,LPTEXTMETRICA);
index 63fc1e4..e9b06df 100644 (file)
@@ -3385,8 +3385,13 @@ WINUSERAPI BOOL WINAPI DestroyWindow(HWND);
 #define DialogBoxIndirectW(i,t,p,f) DialogBoxIndirectParamW(i,t,p,f,0)
 WINUSERAPI int WINAPI DialogBoxIndirectParamA(HINSTANCE,LPCDLGTEMPLATE,HWND,DLGPROC,LPARAM);
 WINUSERAPI int WINAPI DialogBoxIndirectParamW(HINSTANCE,LPCDLGTEMPLATE,HWND,DLGPROC,LPARAM);
+#ifdef _WIN32_WCE
+extern int DialogBoxParamA(HINSTANCE,LPCSTR,HWND,DLGPROC,LPARAM);
+extern int DialogBoxParamW(HINSTANCE,LPCWSTR,HWND,DLGPROC,LPARAM);
+#else
 WINUSERAPI int WINAPI DialogBoxParamA(HINSTANCE,LPCSTR,HWND,DLGPROC,LPARAM);
 WINUSERAPI int WINAPI DialogBoxParamW(HINSTANCE,LPCWSTR,HWND,DLGPROC,LPARAM);
+#endif
 WINUSERAPI LONG WINAPI DispatchMessageA(const MSG*);
 WINUSERAPI LONG WINAPI DispatchMessageW(const MSG*);
 WINUSERAPI int WINAPI DlgDirListA(HWND,LPSTR,int,int,UINT);
index 77e3e64..f4959b4 100644 (file)
@@ -29,6 +29,7 @@
 
 #include <dbt.h>
 #include <httpext.h>
+#include <icm.h>
 #include <imagehlp.h>
 #include <initguid.h>
 #include <ipexport.h>