about summary refs log tree commit diff stats
path: root/src/area_popup.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/area_popup.cpp')
-rw-r--r--src/area_popup.cpp18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/area_popup.cpp b/src/area_popup.cpp index 88dffe0..a3ac588 100644 --- a/src/area_popup.cpp +++ b/src/area_popup.cpp
@@ -43,6 +43,21 @@ void AreaPopup::UpdateIndicators() {
43 const MapArea& map_area = GD_GetMapArea(area_id_); 43 const MapArea& map_area = GD_GetMapArea(area_id_);
44 for (int section_id = 0; section_id < map_area.locations.size(); 44 for (int section_id = 0; section_id < map_area.locations.size();
45 section_id++) { 45 section_id++) {
46 const Location& location = map_area.locations.at(section_id);
47 if (location.exclude_reduce) {
48 wxSizer* container_sizer =
49 section_labels_[section_id]->GetContainingSizer();
50
51 if (AP_IsReduceChecks()) {
52 container_sizer->Hide(section_labels_[section_id]);
53 container_sizer->Hide(eye_indicators_[section_id]);
54 continue;
55 } else {
56 container_sizer->Show(section_labels_[section_id]);
57 container_sizer->Show(eye_indicators_[section_id]);
58 }
59 }
60
46 bool checked = AP_HasCheckedGameLocation(area_id_, section_id); 61 bool checked = AP_HasCheckedGameLocation(area_id_, section_id);
47 bool reachable = IsLocationReachable(area_id_, section_id); 62 bool reachable = IsLocationReachable(area_id_, section_id);
48 const wxColour* text_color = reachable ? wxWHITE : wxRED; 63 const wxColour* text_color = reachable ? wxWHITE : wxRED;
@@ -50,4 +65,7 @@ void AreaPopup::UpdateIndicators() {
50 section_labels_[section_id]->SetForegroundColour(*text_color); 65 section_labels_[section_id]->SetForegroundColour(*text_color);
51 eye_indicators_[section_id]->SetChecked(checked); 66 eye_indicators_[section_id]->SetChecked(checked);
52 } 67 }
68
69 section_labels_[0]->GetContainingSizer()->Layout();
70 GetSizer()->Fit(this);
53} 71}