* Fixed build.

* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@39437 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler
2010-11-15 18:31:21 +00:00
parent 495e073b20
commit 55a54abc90
@@ -19,6 +19,9 @@
using namespace BPrivate;
const uint32 kExtentPenalty = 10;
GroupCookie::GroupCookie(SATWindow* satWindow)
:
fSATWindow(satWindow),
@@ -42,7 +45,6 @@ GroupCookie::GroupCookie(SATWindow* satWindow)
fWidthConstraint(NULL),
fHeightConstraint(NULL)
{
}
@@ -52,9 +54,6 @@ GroupCookie::~GroupCookie()
}
const uint32 kExtentPenalty = 10;
void
GroupCookie::DoGroupLayout(SATWindow* triggerWindow)
{
@@ -274,6 +273,9 @@ GroupCookie::_UpdateWindowSize(const BRect& frame)
}
// #pragma mark -
SATWindow::SATWindow(StackAndTile* sat, Window* window)
:
fWindow(window),
@@ -552,12 +554,15 @@ SATWindow::GetSizeLimits(int32* minWidth, int32* maxWidth, int32* minHeight,
fWindow->GetSizeLimits(minWidth, maxWidth, minHeight, maxHeight);
SATDecorator* decorator = GetDecorator();
if (!decorator)
if (decorator == NULL)
return;
*minWidth += 2 * decorator->BorderWidth() + 1;
*minHeight += 2 * decorator->BorderWidth() + decorator->TabHeight() + 1;
*maxWidth += 2 * decorator->BorderWidth() + 1;
*maxHeight += 2 * decorator->BorderWidth() + decorator->TabHeight() + 1;
*minWidth += 2 * (int32)decorator->BorderWidth() + 1;
*minHeight += 2 * (int32)decorator->BorderWidth()
+ (int32)decorator->TabHeight() + 1;
*maxWidth += 2 * (int32)decorator->BorderWidth() + 1;
*maxHeight += 2 * (int32)decorator->BorderWidth()
+ (int32)decorator->TabHeight() + 1;
}
@@ -723,17 +728,18 @@ SATWindow::_UpdateSizeLimits()
&maxDecorWidth, &maxDecorHeight);
BRect frame = fWindow->Frame();
if (fOriginalMinWidth <= minDecorWidth)
minWidth = frame.Width();
minWidth = frame.IntegerWidth();
if (fOriginalMinHeight <= minDecorHeight)
minHeight = frame.Height();
minHeight = frame.IntegerHeight();
}
fWindow->SetSizeLimits(minWidth, B_SIZE_UNLIMITED,
minHeight, B_SIZE_UNLIMITED);
if (decorator) {
minWidth += 2 * decorator->BorderWidth();
minHeight += 2 * decorator->BorderWidth() + decorator->TabHeight() + 1;
minWidth += 2 * (int32)decorator->BorderWidth();
minHeight += 2 * (int32)decorator->BorderWidth()
+ (int32)decorator->TabHeight() + 1;
}
fGroupCookie->SetSizeLimits(minWidth, B_SIZE_UNLIMITED, minHeight,
B_SIZE_UNLIMITED);