Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
format
  • Loading branch information
Gray Mackall committed Dec 3, 2024
commit 3441a808a5ee3c6d068d392b5b74a2f9d8e8d3b0
Original file line number Diff line number Diff line change
Expand Up @@ -635,7 +635,9 @@ protected void onCreate(@Nullable Bundle savedInstanceState) {
super.onCreate(savedInstanceState);

if (savedInstanceState != null) {
boolean frameworkHandlesBack = savedInstanceState.getBoolean(FlutterActivityAndFragmentDelegate.ON_BACK_CALLBACK_ENABLED_KEY);
boolean frameworkHandlesBack =
savedInstanceState.getBoolean(
FlutterActivityAndFragmentDelegate.ON_BACK_CALLBACK_ENABLED_KEY);
setFrameworkHandlesBack(frameworkHandlesBack);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1073,7 +1073,9 @@ public void onAttach(@NonNull Context context) {
public void onCreate(@Nullable Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
if (savedInstanceState != null) {
boolean frameworkHandlesBack = savedInstanceState.getBoolean(FlutterActivityAndFragmentDelegate.ON_BACK_CALLBACK_ENABLED_KEY);
boolean frameworkHandlesBack =
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to change the pr now but when we have a second variable then all of this code should go into a "save everything" and "restore everything" methods.

savedInstanceState.getBoolean(
FlutterActivityAndFragmentDelegate.ON_BACK_CALLBACK_ENABLED_KEY);
onBackPressedCallback.setEnabled(frameworkHandlesBack);
}
delegate.onRestoreInstanceState(savedInstanceState);
Expand Down
Loading