Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Goudey <h.goudey@me.com>2020-06-15 15:35:52 +0300
committerHans Goudey <h.goudey@me.com>2020-06-15 15:35:52 +0300
commit046afacbc69069a2244f10a3a38e2f8afd8a5f39 (patch)
tree14f62e0b3046d6370bb29d63e7ba7089cd0571d2 /source/blender/editors/animation/time_scrub_ui.c
parent73f8dd0f4cb5277df1d161cd1ceee5a630a84cd7 (diff)
Fix T77116: Current frame indicator text color hardcoded
Draw the text with the "header text highlight" theme color, which is rarely used, making it a good candidate for this special case. Differential Revision: https://developer.blender.org/D7897
Diffstat (limited to 'source/blender/editors/animation/time_scrub_ui.c')
-rw-r--r--source/blender/editors/animation/time_scrub_ui.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/editors/animation/time_scrub_ui.c b/source/blender/editors/animation/time_scrub_ui.c
index 7679995d9a4..863f433c778 100644
--- a/source/blender/editors/animation/time_scrub_ui.c
+++ b/source/blender/editors/animation/time_scrub_ui.c
@@ -95,7 +95,6 @@ static void draw_current_frame(const Scene *scene,
int current_frame)
{
const uiFontStyle *fstyle = UI_FSTYLE_WIDGET;
- const uchar color[] = {255, 255, 255, 255};
int frame_x = UI_view2d_view_to_region_x(v2d, current_frame);
char frame_str[64];
@@ -127,11 +126,13 @@ static void draw_current_frame(const Scene *scene,
4 * UI_DPI_FAC,
bg_color);
+ uchar text_color[4];
+ UI_GetThemeColor4ubv(TH_HEADER_TEXT_HI, text_color);
UI_fontstyle_draw_simple(fstyle,
frame_x - text_width / 2 + U.pixelsize / 2,
get_centered_text_y(scrub_region_rect),
frame_str,
- color);
+ text_color);
}
void ED_time_scrub_draw(const ARegion *region,