Merge "Fix SmartForwardingActivity crash at screen rotation" into main

This commit is contained in:
SongFerng Wang
2024-07-19 05:41:40 +00:00
committed by Gerrit Code Review

View File

@@ -48,8 +48,7 @@ public class SmartForwardingFragment extends PreferenceFragmentCompat
public void onCreatePreferences(Bundle savedInstanceState, String rootKey) {
setPreferencesFromResource(R.xml.smart_forwarding_switch, rootKey);
String title = getResources().getString(R.string.smart_forwarding_title);
getActivity().getActionBar().setTitle(title);
getActivity().setTitle(R.string.smart_forwarding_title);
TwoStatePreference smartForwardingSwitch = findPreference(KEY_SMART_FORWARDING_SWITCH);
if (turnOffSwitch) {