Skip to content

Commit 53d0968

Browse files
committed
v1.7.54
1 parent b118102 commit 53d0968

File tree

6 files changed

+65
-65
lines changed

6 files changed

+65
-65
lines changed

.efrocachemap

Lines changed: 33 additions & 33 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
### 1.7.54 (build 22632, api 9, 2025-11-19)
1+
### 1.7.54 (build 22633, api 9, 2025-11-19)
22
- `scrollwidget` and `hscrollwidget` now center selected items that are too
33
large to fit completely in view instead of unpredictably scrolling to the
44
beginning or end of them. This makes show-buffer values (which effectively

src/assets/ba_data/python/baenv.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656

5757
# Build number and version of the ballistica binary we expect to be
5858
# using.
59-
TARGET_BALLISTICA_BUILD = 22632
59+
TARGET_BALLISTICA_BUILD = 22633
6060
TARGET_BALLISTICA_VERSION = '1.7.54'
6161

6262

src/assets/ba_data/python/bauiv1lib/inventory.py

Lines changed: 15 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,9 @@ def restore_window_shared_state(
146146
if not isinstance(window.request, dui1.Request):
147147
return
148148

149+
# If desired, set the profile button that will be selected in
150+
# the new window. We do this when coming back from creating a
151+
# new profile/etc.
149152
if (
150153
window.request.path == '/'
151154
and self._next_selected_profile is not None
@@ -157,20 +160,14 @@ def restore_window_shared_state(
157160
self._next_selected_profile = None
158161

159162
def _on_profile_save(self, name: str) -> None:
163+
# An editor we launched tells us it saved a profile.
164+
160165
# Have this one selected when we go back to the listing.
161166
self._next_selected_profile = name
162167
bui.pushcall(self._notify_profiles_changed)
163168

164-
def _notify_profiles_changed(self) -> None:
165-
import bascenev1 as bs
166-
167-
# If there's a team-chooser in existence, tell it the profile-list
168-
# has probably changed.
169-
session = bs.get_foreground_host_session()
170-
if session is not None:
171-
session.handlemessage(bs.PlayerProfilesChangedMessage())
172-
173169
def _on_profile_delete(self, name: str) -> None:
170+
# An editor we launched tells us it deleted a profile.
174171

175172
# Ask the inventory list to select/show the profile right before
176173
# the one we're deleting.
@@ -192,6 +189,15 @@ def _on_profile_delete(self, name: str) -> None:
192189

193190
self._notify_profiles_changed()
194191

192+
def _notify_profiles_changed(self) -> None:
193+
import bascenev1 as bs
194+
195+
# If there's a team-chooser in existence, tell it the profile-list
196+
# has probably changed.
197+
session = bs.get_foreground_host_session()
198+
if session is not None:
199+
session.handlemessage(bs.PlayerProfilesChangedMessage())
200+
195201
def _get_profile_buttons(self) -> list[dui1.Button]:
196202
# pylint: disable=too-many-locals
197203

@@ -275,10 +281,6 @@ def _new_profile(self, action: DocUILocalAction) -> None:
275281

276282
bui.getsound('swish').play()
277283

278-
# No-op if we're not the in-control main window.
279-
if not action.window.main_window_has_control():
280-
return
281-
282284
plus = bui.app.plus
283285
assert plus is not None
284286

@@ -312,10 +314,6 @@ def _edit_profile(self, action: DocUILocalAction) -> None:
312314

313315
bui.getsound('swish').play()
314316

315-
# No-op if we're not in control.
316-
if not action.window.main_window_has_control():
317-
return
318-
319317
profile = action.args.get('profile')
320318
assert isinstance(profile, str)
321319

src/assets/ba_data/python/bauiv1lib/profile/edit.py

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,6 @@ class EditProfileWindow(
2424
):
2525
"""Window for editing a player profile."""
2626

27-
def reload_window(self) -> None:
28-
"""Transitions out and recreates ourself."""
29-
30-
# Replace ourself with ourself, but keep the same back location.
31-
assert self.main_window_back_state is not None
32-
self.main_window_replace(
33-
lambda: EditProfileWindow(self.getname()),
34-
back_state=self.main_window_back_state,
35-
)
36-
3727
def __init__(
3828
self,
3929
existing_profile: str | None,
@@ -43,13 +33,11 @@ def __init__(
4333
on_profile_save: Callable[[str], None] | None = None,
4434
on_profile_delete: Callable[[str], None] | None = None,
4535
):
46-
# FIXME: Tidy this up a bit.
4736
# pylint: disable=too-many-branches
4837
# pylint: disable=too-many-statements
4938
# pylint: disable=too-many-locals
5039

5140
assert bui.app.classic is not None
52-
# print(f'EditProfileWindow({id(self)})')
5341

5442
plus = bui.app.plus
5543
assert plus is not None
@@ -547,6 +535,16 @@ def __init__(
547535

548536
self._update_character()
549537

538+
def reload_window(self) -> None:
539+
"""Transitions out and recreates ourself."""
540+
541+
# Replace ourself with ourself, but keep the same back location.
542+
assert self.main_window_back_state is not None
543+
self.main_window_replace(
544+
lambda: EditProfileWindow(self.getname()),
545+
back_state=self.main_window_back_state,
546+
)
547+
550548
def _delete_press(self) -> None:
551549
# pylint: disable=cyclic-import
552550
from bauiv1lib.confirm import ConfirmWindow
@@ -604,13 +602,17 @@ def get_main_window_state(self) -> bui.MainWindowState:
604602

605603
# Pull things out of self here; if we do it within the lambda
606604
# we'll keep ourself alive which is bad.
605+
on_profile_save = self._on_profile_save
606+
on_profile_delete = self._on_profile_delete
607607

608608
existing_profile = self._existing_profile
609609
return bui.BasicMainWindowState(
610610
create_call=lambda transition, origin_widget: cls(
611611
transition=transition,
612612
origin_widget=origin_widget,
613613
existing_profile=existing_profile,
614+
on_profile_save=on_profile_save,
615+
on_profile_delete=on_profile_delete,
614616
)
615617
)
616618

src/ballistica/shared/ballistica.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ auto main(int argc, char** argv) -> int {
4444
namespace ballistica {
4545

4646
// These are set automatically via script; don't modify them here.
47-
const int kEngineBuildNumber = 22632;
47+
const int kEngineBuildNumber = 22633;
4848
const char* kEngineVersion = "1.7.54";
4949
const int kEngineApiVersion = 9;
5050

0 commit comments

Comments
 (0)