WinCE 4 cleanup
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@25017 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
504de6d140
commit
2d36b3d847
@ -48,7 +48,9 @@
|
||||
#if defined(__WXWINCE__)
|
||||
#include <ole2.h>
|
||||
#include <shellapi.h>
|
||||
#include <aygshell.h>
|
||||
#if _WIN32_WCE < 400
|
||||
#include <aygshell.h>
|
||||
#endif
|
||||
#endif
|
||||
|
||||
// include <commctrl.h> "properly"
|
||||
@ -1808,7 +1810,7 @@ bool wxListCtrl::MSWOnNotify(int idCtrl, WXLPARAM lParam, WXLPARAM *result)
|
||||
event.m_col = nmHDR->iItem;
|
||||
break;
|
||||
|
||||
#ifdef __WXWINCE__
|
||||
#if defined(__WXWINCE__) && _WIN32_WCE < 400
|
||||
case GN_CONTEXTMENU:
|
||||
#endif //__WXWINCE__
|
||||
case NM_RCLICK:
|
||||
@ -1822,7 +1824,7 @@ bool wxListCtrl::MSWOnNotify(int idCtrl, WXLPARAM lParam, WXLPARAM *result)
|
||||
|
||||
// where did the click occur?
|
||||
POINT ptClick;
|
||||
#ifdef __WXWINCE__
|
||||
#if defined(__WXWINCE__) && _WIN32_WCE < 400
|
||||
if(nmhdr->code == GN_CONTEXTMENU) {
|
||||
ptClick = ((NMRGINFO*)nmhdr)->ptAction;
|
||||
} else
|
||||
@ -2142,7 +2144,7 @@ bool wxListCtrl::MSWOnNotify(int idCtrl, WXLPARAM lParam, WXLPARAM *result)
|
||||
event.m_item.m_data = GetItemData(iItem);
|
||||
break;
|
||||
|
||||
#ifdef __WXWINCE__
|
||||
#if defined(__WXWINCE__) && _WIN32_WCE < 400
|
||||
case GN_CONTEXTMENU:
|
||||
#endif //__WXWINCE__
|
||||
case NM_RCLICK:
|
||||
@ -2157,7 +2159,7 @@ bool wxListCtrl::MSWOnNotify(int idCtrl, WXLPARAM lParam, WXLPARAM *result)
|
||||
LV_HITTESTINFO lvhti;
|
||||
wxZeroMemory(lvhti);
|
||||
|
||||
#ifdef __WXWINCE__
|
||||
#if defined(__WXWINCE__) && _WIN32_WCE < 400
|
||||
if(nmhdr->code == GN_CONTEXTMENU) {
|
||||
lvhti.pt = ((NMRGINFO*)nmhdr)->ptAction;
|
||||
} else
|
||||
|
@ -51,12 +51,12 @@
|
||||
#include <ole2.h>
|
||||
#include <shellapi.h>
|
||||
#include <commctrl.h>
|
||||
#if _WIN32_WCE < 400
|
||||
#include <aygshell.h>
|
||||
|
||||
#ifndef TBSTYLE_NO_DROPDOWN_ARROW
|
||||
#define TBSTYLE_NO_DROPDOWN_ARROW 0x0080
|
||||
#endif
|
||||
|
||||
#include "wx/msw/wince/missing.h"
|
||||
|
||||
#endif
|
||||
|
||||
// other standard headers
|
||||
@ -745,7 +745,7 @@ WXHMENU wxMenuBar::Create()
|
||||
// since you have to use resources.
|
||||
// We'll have to find another way to add a menu
|
||||
// by changing/adding menu items to an existing menu.
|
||||
#ifdef __WXWINCE__
|
||||
#if defined(__WXWINCE__) && _WIN32_WCE < 400
|
||||
if ( m_hMenu != 0 )
|
||||
return m_hMenu;
|
||||
|
||||
@ -806,6 +806,17 @@ WXHMENU wxMenuBar::Create()
|
||||
}
|
||||
}
|
||||
|
||||
#if _WIN32_WCE >= 400
|
||||
if (GetToolBar())
|
||||
{
|
||||
HWND hCommandBar = (HWND) GetToolBar()->GetHWND();
|
||||
if (!CommandBar_InsertMenubarEx(hCommandBar, NULL, (LPTSTR) m_hMenu, 0))
|
||||
{
|
||||
wxLogLastError(wxT("CommandBar_InsertMenubarEx"));
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
return m_hMenu;
|
||||
#endif
|
||||
}
|
||||
|
@ -45,7 +45,10 @@
|
||||
#if defined(__WXWINCE__)
|
||||
#include <ole2.h>
|
||||
#include <shellapi.h>
|
||||
#include <aygshell.h>
|
||||
#if _WIN32_WCE < 400
|
||||
#include <aygshell.h>
|
||||
#endif
|
||||
#include "wx/msw/wince/missing.h"
|
||||
#endif
|
||||
|
||||
#include "wx/msw/winundef.h"
|
||||
@ -737,7 +740,7 @@ bool wxTopLevelWindowMSW::ShowFullScreen(bool show, long style)
|
||||
rect.x, rect.y, rect.width, rect.height,
|
||||
flags);
|
||||
|
||||
#ifdef __WXWINCE__
|
||||
#if __WXWINCE__ && _WIN32_WCE < 400
|
||||
::SHFullScreen(GetHwnd(), SHFS_HIDETASKBAR | SHFS_HIDESIPBUTTON);
|
||||
#endif
|
||||
|
||||
@ -747,7 +750,7 @@ bool wxTopLevelWindowMSW::ShowFullScreen(bool show, long style)
|
||||
}
|
||||
else // stop showing full screen
|
||||
{
|
||||
#ifdef __WXWINCE__
|
||||
#if __WXWINCE__ && _WIN32_WCE < 400
|
||||
::SHFullScreen(GetHwnd(), SHFS_SHOWTASKBAR | SHFS_SHOWSIPBUTTON);
|
||||
#endif
|
||||
Maximize(m_fsIsMaximized);
|
||||
|
@ -54,7 +54,10 @@
|
||||
#include <ole2.h>
|
||||
#include <shellapi.h>
|
||||
#include <commctrl.h>
|
||||
#include <aygshell.h>
|
||||
#if _WIN32_WCE < 400
|
||||
#include <aygshell.h>
|
||||
#endif
|
||||
#include "wx/msw/wince/missing.h"
|
||||
|
||||
#include "wx/msw/winundef.h"
|
||||
|
||||
@ -256,6 +259,10 @@ bool wxToolBar::MSWCreateToolbar(const wxPoint& pos, const wxSize& size, wxMenuB
|
||||
if (m_menuBar)
|
||||
m_menuBar->SetToolBar(this);
|
||||
|
||||
#if _WIN32_WCE >= 400
|
||||
HWND hWnd = CommandBar_Create(wxGetInstance(), (HWND) GetParent()->GetHWND(), GetId());
|
||||
SetHWND((WXHWND) hWnd);
|
||||
#else
|
||||
// Create the menubar.
|
||||
SHMENUBARINFO mbi;
|
||||
|
||||
@ -279,12 +286,8 @@ bool wxToolBar::MSWCreateToolbar(const wxPoint& pos, const wxSize& size, wxMenuB
|
||||
}
|
||||
|
||||
SetHWND((WXHWND) mbi.hwndMB);
|
||||
/*
|
||||
if (!::SendMessage((HWND) GetHWND(), TB_DELETEBUTTON, 0, (LPARAM) 0))
|
||||
{
|
||||
wxLogLastError(wxT("TB_DELETEBUTTON"));
|
||||
}
|
||||
*/
|
||||
#endif
|
||||
|
||||
// install wxWindows window proc for this window
|
||||
SubclassWin(m_hWnd);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user