about summary refs log tree commit diff stats
path: root/tracker_panel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tracker_panel.cpp')
-rw-r--r--tracker_panel.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/tracker_panel.cpp b/tracker_panel.cpp index 0e78cc5..1aa7dcf 100644 --- a/tracker_panel.cpp +++ b/tracker_panel.cpp
@@ -13,6 +13,7 @@ TrackerPanel::TrackerPanel(wxWindow *parent) : wxPanel(parent, wxID_ANY) {
13 AreaPopup *area_popup = new AreaPopup(this, map_area.id); 13 AreaPopup *area_popup = new AreaPopup(this, map_area.id);
14 area_popup->SetPosition({0, 0}); 14 area_popup->SetPosition({0, 0});
15 area_popup->Raise(); 15 area_popup->Raise();
16 area_popups_.push_back(area_popup);
16 17
17 AreaWindow *area_window = new AreaWindow(this, map_area.id, area_popup); 18 AreaWindow *area_window = new AreaWindow(this, map_area.id, area_popup);
18 area_window->Lower(); 19 area_window->Lower();
@@ -24,6 +25,18 @@ TrackerPanel::TrackerPanel(wxWindow *parent) : wxPanel(parent, wxID_ANY) {
24 Bind(wxEVT_PAINT, &TrackerPanel::OnPaint, this); 25 Bind(wxEVT_PAINT, &TrackerPanel::OnPaint, this);
25} 26}
26 27
28void TrackerPanel::UpdateIndicators() {
29 Redraw();
30
31 for (AreaWindow *area_window : area_windows_) {
32 area_window->UpdateIndicators();
33 }
34
35 for (AreaPopup *area_popup : area_popups_) {
36 area_popup->UpdateIndicators();
37 }
38}
39
27void TrackerPanel::OnPaint(wxPaintEvent &event) { 40void TrackerPanel::OnPaint(wxPaintEvent &event) {
28 if (GetSize() != rendered_.GetSize()) { 41 if (GetSize() != rendered_.GetSize()) {
29 Redraw(); 42 Redraw();