Correctly check if the mouse has been on the tab.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@39750 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Clemens Zeidler
2010-12-06 19:31:11 +00:00
parent c2a14a1a85
commit d8db8216de
2 changed files with 2 additions and 2 deletions
@@ -43,7 +43,7 @@ public:
/*! Indicates that window is stacked */
void SetStackedMode(bool stacked, BRegion* dirty);
bool StackedMode() const
{ return fStackedMode; };
{ return fStackedMode; }
/*! Set the tab length if the decorator is in stacked mode and if
the tab is the last one in the tab bar. */
@@ -797,7 +797,7 @@ SATWindow::_RestoreOriginalSize(bool stayBelowMouse)
if (decorator == NULL)
return;
BRect tabRect = decorator->TabRect();
if (mousePosition.y < tabRect.bottom
if (mousePosition.y < tabRect.bottom && mousePosition.y > tabRect.top
&& mousePosition.x <= frame.right + decorator->BorderWidth() +1
&& mousePosition.x >= frame.left + decorator->BorderWidth()) {
// verify mouse stays on the tab