wxUniv compilation fixes (patch 559620)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15652 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -593,6 +593,10 @@ class WXDLLEXPORT wxMouseEvent : public wxEvent
|
||||
{
|
||||
public:
|
||||
wxMouseEvent(wxEventType mouseType = wxEVT_NULL);
|
||||
wxMouseEvent(const wxMouseEvent& event) { Assign(event); }
|
||||
|
||||
wxMouseEvent& operator=(const wxMouseEvent& event)
|
||||
{ Assign(event); return *this; }
|
||||
|
||||
// Was it a button event? (*doesn't* mean: is any button *down*?)
|
||||
bool IsButton() const { return Button(-1); }
|
||||
@@ -739,6 +743,9 @@ public:
|
||||
int m_wheelDelta;
|
||||
int m_linesPerAction;
|
||||
|
||||
protected:
|
||||
void Assign(const wxMouseEvent& evt);
|
||||
|
||||
private:
|
||||
DECLARE_DYNAMIC_CLASS(wxMouseEvent)
|
||||
};
|
||||
|
@@ -386,6 +386,25 @@ wxMouseEvent::wxMouseEvent(wxEventType commandType)
|
||||
m_linesPerAction = 0;
|
||||
}
|
||||
|
||||
void wxMouseEvent::Assign(const wxMouseEvent& event)
|
||||
{
|
||||
m_x = event.m_x;
|
||||
m_y = event.m_y;
|
||||
|
||||
m_leftDown = event.m_leftDown;
|
||||
m_middleDown = event.m_middleDown;
|
||||
m_rightDown = event.m_rightDown;
|
||||
|
||||
m_controlDown = event.m_controlDown;
|
||||
m_shiftDown = event.m_shiftDown;
|
||||
m_altDown = event.m_altDown;
|
||||
m_metaDown = event.m_metaDown;
|
||||
|
||||
m_wheelRotation = event.m_wheelRotation;
|
||||
m_wheelDelta = event.m_wheelDelta;
|
||||
m_linesPerAction = event.m_linesPerAction;
|
||||
}
|
||||
|
||||
// True if was a button dclick event (1 = left, 2 = middle, 3 = right)
|
||||
// or any button dclick event (but = -1)
|
||||
bool wxMouseEvent::ButtonDClick(int but) const
|
||||
|
@@ -179,7 +179,7 @@ static void TranslateKbdEventToMouse(wxWindowMSW *win,
|
||||
static TEXTMETRIC wxGetTextMetrics(const wxWindowMSW *win);
|
||||
|
||||
// find the window for the mouse event at the specified position
|
||||
static wxWindowMSW *FindWindowForMouseEvent(wxWindow *win, int *x, int *y);
|
||||
static wxWindowMSW *FindWindowForMouseEvent(wxWindowMSW *win, int *x, int *y); //TW:REQ:Univ
|
||||
|
||||
// wrapper around BringWindowToTop() API
|
||||
static inline void wxBringWindowToTop(HWND hwnd)
|
||||
@@ -2427,7 +2427,7 @@ long wxWindowMSW::MSWWindowProc(WXUINT message, WXWPARAM wParam, WXLPARAM lParam
|
||||
}
|
||||
else
|
||||
{
|
||||
wxWindow *win = FindWindowForMouseEvent(this, &x, &y);
|
||||
wxWindowMSW *win = FindWindowForMouseEvent(this, &x, &y); //TW:REQ:Univ
|
||||
processed = win->HandleMouseEvent(message, x, y, wParam);
|
||||
}
|
||||
}
|
||||
@@ -3992,7 +3992,7 @@ void wxWindowMSW::InitMouseEvent(wxMouseEvent& event,
|
||||
// Notice that this is not done for the mouse move events because this could
|
||||
// (would?) be too slow, but only for clicks which means that the static texts
|
||||
// still don't get move, enter nor leave events.
|
||||
static wxWindowMSW *FindWindowForMouseEvent(wxWindow *win, int *x, int *y)
|
||||
static wxWindowMSW *FindWindowForMouseEvent(wxWindowMSW *win, int *x, int *y) //TW:REQ:Univ
|
||||
{
|
||||
wxCHECK_MSG( x && y, win, _T("NULL pointer in FindWindowForMouseEvent") );
|
||||
|
||||
|
Reference in New Issue
Block a user