Merge branch 'save_ext' into jgrpp

# Conflicts:
#	config.lib
#	src/misc_gui.cpp
#	src/network/network_gui.cpp
#	src/settings_type.h
#	src/smallmap_gui.cpp
#	src/smallmap_gui.h
#	src/station_cmd.cpp
#	src/toolbar_gui.cpp
#	src/vehicle_gui.cpp
#	src/window.cpp
This commit is contained in:
Jonathan G Rennison
2019-01-14 00:01:44 +00:00
147 changed files with 1026 additions and 330 deletions

View File

@@ -33,6 +33,7 @@
#include "../map_type.h"
#include "../newgrf.h"
#include "../error.h"
#include "../guitimer_func.h"
#include "../widgets/network_widget.h"
@@ -236,6 +237,7 @@ protected:
Scrollbar *vscroll; ///< vertical scrollbar of the list of servers
QueryString name_editbox; ///< Client name editbox.
QueryString filter_editbox; ///< Editbox for filter on servers
GUITimer requery_timer; ///< Timer for network requery
int lock_offset; ///< Left offset for lock icon.
int blot_offset; ///< Left offset for green/yellow/red compatibility icon.
@@ -482,6 +484,8 @@ public:
this->server = this->last_joined;
if (this->last_joined != NULL) NetworkUDPQueryServer(this->last_joined->address);
this->requery_timer.SetInterval(MILLISECONDS_PER_TICK);
this->servers.SetListing(this->last_sorting);
this->servers.SetSortFuncs(this->sorter_funcs);
this->servers.SetFilterFuncs(this->filter_funcs);
@@ -905,8 +909,11 @@ public:
this->vscroll->SetCapacityFromWidget(this, WID_NG_MATRIX);
}
virtual void OnTick()
virtual void OnRealtimeTick(uint delta_ms)
{
if (!this->requery_timer.Elapsed(delta_ms)) return;
this->requery_timer.SetInterval(MILLISECONDS_PER_TICK);
NetworkGameListRequery();
}
};