1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-05-05 22:28:57 +02:00

Ensure colours of rulers and TimeTrack background update after a theme change.

This commit is contained in:
James Crook 2017-04-27 11:28:57 +01:00
parent 7661d179ba
commit 60a53d560b
2 changed files with 6 additions and 4 deletions

View File

@ -275,8 +275,9 @@ void TimeTrack::Draw(wxDC & dc, const wxRect & r, const ZoomInfo &zoomInfo) cons
min = max;
}
dc.SetBrush(blankBrush);
dc.SetPen(blankPen);
//dc.SetBrush(blankBrush);
//dc.SetPen(blankPen);
AColor::UseThemeColour( &dc, clrTrackBackground );
dc.DrawRectangle(r);
//copy this rectangle away for future use.
@ -291,6 +292,7 @@ void TimeTrack::Draw(wxDC & dc, const wxRect & r, const ZoomInfo &zoomInfo) cons
// LL: It's because the ruler only Invalidate()s when the NEW value is different
// than the current value.
mRuler->SetFlip(GetHeight() > 75 ? true : true); // MB: so why don't we just call Invalidate()? :)
mRuler->SetTickColour( theTheme.Colour( clrTrackPanelText ));
mRuler->Draw(dc, this);
Doubles envValues{ size_t(mid.width) };

View File

@ -545,7 +545,7 @@ void TrackArtist::DrawVRuler(const Track *t, wxDC * dc, wxRect & rect)
}
UpdateVRuler(t, rr);
vruler->SetTickColour( theTheme.Colour( clrTrackPanelText ));
vruler->Draw(*dc);
return;
@ -569,7 +569,7 @@ void TrackArtist::DrawVRuler(const Track *t, wxDC * dc, wxRect & rect)
}
UpdateVRuler(t, rr);
vruler->SetTickColour( theTheme.Colour( clrTrackPanelText ));
vruler->Draw(*dc);
return;