Don't make layer indentation wider for child layers when we zoom in the timeline

This commit is contained in:
David Capello 2019-07-01 16:18:32 -03:00
parent f2fae67734
commit fed9a2b45c

View File

@ -2095,7 +2095,9 @@ void Timeline::drawLayer(ui::Graphics* g, int layerIdx)
doc::color_t layerColor = layer->userData().color();
gfx::Rect textBounds = bounds;
if (m_rows[layerIdx].level() > 0) {
int w = m_rows[layerIdx].level()*frameBoxWidth();
const int frameBoxWithWithoutZoom =
skinTheme()->dimensions.timelineBaseSize();
const int w = m_rows[layerIdx].level()*frameBoxWithWithoutZoom;
textBounds.x += w;
textBounds.w -= w;
}