diff --git a/application/preferences/AccountListItem.cpp b/application/preferences/AccountListItem.cpp index ace9b0e..cf99b2c 100644 --- a/application/preferences/AccountListItem.cpp +++ b/application/preferences/AccountListItem.cpp @@ -50,46 +50,3 @@ AccountListItem::SetAccount(const char* name) } -void -AccountListItem::DrawItem(BView* owner, BRect frame, bool complete) -{ - rgb_color highColor = owner->HighColor(); - rgb_color lowColor = owner->LowColor(); - - // Draw selection - if (IsSelected()) { - rgb_color highlightColor = ui_color(B_CONTROL_HIGHLIGHT_COLOR); - - owner->SetLowColor(highlightColor); - owner->SetHighColor(highlightColor); - owner->FillRect(frame); - } - - // Draw account name - rgb_color textColor = ui_color(B_CONTROL_TEXT_COLOR); - owner->MovePenTo(frame.left, frame.top + fBaselineOffset); - if (!IsEnabled()) - owner->SetHighColor(tint_color(textColor, B_LIGHTEN_2_TINT)); - else - owner->SetHighColor(textColor); - owner->DrawString(Text()); - - owner->SetHighColor(highColor); - owner->SetLowColor(lowColor); -} - - -void -AccountListItem::Update(BView* owner, const BFont* font) -{ - if (Text()) - SetWidth(font->StringWidth(Text())); - - font_height height; - font->GetHeight(&height); - - fBaselineOffset = 2 + ceilf(height.ascent + height.leading / 2); - - SetHeight(ceilf(height.ascent) + ceilf(height.descent) - + ceilf(height.leading) + 4); -} diff --git a/application/preferences/AccountListItem.h b/application/preferences/AccountListItem.h index a904ce0..809e9ce 100644 --- a/application/preferences/AccountListItem.h +++ b/application/preferences/AccountListItem.h @@ -21,11 +21,6 @@ public: const char* Account() const; void SetAccount(const char* name); - void DrawItem(BView* owner, BRect frame, - bool complete = false); - - void Update(BView* owner, const BFont* font); - private: ProtocolSettings* fSettings; BString fAccount;