mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-10 04:57:00 -04:00
draw_control_box instead of draw_control_border
git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@1563 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
@@ -36,18 +36,14 @@ void NativeLookEditor::drawViewer(RotatedDC& dc, ValueViewer& v) {
|
||||
if (!shouldDraw(v)) return;
|
||||
ValueEditor* e = v.getEditor();
|
||||
if (!e || e->drawLabel()) {
|
||||
// draw background
|
||||
// draw control border and box
|
||||
Style& s = *v.getStyle();
|
||||
dc.SetPen(*wxTRANSPARENT_PEN);
|
||||
dc.SetBrush(wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOW));
|
||||
dc.DrawRectangle(s.getInternalRect().grow(1));
|
||||
draw_control_box(this, dc.getDC(), dc.trRectStraight(s.getInternalRect().grow(1)), current_editor == e, e != nullptr);
|
||||
// draw label
|
||||
dc.SetFont(*wxNORMAL_FONT);
|
||||
// TODO : tr using stylesheet or using game?
|
||||
dc.DrawText(tr(getStylePackage(), s.fieldP->name, capitalize_sentence),
|
||||
RealPoint(margin_left - s.left, 1));
|
||||
// draw 3D border
|
||||
draw_control_border(this, dc.getDC(), dc.trRectStraight(s.getInternalRect().grow(1)));
|
||||
}
|
||||
// draw viewer
|
||||
v.draw(dc);
|
||||
|
||||
Reference in New Issue
Block a user