Page Menu
Home
Wildfire Games
Search
Configure Global Search
Log In
Differential
D2734
Diff 12364
binaries/data/mods/public/gui/reference/common/common.js
Changeset View
If following JS GUI class rewrite consequently, tooltips.js file would become some Tooltip class too.
Then the callers to these two functions could become this.templateLoader.GetTemplateData and this.templateLoader.TechnologyTemplateExists.
(Once the two functions have left global scope, there are only two globals variables remaining here.
If all globals are defined in the first file the page opens, then there won't be hidden surprise globals for the reader.
The danger is that the file will contain more new procedural code as long as it exists.
For those two reasons, this file should be removed (similar pattern with general "common" GUI code that actually is very specific most often))