* Applied patch by hamish to fix layouting the clock.
* This closes #7937, thanks! git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42663 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -160,7 +160,7 @@ TAnalogClock::MouseMoved(BPoint point, uint32 transit, const BMessage* message)
|
||||
|
||||
|
||||
void
|
||||
TAnalogClock::FrameResized(float, float)
|
||||
TAnalogClock::DoLayout()
|
||||
{
|
||||
BRect bounds = Bounds();
|
||||
|
||||
@@ -168,8 +168,7 @@ TAnalogClock::FrameResized(float, float)
|
||||
// (important when drawing with B_SUBPIXEL_PRECISE)
|
||||
fCenterX = floorf((bounds.left + bounds.right) / 2 + 0.5) + 0.5;
|
||||
fCenterY = floorf((bounds.top + bounds.bottom) / 2 + 0.5) + 0.5;
|
||||
fRadius = floorf((MIN(bounds.Width(), bounds.Height()) / 2.0)) - 2.5;
|
||||
fRadius -= 3;
|
||||
fRadius = floorf((MIN(bounds.Width(), bounds.Height()) / 2.0)) - 5.5;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ public:
|
||||
virtual void MouseUp(BPoint point);
|
||||
virtual void MouseMoved(BPoint point, uint32 transit,
|
||||
const BMessage* message);
|
||||
virtual void FrameResized(float, float);
|
||||
virtual void DoLayout();
|
||||
|
||||
virtual BSize MaxSize();
|
||||
virtual BSize MinSize();
|
||||
|
||||
Reference in New Issue
Block a user