Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit82451db

Browse files
Close bar without animation
1 parent5fc403e commit82451db

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

‎internal_filesystem/lib/mpos/ui/topmenu.py‎

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ def close_drawer(to_launcher=False):
4444
drawer_open=False
4545
ifnotto_launcherandnotmpos.apps.is_launcher(mpos.ui.foreground_app_name):
4646
print(f"close_drawer: also closing bar because to_launcher is{to_launcher} and foreground_app_name is{mpos.ui.foreground_app_name}")
47-
close_bar()
47+
close_bar(False)
4848
WidgetAnimator.hide_widget(drawer,anim_type="slide_up",duration=1000,delay=0)
4949

5050
defopen_bar():
@@ -58,12 +58,15 @@ def open_bar():
5858
else:
5959
print("bar already open")
6060

61-
defclose_bar():
61+
defclose_bar(animate=True):
6262
globalbar_open,show_bar_animation,hide_bar_animation
6363
ifbar_open:
6464
bar_open=False
6565
show_bar_animation.current_value=show_bar_animation_end_value
66-
hide_bar_animation.start()
66+
ifanimate:
67+
hide_bar_animation.start()
68+
else:
69+
notification_bar.set_y(hide_bar_animation_end_value)
6770

6871

6972

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp