diff options
author | Ulf Hermann <[email protected]> | 2016-08-22 19:52:20 +0200 |
---|---|---|
committer | Ulf Hermann <[email protected]> | 2016-08-23 12:36:42 +0000 |
commit | 8c80a8626674563cf17add41deaa522417e63d95 (patch) | |
tree | 7373f4ab6055bf5549cc214d0f68200c5464bd8e | |
parent | f4b8ec1efc5cb2b50ac4cf9d8d0fc7db5028d336 (diff) |
Timeline: Fix event compression for non-default heightsv4.1.0
The "id" member of OpaqueColoredPoint2DWithSize is then used as the
number of events compressed into one. To discern it from an actual
id it's also negated. Thus, it needs to be updated when adding an
event. This is not a problem for default height items because their
top is always at 0, so that the addition of the 'y' members doesn't
have an effect.
Change-Id: Ibd7218954e36661d7f729465430de89821a41a7f
Task-number: QTCREATORBUG-16763
Reviewed-by: Christian Kandeler <[email protected]>
Reviewed-by: Eike Ziller <[email protected]>
Reviewed-by: Ulf Hermann <[email protected]>
-rw-r--r-- | src/libs/timeline/timelineitemsrenderpass.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/libs/timeline/timelineitemsrenderpass.cpp b/src/libs/timeline/timelineitemsrenderpass.cpp index 235a3388168..e7281b0101a 100644 --- a/src/libs/timeline/timelineitemsrenderpass.cpp +++ b/src/libs/timeline/timelineitemsrenderpass.cpp @@ -143,8 +143,12 @@ float OpaqueColoredPoint2DWithSize::top() const void OpaqueColoredPoint2DWithSize::update(float nr, float ny) { - if (a <= MaximumDirection) + if (a <= MaximumDirection) { a += MaximumDirection; + id = -2; + } else { + --id; + } y += ny; w = nr - x; |