tidying and modernization pass on serverdialog

This commit is contained in:
Eric 2022-09-06 07:54:29 -07:00
parent b5f52d37de
commit fb4975bb10
No known key found for this signature in database
GPG Key ID: 89C93F0F8D6D5A98
7 changed files with 109 additions and 87 deletions

View File

@ -3995,50 +3995,50 @@
"assets/src/ba_data/python/ba/_generated/__init__.py": "https://files.ballistica.net/cache/ba1/ee/e8/cad05aa531c7faf7ff7b96db7f6e",
"assets/src/ba_data/python/ba/_generated/enums.py": "https://files.ballistica.net/cache/ba1/b2/e5/0ee0561e16257a32830645239f34",
"ballisticacore-windows/Generic/BallisticaCore.ico": "https://files.ballistica.net/cache/ba1/89/c0/e32c7d2a35dc9aef57cc73b0911a",
"build/prefab/full/linux_arm64_gui/debug/ballisticacore": "https://files.ballistica.net/cache/ba1/06/3e/28bf1a2f2c8ff9d60dc9009afd43",
"build/prefab/full/linux_arm64_gui/release/ballisticacore": "https://files.ballistica.net/cache/ba1/32/6b/12db67765516b0205816b41db4b8",
"build/prefab/full/linux_arm64_server/debug/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/57/1e/0ba38a08a2ba605e4589c6422bc1",
"build/prefab/full/linux_arm64_server/release/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/0a/29/2965569534dfb27d9736be40a8ca",
"build/prefab/full/linux_x86_64_gui/debug/ballisticacore": "https://files.ballistica.net/cache/ba1/38/ab/f754bc432bfa15093d2d6c953c12",
"build/prefab/full/linux_x86_64_gui/release/ballisticacore": "https://files.ballistica.net/cache/ba1/77/22/b49336253e7c20018aabfcbbda41",
"build/prefab/full/linux_x86_64_server/debug/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/98/0f/6a0c5560b55ca824fd25cf6b356b",
"build/prefab/full/linux_x86_64_server/release/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/9f/91/15b00e3fce05b0f10ea5af3d5ee2",
"build/prefab/full/mac_arm64_gui/debug/ballisticacore": "https://files.ballistica.net/cache/ba1/12/d7/c074bdd761d329d75b1042d5167b",
"build/prefab/full/mac_arm64_gui/release/ballisticacore": "https://files.ballistica.net/cache/ba1/51/eb/1f61c50a9ebc93e0f856bbe1ef5e",
"build/prefab/full/mac_arm64_server/debug/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/62/f3/5d29f0c2f554ae5205d76cdb283e",
"build/prefab/full/mac_arm64_server/release/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/d2/90/0375524fe5f78555b9ff12b2601b",
"build/prefab/full/mac_x86_64_gui/debug/ballisticacore": "https://files.ballistica.net/cache/ba1/2b/cc/b45a0dcdda43cf719b6fd644c4c4",
"build/prefab/full/mac_x86_64_gui/release/ballisticacore": "https://files.ballistica.net/cache/ba1/69/1c/10f4427b746cb6a2545290aa1f99",
"build/prefab/full/mac_x86_64_server/debug/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/98/6e/65f75aeb62bdd6c897d163299c46",
"build/prefab/full/mac_x86_64_server/release/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/0f/d0/ff714a43170a2c422d65b0533dca",
"build/prefab/full/windows_x86_gui/debug/BallisticaCore.exe": "https://files.ballistica.net/cache/ba1/40/d8/af1c5a8f4f2960596475ee11bbdd",
"build/prefab/full/windows_x86_gui/release/BallisticaCore.exe": "https://files.ballistica.net/cache/ba1/33/73/7b039824562b5160fa03efdd1cc3",
"build/prefab/full/windows_x86_server/debug/dist/BallisticaCoreHeadless.exe": "https://files.ballistica.net/cache/ba1/e4/dc/9bbf05c098bdc64a9b90f2580cdc",
"build/prefab/full/windows_x86_server/release/dist/BallisticaCoreHeadless.exe": "https://files.ballistica.net/cache/ba1/da/5e/91e6217194f56e7782bf7654af88",
"build/prefab/lib/linux_arm64_gui/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/14/ee/113076d5d2e088cc90230cf6ab51",
"build/prefab/lib/linux_arm64_gui/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/7e/e4/38a2a67908a08aa068c4927d3122",
"build/prefab/lib/linux_arm64_server/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/75/fd/6250319a816a7b312051bfc2a63f",
"build/prefab/lib/linux_arm64_server/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/e4/32/1b30542405d53f85a1eed025be9d",
"build/prefab/lib/linux_x86_64_gui/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/37/80/ce8008d84820ef0d0ca8960965c4",
"build/prefab/lib/linux_x86_64_gui/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/2e/09/a78c65202f7d1fc0fbb4d83933c3",
"build/prefab/lib/linux_x86_64_server/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/0d/04/dba2a6ac9f1817603fccf3a5542b",
"build/prefab/lib/linux_x86_64_server/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/20/c6/4a99477e51ef8b70db429af3719e",
"build/prefab/lib/mac_arm64_gui/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/34/24/18ef1ad96d0f203409b60424d9d0",
"build/prefab/lib/mac_arm64_gui/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/6e/83/0c5492eff9fa8ce9bafb8e39a561",
"build/prefab/lib/mac_arm64_server/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/ab/1e/ccd89ecb93c13c4ca7c6c6a3797e",
"build/prefab/lib/mac_arm64_server/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/16/e7/461b11e11e2026b559bfaf7c3941",
"build/prefab/lib/mac_x86_64_gui/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/e1/93/519f4f309f0f4fa8752114b70a64",
"build/prefab/lib/mac_x86_64_gui/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/dd/d1/187a739cbbe0316fd809708fa9ee",
"build/prefab/lib/mac_x86_64_server/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/19/38/7a480d58b0ade7b5705f2f9474ee",
"build/prefab/lib/mac_x86_64_server/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/e2/4b/524bed0bfca1b06a324163728fe1",
"build/prefab/lib/windows/Debug_Win32/BallisticaCoreGenericInternal.lib": "https://files.ballistica.net/cache/ba1/a6/36/5eacae1d7477be84c255960e1a10",
"build/prefab/lib/windows/Debug_Win32/BallisticaCoreGenericInternal.pdb": "https://files.ballistica.net/cache/ba1/9c/0f/9e9a95622f7ca0ec6315346517a5",
"build/prefab/lib/windows/Debug_Win32/BallisticaCoreHeadlessInternal.lib": "https://files.ballistica.net/cache/ba1/ba/f6/ae4469f1b89aed5aca7b05711fb9",
"build/prefab/lib/windows/Debug_Win32/BallisticaCoreHeadlessInternal.pdb": "https://files.ballistica.net/cache/ba1/97/6f/c3ce83c00b3f1e74f26878756d89",
"build/prefab/lib/windows/Release_Win32/BallisticaCoreGenericInternal.lib": "https://files.ballistica.net/cache/ba1/6f/57/3e0af371b5fefb1a625a37b42f0d",
"build/prefab/lib/windows/Release_Win32/BallisticaCoreGenericInternal.pdb": "https://files.ballistica.net/cache/ba1/ae/ad/375e1add60a59f6ca1a94fcea1ef",
"build/prefab/lib/windows/Release_Win32/BallisticaCoreHeadlessInternal.lib": "https://files.ballistica.net/cache/ba1/d4/03/4a9df83e96f11f2315e3ee0af9bd",
"build/prefab/lib/windows/Release_Win32/BallisticaCoreHeadlessInternal.pdb": "https://files.ballistica.net/cache/ba1/e3/11/d0e5057f133014b787866b6d6f0f",
"build/prefab/full/linux_arm64_gui/debug/ballisticacore": "https://files.ballistica.net/cache/ba1/6a/31/abdfef298b17ac40d0d7ba7b9b2c",
"build/prefab/full/linux_arm64_gui/release/ballisticacore": "https://files.ballistica.net/cache/ba1/46/1c/9e9b9785377d915aa46a33125fac",
"build/prefab/full/linux_arm64_server/debug/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/dc/fb/784613192b8674fab9dc25d65c35",
"build/prefab/full/linux_arm64_server/release/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/34/87/9f984d7668fb12dec1f5be606e35",
"build/prefab/full/linux_x86_64_gui/debug/ballisticacore": "https://files.ballistica.net/cache/ba1/f4/93/71328611c9d000fd9c38a7ac2d4e",
"build/prefab/full/linux_x86_64_gui/release/ballisticacore": "https://files.ballistica.net/cache/ba1/c3/b7/3c004ace11368dcd9cafe48b125e",
"build/prefab/full/linux_x86_64_server/debug/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/1a/4b/92422f6a9bdd3ebe5d71d404b0e8",
"build/prefab/full/linux_x86_64_server/release/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/29/a9/2ee957413b1add9b674716000249",
"build/prefab/full/mac_arm64_gui/debug/ballisticacore": "https://files.ballistica.net/cache/ba1/c5/77/60f9affdc1cbaa47a6129fe1e103",
"build/prefab/full/mac_arm64_gui/release/ballisticacore": "https://files.ballistica.net/cache/ba1/a0/96/94f6f60acb5167bf8905ed7ca2ff",
"build/prefab/full/mac_arm64_server/debug/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/4c/d8/d9e113fdfd32edc5da247eefbe8a",
"build/prefab/full/mac_arm64_server/release/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/0a/13/a9a9461fe5d7a52465e2c09d678b",
"build/prefab/full/mac_x86_64_gui/debug/ballisticacore": "https://files.ballistica.net/cache/ba1/e0/33/dad6527ec715fe96b040dfaccb4e",
"build/prefab/full/mac_x86_64_gui/release/ballisticacore": "https://files.ballistica.net/cache/ba1/cd/e5/9727f9aa21af0fdaa363dbcf1355",
"build/prefab/full/mac_x86_64_server/debug/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/44/94/b3ddae52b264cd093f44d628e2d2",
"build/prefab/full/mac_x86_64_server/release/dist/ballisticacore_headless": "https://files.ballistica.net/cache/ba1/33/61/820cd8d5ee9025c7da32292c677b",
"build/prefab/full/windows_x86_gui/debug/BallisticaCore.exe": "https://files.ballistica.net/cache/ba1/34/42/bf6aa84314cf7244c23f882069dd",
"build/prefab/full/windows_x86_gui/release/BallisticaCore.exe": "https://files.ballistica.net/cache/ba1/6e/0f/45696af8c1d60889127d48bf651e",
"build/prefab/full/windows_x86_server/debug/dist/BallisticaCoreHeadless.exe": "https://files.ballistica.net/cache/ba1/36/2f/c4e3eb9139d428ccdb7b8b4a0355",
"build/prefab/full/windows_x86_server/release/dist/BallisticaCoreHeadless.exe": "https://files.ballistica.net/cache/ba1/76/d9/9bcd1ca394b799f1181516b27c58",
"build/prefab/lib/linux_arm64_gui/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/4f/62/10fba4712bc7c1649de95f6d435a",
"build/prefab/lib/linux_arm64_gui/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/7f/74/101f9c7cdbea3924a3eb753372b8",
"build/prefab/lib/linux_arm64_server/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/3d/10/0213350b34d61574be888f434776",
"build/prefab/lib/linux_arm64_server/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/2f/69/3195bc2ac8ab95a072deb6328383",
"build/prefab/lib/linux_x86_64_gui/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/fb/b8/1d53882382e1bdffea589b8abd52",
"build/prefab/lib/linux_x86_64_gui/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/66/7d/4cf7e08113052eae664b714bdc64",
"build/prefab/lib/linux_x86_64_server/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/0a/3e/0e759cd0a7a1e098e3c1daff0827",
"build/prefab/lib/linux_x86_64_server/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/8a/a0/eb48807010d1e7fa6a4956d0967e",
"build/prefab/lib/mac_arm64_gui/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/45/1b/cd3972f7bb9cb4a7d4bfeb0977fb",
"build/prefab/lib/mac_arm64_gui/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/b2/c1/92b3546f4ea454e3813062e7c2a0",
"build/prefab/lib/mac_arm64_server/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/d8/7f/694dfd1b8580077fd1d3ab585611",
"build/prefab/lib/mac_arm64_server/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/8c/ea/38c4415b9582016f40ecb9c371f6",
"build/prefab/lib/mac_x86_64_gui/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/2d/54/3f42d8cbbabb633fe47dc9e63f8b",
"build/prefab/lib/mac_x86_64_gui/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/e0/9c/78bc9f3658e495238a9ae7095ad0",
"build/prefab/lib/mac_x86_64_server/debug/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/3e/60/48c02923c5c7e7b8a3a705cdbe49",
"build/prefab/lib/mac_x86_64_server/release/libballisticacore_internal.a": "https://files.ballistica.net/cache/ba1/7b/cb/93116682d10e6f868ec9215c0ab2",
"build/prefab/lib/windows/Debug_Win32/BallisticaCoreGenericInternal.lib": "https://files.ballistica.net/cache/ba1/98/9b/43700428b53a552af3f32aa2577c",
"build/prefab/lib/windows/Debug_Win32/BallisticaCoreGenericInternal.pdb": "https://files.ballistica.net/cache/ba1/37/e2/b6da8c9dd13e91ebb705da51c653",
"build/prefab/lib/windows/Debug_Win32/BallisticaCoreHeadlessInternal.lib": "https://files.ballistica.net/cache/ba1/f5/93/774197e1f445c4dee88ed2910006",
"build/prefab/lib/windows/Debug_Win32/BallisticaCoreHeadlessInternal.pdb": "https://files.ballistica.net/cache/ba1/2e/7c/139654fe813f9254ed5de42c7ef7",
"build/prefab/lib/windows/Release_Win32/BallisticaCoreGenericInternal.lib": "https://files.ballistica.net/cache/ba1/ef/ea/8ccb18f593d003984a1f56cf0c78",
"build/prefab/lib/windows/Release_Win32/BallisticaCoreGenericInternal.pdb": "https://files.ballistica.net/cache/ba1/99/f6/7e56f9dd76d97493a53ebe755fba",
"build/prefab/lib/windows/Release_Win32/BallisticaCoreHeadlessInternal.lib": "https://files.ballistica.net/cache/ba1/cf/d5/2d58578076ced4f6e2b218b18d11",
"build/prefab/lib/windows/Release_Win32/BallisticaCoreHeadlessInternal.pdb": "https://files.ballistica.net/cache/ba1/a2/07/d85112deb0bf08aa01d18f098b94",
"src/ballistica/generated/python_embedded/binding.inc": "https://files.ballistica.net/cache/ba1/7d/3e/229a581cb2454ed856f1d8b564a7",
"src/ballistica/generated/python_embedded/bootstrap.inc": "https://files.ballistica.net/cache/ba1/98/12/571b2160d69d42580e8f31fa6a8d"
}

