Skip to content

#14 Pie Chart Popups Gone

Eduard requested to merge issue_14_pie_chart_gone_further_cleanup into main

Fix #14 (closed) & cleanup the code a bit.

The issue was that leave_notify_event would get called as soon as the tooltip (containing info about the selected item) would appear. This caused the variable highlighted_item to be set to null and hence make the tooltip instantly disappear.

This MR does a few things:

  1. remove leave_notify_event entirely and only set highlighted_item when a move event or click event has happened.
  2. Always enable has_tooltip
  3. remove return value from highlight_item_at_point (since we always have has_tooltip enabled)

I'm not sure if this is the best solution, happy to take review comments make changes as long as the code ends up being modernised / simplified.

Best Wishes!

Edited by Eduard

Merge request reports