Commit graph

10 commits

Author SHA1 Message Date
elexis
86c151ebaa PushGuiPage support for passing a function instead of a function name.
Allows coding the GUI without global functions which break
prototype-oriented coding, refs #5322, fixing the concern in 4b1297b328.

Supports stacked message boxes and removes the according workaround.
Change structree / civinfo switch-dialog code from 760a47335d to perform
the callback for page that actually registered the callback.
Ensure the parent that the callbackhandler is always called if the page
is closed.
Merge PopGuiPage and PopGuiPageCB following that choice, incidentally
leaving cleaner code.

Differential Revision: https://code.wildfiregames.com/D1684
Comments by: Yves, Vladislav, wraitii, leper
This was SVN commit r22676.
2019-08-16 18:46:04 +00:00
elexis
e370c509a6 Small closePage() cleanup for D1684.
Rename close() to closePage() for structree / template viewer / civ info
for global consistency.
Remove a splashscreen proxy and move splashscreen closing from XML to
closePage() in JS.

This was SVN commit r22669.
2019-08-15 13:29:11 +00:00
s0600204
760a47335d Add buttons for changing between, and hotkeys for opening, the civinfo and structree
Patch by: fpre
Reviewed By: s0600204
Fixes: #4970
Differential Revision: https://code.wildfiregames.com/D846
This was SVN commit r21339.
2018-02-23 20:54:28 +00:00
s0600204
9501292661 Merge the structree's loadUnit and loadStructure functions
The resultant function should be able to handle any (selectable) entity
template.

This was SVN commit r21174.
2018-02-11 04:09:28 +00:00
elexis
c53adeaaa6 Unify structree production queue loading duplication.
Differential Revision: https://code.wildfiregames.com/D1192
Reviewed By: s0600204
This was SVN commit r21022.
2018-01-26 22:18:35 +00:00
s0600204
f6b5488a24 Move unravelPhases function from structree to globalscripts for use in AI init.
Reviewed By: mimo
Differential Revision: https://code.wildfiregames.com/D1183
This was SVN commit r20750.
2018-01-02 06:38:09 +00:00
s0600204
00b05fd9f7 Use phase techs to determine phase order in structure tree.
(Instead of non-phase techs which is what it was using up to now.)


Reviewed/accepted by: mimo
Changes agreed (but not tested/formally proven) by: elexis

Differential Revision: https://code.wildfiregames.com/D1181
This was SVN commit r20749.
2018-01-02 06:23:33 +00:00
elexis
b5ea27904d JS GUI cleanup.
Mark g_CivData as const and don't use optional arguments at loadCivData.
Translate the infinity symbol in the summary screen.

Refs D829
Reviewed By: s0600204
This was SVN commit r20043.
2017-08-26 18:53:37 +00:00
elexis
c4cef0d289 Don't write two helper variables to g_CivInfo in the structure tree,
so that the object has the same content throughout the entire GUI and
can be marked read-only.

Refs D829
Reviewed by: s0600204
This was SVN commit r20042.
2017-08-26 17:57:11 +00:00
s0600204
cdf6109713 Relocate and Rearrange the structree codebase
Makes it possible to reuse the more generic parts of the `structree`
codebase in other pages without including `structree`-specific logic.
This sets the stage for further reference/encyclopedia-type pages.

Reviewed By: fatherbushido, elexis
Differential Revision: https://code.wildfiregames.com/D295
This was SVN commit r19940.
2017-07-31 12:49:00 +00:00