View File

@ -2216,6 +2216,7 @@
<w>scutil</w>
<w>scyn</w>
<w>sdata</w>
<w>sddata</w>
<w>sdkcheck</w>
<w>sdkutils</w>
<w>sdtk</w>

View File

@ -1,4 +1,4 @@
### 1.7.7 (build 20772, api 7, 2022-09-05)
### 1.7.7 (build 20774, api 7, 2022-09-06)
- Added `ba.app.meta.load_exported_classes()` for loading classes discovered by the meta subsystem cleanly in a background thread.
- Improved logging of missing playlist game types.
- Some ba.Lstr functionality can now be used in background threads.

View File

@ -32,7 +32,7 @@ def bootstrap() -> None:
# Give a soft warning if we're being used with a different binary
# version than we expect.
expected_build = 20772
expected_build = 20774
running_build: int = env['build_number']
if running_build != expected_build:
print(

View File

@ -4,22 +4,38 @@
from __future__ import annotations
from typing import TYPE_CHECKING
import logging
from dataclasses import dataclass, field
from typing import TYPE_CHECKING, Annotated
from efro.dataclassio import ioprepped, IOAttrs
import ba
import ba.internal
if TYPE_CHECKING:
from typing import Any
pass
@ioprepped
@dataclass
class ServerDialogData:
"""Data for ServerDialog."""
dialog_id: Annotated[str, IOAttrs('dialogID')]
text: Annotated[str, IOAttrs('text')]
subs: Annotated[list[tuple[str, str]],
IOAttrs('subs')] = field(default_factory=list)
show_cancel: Annotated[bool, IOAttrs('showCancel')] = True
copy_text: Annotated[str | None, IOAttrs('copyText')] = None
class ServerDialogWindow(ba.Window):
"""A dialog window driven by the master-server."""
def __init__(self, data: dict[str, Any]):
self._dialog_id = data['dialogID']
txt = ba.Lstr(translate=('serverResponses', data['text']),
subs=data.get('subs', [])).evaluate()
def __init__(self, data: ServerDialogData):
self._data = data
txt = ba.Lstr(translate=('serverResponses', data.text),
subs=data.subs).evaluate()
txt = txt.strip()
txt_scale = 1.5
txt_height = (
@ -33,7 +49,7 @@ class ServerDialogWindow(ba.Window):
transition='in_scale',
scale=(1.8 if uiscale is ba.UIScale.SMALL else
1.35 if uiscale is ba.UIScale.MEDIUM else 1.0)))
self._starttime = ba.time(ba.TimeType.REAL, ba.TimeFormat.MILLISECONDS)
self._starttime = ba.time(ba.TimeType.REAL)
ba.playsound(ba.getsound('swish'))
ba.textwidget(parent=self._root_widget,
@ -47,68 +63,72 @@ class ServerDialogWindow(ba.Window):
text=txt,
maxwidth=self._width * 0.85,
max_height=(self._height - 110))
show_cancel = data.get('showCancel', True)
self.copy_text = data.get('copyText', None)
self._cancel_button: ba.Widget | None
self._copy_button: ba.Widget | None
if show_cancel:
self._cancel_button = ba.buttonwidget(
parent=self._root_widget,
position=(30, 30),
size=(160, 60),
autoselect=True,
label=ba.Lstr(resource='cancelText'),
on_activate_call=self._cancel_press)
elif self.copy_text is not None:
self._cancel_button = None
self._copy_button = ba.buttonwidget(
parent=self._root_widget,
position=(30, 30),
size=(160, 60),
autoselect=True,
label=ba.Lstr(resource='copyText'),
on_activate_call=self._copy_press)
else:
self._cancel_button = None
self._copy_button = None
show_copy = data.copy_text is not None and ba.clipboard_is_supported()
# Currently can't do both copy and cancel since they go in the same
# spot. Cancel wins in this case since it is important functionality
# and copy is just for convenience (and not even always available).
if show_copy and data.show_cancel:
logging.warning('serverdialog requesting both copy and cancel;'
' copy will not be shown.')
show_copy = False
self._cancel_button = (None
if not data.show_cancel else ba.buttonwidget(
parent=self._root_widget,
position=(30, 30),
size=(160, 60),
autoselect=True,
label=ba.Lstr(resource='cancelText'),
on_activate_call=self._cancel_press))
self._copy_button = None if not show_copy else ba.buttonwidget(
parent=self._root_widget,
position=(30, 30),
size=(160, 60),
autoselect=True,
label=ba.Lstr(resource='copyText'),
on_activate_call=self._copy_press)
self._ok_button = ba.buttonwidget(
parent=self._root_widget,
position=((self._width - 182) if show_cancel else
(self._width - 182) if self.copy_text is not None else
position=((self._width - 182) if data.show_cancel else
(self._width - 182) if data.copy_text is not None else
(self._width * 0.5 - 80), 30),
size=(160, 60),
autoselect=True,
label=ba.Lstr(resource='okText'),
on_activate_call=self._ok_press)
ba.containerwidget(edit=self._root_widget,
cancel_button=self._cancel_button,
start_button=self._ok_button,
selected_child=self._ok_button)
def _copy_press(self) -> None:
ba.clipboard_set_text(self.copy_text)
assert self._data.copy_text is not None
ba.clipboard_set_text(self._data.copy_text)
ba.screenmessage(ba.Lstr(resource='copyConfirmText'), color=(0, 1, 0))
def _ok_press(self) -> None:
if ba.time(ba.TimeType.REAL,
ba.TimeFormat.MILLISECONDS) - self._starttime < 1000:
if ba.time(ba.TimeType.REAL) - self._starttime < 1.0:
ba.playsound(ba.getsound('error'))
return
ba.internal.add_transaction({
'type': 'DIALOG_RESPONSE',
'dialogID': self._dialog_id,
'dialogID': self._data.dialog_id,
'response': 1
})
ba.containerwidget(edit=self._root_widget, transition='out_scale')
def _cancel_press(self) -> None:
if ba.time(ba.TimeType.REAL,
ba.TimeFormat.MILLISECONDS) - self._starttime < 1000:
if ba.time(ba.TimeType.REAL) - self._starttime < 1.0:
ba.playsound(ba.getsound('error'))
return
ba.internal.add_transaction({
'type': 'DIALOG_RESPONSE',
'dialogID': self._dialog_id,
'dialogID': self._data.dialog_id,
'response': 0
})
ba.containerwidget(edit=self._root_widget, transition='out_scale')

View File

@ -1143,6 +1143,7 @@
<w>screenmessage</w>
<w>scrollwidget</w>
<w>scutil</w>
<w>sddata</w>
<w>sdkcheck</w>
<w>sdl's</w>
<w>sdlk</w>

View File

@ -22,7 +22,7 @@
namespace ballistica {
// These are set automatically via script; don't modify them here.
const int kAppBuildNumber = 20772;
const int kAppBuildNumber = 20774;
const char* kAppVersion = "1.7.7";
// Our standalone globals.