Fixed BTabs focus underline offset.
Fixed a typo in method name. Please forgive me Stephan if I just screw your next commit... git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29240 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
3b5507a987
commit
83aff015eb
|
@ -169,7 +169,7 @@ public:
|
||||||
const rgb_color& base, uint32 flags = 0,
|
const rgb_color& base, uint32 flags = 0,
|
||||||
uint32 borders = B_ALL_BORDERS);
|
uint32 borders = B_ALL_BORDERS);
|
||||||
|
|
||||||
virtual void DrawInctiveTab(BView* view, BRect& rect,
|
virtual void DrawInactiveTab(BView* view, BRect& rect,
|
||||||
const BRect& updateRect,
|
const BRect& updateRect,
|
||||||
const rgb_color& base, uint32 flags = 0,
|
const rgb_color& base, uint32 flags = 0,
|
||||||
uint32 borders = B_ALL_BORDERS);
|
uint32 borders = B_ALL_BORDERS);
|
||||||
|
|
|
@ -1247,7 +1247,7 @@ BControlLook::DrawActiveTab(BView* view, BRect& rect, const BRect& updateRect,
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
BControlLook::DrawInctiveTab(BView* view, BRect& rect, const BRect& updateRect,
|
BControlLook::DrawInactiveTab(BView* view, BRect& rect, const BRect& updateRect,
|
||||||
const rgb_color& base, uint32 flags, uint32 borders)
|
const rgb_color& base, uint32 flags, uint32 borders)
|
||||||
{
|
{
|
||||||
if (!rect.IsValid() || !rect.Intersects(updateRect))
|
if (!rect.IsValid() || !rect.Intersects(updateRect))
|
||||||
|
|
|
@ -223,12 +223,12 @@ BTab::DrawFocusMark(BView *owner, BRect frame)
|
||||||
float width = owner->StringWidth(Label());
|
float width = owner->StringWidth(Label());
|
||||||
|
|
||||||
owner->SetHighColor(ui_color(B_KEYBOARD_NAVIGATION_COLOR));
|
owner->SetHighColor(ui_color(B_KEYBOARD_NAVIGATION_COLOR));
|
||||||
// TODO: remove offset
|
|
||||||
float offset = frame.Height() / 2.0;
|
float offset = IsSelected() ? 3 : 2;
|
||||||
owner->StrokeLine(BPoint((frame.left + frame.right - width + offset) / 2.0,
|
owner->StrokeLine(BPoint((frame.left + frame.right - width) / 2.0,
|
||||||
frame.bottom - 3),
|
frame.bottom - offset),
|
||||||
BPoint((frame.left + frame.right + width + offset) / 2.0,
|
BPoint((frame.left + frame.right + width) / 2.0,
|
||||||
frame.bottom - 3));
|
frame.bottom - offset));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -290,7 +290,7 @@ BTab::DrawTab(BView *owner, BRect frame, tab_position position, bool full)
|
||||||
be_control_look->DrawActiveTab(owner, frame, frame, no_tint, 0,
|
be_control_look->DrawActiveTab(owner, frame, frame, no_tint, 0,
|
||||||
borders);
|
borders);
|
||||||
} else {
|
} else {
|
||||||
be_control_look->DrawInctiveTab(owner, frame, frame, no_tint, 0,
|
be_control_look->DrawInactiveTab(owner, frame, frame, no_tint, 0,
|
||||||
borders);
|
borders);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -858,7 +858,7 @@ BTabView::DrawTabs()
|
||||||
| BControlLook::B_BOTTOM_BORDER | BControlLook::B_RIGHT_BORDER;
|
| BControlLook::B_BOTTOM_BORDER | BControlLook::B_RIGHT_BORDER;
|
||||||
if (left == 0)
|
if (left == 0)
|
||||||
borders |= BControlLook::B_LEFT_BORDER;
|
borders |= BControlLook::B_LEFT_BORDER;
|
||||||
be_control_look->DrawInctiveTab(this, frame, frame, base, 0, borders);
|
be_control_look->DrawInactiveTab(this, frame, frame, base, 0, borders);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (fSelection < CountTabs())
|
if (fSelection < CountTabs())
|
||||||
|
|
Loading…
Reference in New Issue