]>
git.saurik.com Git - wxWidgets.git/blob - src/os2/popupwin.cpp
11f6b5d978abcebe93fcfe742900903a9248d34b
1 ///////////////////////////////////////////////////////////////////////////////
2 // Name: os2/popupwin.cpp
3 // Purpose: implements wxPopupWindow for OS2
4 // Author: Dave Webster
8 // Copyright: (c) 2002 Dave Webster <dwebster@bhmi.com>
9 // License: wxWindows licence
10 ///////////////////////////////////////////////////////////////////////////////
12 // ============================================================================
14 // ============================================================================
16 // ----------------------------------------------------------------------------
18 // ----------------------------------------------------------------------------
21 #pragma implementation "popup.h"
24 // For compilers that support precompilation, includes "wx.h".
25 #include "wx/wxprec.h"
32 #include "wx/popupwin.h"
34 // ============================================================================
36 // ============================================================================
38 bool wxPopupWindow::Create( wxWindow
* pParent
,
41 return wxPopupWindowBase::Create(pParent
) &&
42 wxWindow::Create( pParent
46 ,nFlags
| wxPOPUP_WINDOW
48 } // end of wxPopupWindow::Create
50 void wxPopupWindow::DoGetPosition( int* pnX
,
54 // The position of a "top level" window such as this should be in
55 // screen coordinates, not in the client ones which MSW gives us
56 // (because we are a child window)
58 wxPopupWindowBase::DoGetPosition(pnX
, pnY
);
59 GetParent()->ClientToScreen(pnX
, pnY
);
60 } // end of wxPopupWindow::DoGetPosition
62 WXHWND
wxPopupWindow::OS2GetParent() const
64 // we must be a child of the desktop to be able to extend beyond the parent
65 // window client area (like the comboboxes drop downs do)
67 return (WXHWND
)HWND_DESKTOP
;
68 } // end of wxPopupWindow::OS2GetParent
70 WXDWORD
wxPopupWindow::OS2GetStyle( long lFlags
,
71 WXDWORD
* dwExstyle
) const
73 WXDWORD dwStyle
= wxWindow::OS2GetStyle( lFlags
& wxBORDER_MASK
78 } // end of wxPopupWindow::OS2GetStyle