Modified some classes to succesfully comunicate with BWindow/BView. the default decorator has been impoved. From now borders are build ARROUND the window area.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@4432 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -33,7 +33,11 @@
|
||||
#include "TokenHandler.h"
|
||||
#include "ServerWindow.h"
|
||||
#include "WinBorder.h"
|
||||
#include "RootLayer.h"
|
||||
#include "Desktop.h"
|
||||
#include "DisplayDriver.h"
|
||||
#include "Decorator.h"
|
||||
|
||||
|
||||
//#define DEBUG_WORKSPACE
|
||||
//#define DEBUG_SCREEN
|
||||
@@ -443,6 +447,26 @@ printf("Screen::RemoveWindow(%s)\n",win?win->GetTitle():"NULL");
|
||||
|
||||
win->_winborder->RemoveSelf();
|
||||
}
|
||||
/*!
|
||||
\brief Returns the WinBorder taht contains the point
|
||||
\param The point
|
||||
\return The WinBorder that contains the point
|
||||
*/
|
||||
WinBorder* Screen::GetWindowAt( BPoint pt ){
|
||||
WinBorder *wb;
|
||||
Layer *rl = GetRootLayer();
|
||||
Layer *child;
|
||||
for(child = rl->_bottomchild; child!=NULL; child = child->_uppersibling)
|
||||
{
|
||||
if(child->_hidecount>0)
|
||||
continue;
|
||||
wb = dynamic_cast<WinBorder*>( child );
|
||||
if (wb)
|
||||
if(wb->GetDecorator()->GetFootprint()->Contains(pt))
|
||||
return wb;
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/*!
|
||||
\brief Returns the active window in the current workspace
|
||||
|
||||
Reference in New Issue
Block a user