* "where" and "be:view_where" are supposed to contain the same value; dunno
why the latter is then even added, but we do the same thing as BeOS now. * This fixes bug #2075. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24997 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -3050,8 +3050,7 @@ BWindow::_UnpackMessage(unpack_cookie& cookie, BMessage** _message, BHandler** _
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*!
|
/*! Some messages don't get to the window in a shape an application should see.
|
||||||
Some messages don't get to the window in a shape an application should see.
|
|
||||||
This method is supposed to give a message the last grinding before
|
This method is supposed to give a message the last grinding before
|
||||||
it's acceptable for the receiving application.
|
it's acceptable for the receiving application.
|
||||||
*/
|
*/
|
||||||
@@ -3070,13 +3069,12 @@ BWindow::_SanitizeMessage(BMessage* message, BHandler* target, bool usePreferred
|
|||||||
if (message->FindPoint("screen_where", &where) != B_OK)
|
if (message->FindPoint("screen_where", &where) != B_OK)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
// add local window coordinates
|
|
||||||
message->AddPoint("where", ConvertFromScreen(where));
|
|
||||||
|
|
||||||
BView* view = dynamic_cast<BView*>(target);
|
BView* view = dynamic_cast<BView*>(target);
|
||||||
if (view != NULL) {
|
if (view != NULL) {
|
||||||
// add local view coordinates
|
// add local view coordinates
|
||||||
message->AddPoint("be:view_where", view->ConvertFromScreen(where));
|
message->AddPoint("be:view_where",
|
||||||
|
view->ConvertFromScreen(where));
|
||||||
|
message->AddPoint("where", view->ConvertFromScreen(where));
|
||||||
|
|
||||||
if (message->what == B_MOUSE_MOVED) {
|
if (message->what == B_MOUSE_MOVED) {
|
||||||
// is there a token of the view that is currently under the mouse?
|
// is there a token of the view that is currently under the mouse?
|
||||||
@@ -3106,6 +3104,9 @@ BWindow::_SanitizeMessage(BMessage* message, BHandler* target, bool usePreferred
|
|||||||
if (usePreferred || viewUnderMouse == NULL)
|
if (usePreferred || viewUnderMouse == NULL)
|
||||||
fLastMouseMovedView = viewUnderMouse;
|
fLastMouseMovedView = viewUnderMouse;
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
// add local window coordinates
|
||||||
|
message->AddPoint("where", ConvertFromScreen(where));
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user