mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
profile: implement animation of the tooltip item
To do so, generalize the animation routine. This seems to expose a QtQuick bug: we get spurious hover-events when the tooltip item is updated in the animation. We have to check for that to prevent en endless loop (until the user moves the mouse out of the profile window). Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
06b0a7eeae
commit
d0c26f42d7
6 changed files with 120 additions and 34 deletions
|
|
@ -10,11 +10,11 @@
|
|||
struct dive;
|
||||
struct plot_info;
|
||||
|
||||
class ToolTipItem : public ChartRectItem {
|
||||
class ToolTipItem : public AnimatedChartRectItem {
|
||||
public:
|
||||
ToolTipItem(ChartView &view, double dpr);
|
||||
void update(const dive *d, double dpr, int time, const plot_info &pInfo,
|
||||
const std::vector<std::pair<QString, QPixmap>> &events, bool inPlanner);
|
||||
const std::vector<std::pair<QString, QPixmap>> &events, bool inPlanner, int animSpeed);
|
||||
private:
|
||||
QFont font;
|
||||
QFontMetrics fm;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue