summaryrefslogtreecommitdiff
path: root/src/ai/ai_gui.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/ai/ai_gui.cpp')
-rw-r--r--src/ai/ai_gui.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/ai/ai_gui.cpp b/src/ai/ai_gui.cpp
index 01506ada5..1705af314 100644
--- a/src/ai/ai_gui.cpp
+++ b/src/ai/ai_gui.cpp
@@ -604,6 +604,7 @@ struct AIConfigWindow : public Window {
if (this->selected_slot > 1) {
Swap(_settings_newgame.ai_config[this->selected_slot], _settings_newgame.ai_config[this->selected_slot - 1]);
this->selected_slot--;
+ this->vscroll.ScrollTowards(this->selected_slot);
this->InvalidateData();
}
break;
@@ -612,6 +613,7 @@ struct AIConfigWindow : public Window {
if (this->selected_slot < _settings_newgame.difficulty.max_no_competitors) {
Swap(_settings_newgame.ai_config[this->selected_slot], _settings_newgame.ai_config[this->selected_slot + 1]);
this->selected_slot++;
+ this->vscroll.ScrollTowards(this->selected_slot);
this->InvalidateData();
}
break;