diff --git a/winsup/w32api/ChangeLog b/winsup/w32api/ChangeLog index f4bf5ab04..62e9ed609 100644 --- a/winsup/w32api/ChangeLog +++ b/winsup/w32api/ChangeLog @@ -1,3 +1,36 @@ +2006-04-18 Eric House + + 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. diff --git a/winsup/w32api/include/commctrl.h b/winsup/w32api/include/commctrl.h index 46368e010..e5bc46192 100644 --- a/winsup/w32api/include/commctrl.h +++ b/winsup/w32api/include/commctrl.h @@ -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 diff --git a/winsup/w32api/include/winbase.h b/winsup/w32api/include/winbase.h index 707dbfd17..be78b2f27 100644 --- a/winsup/w32api/include/winbase.h +++ b/winsup/w32api/include/winbase.h @@ -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); diff --git a/winsup/w32api/include/wingdi.h b/winsup/w32api/include/wingdi.h index dcf5263f8..cf2bf2412 100644 --- a/winsup/w32api/include/wingdi.h +++ b/winsup/w32api/include/wingdi.h @@ -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); diff --git a/winsup/w32api/include/winuser.h b/winsup/w32api/include/winuser.h index 63fc1e477..e9b06dfab 100644 --- a/winsup/w32api/include/winuser.h +++ b/winsup/w32api/include/winuser.h @@ -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); diff --git a/winsup/w32api/lib/test.c b/winsup/w32api/lib/test.c index 77e3e646e..f4959b4fe 100644 --- a/winsup/w32api/lib/test.c +++ b/winsup/w32api/lib/test.c @@ -29,6 +29,7 @@ #include #include +#include #include #include #include