UniRegensburg / unsere-app-fur-die-universitat-regensburg-bib-buddy

Bib Buddy - deine App für eine konzentrierte, offene Literaturarbeit!
0 stars 0 forks source link

Back button clears fragment #140

Closed LuisMossburger closed 3 years ago

LuisMossburger commented 3 years ago

I have noticed that the back button "clears" the fragment (hides all elements in it). If back is pressed one more time, the app crashed and the following stack trace is printed. I guess this is due to the recent rework of the back button in #123

E/AndroidRuntime: at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at de.bibbuddy.HomeFragment$1.handleOnBackPressed(HomeFragment.java:26) at androidx.activity.OnBackPressedDispatcher.onBackPressed(OnBackPressedDispatcher.java:192) at androidx.activity.ComponentActivity.onBackPressed(ComponentActivity.java:539) at android.app.Activity.onKeyUp(Activity.java:3784) at android.view.KeyEvent.dispatch(KeyEvent.java:2866) at android.app.Activity.dispatchKeyEvent(Activity.java:4090) at androidx.core.app.ComponentActivity.superDispatchKeyEvent(ComponentActivity.java:122) at androidx.core.view.KeyEventDispatcher.dispatchKeyEvent(KeyEventDispatcher.java:84) at androidx.core.app.ComponentActivity.dispatchKeyEvent(ComponentActivity.java:140) at androidx.appcompat.app.AppCompatActivity.dispatchKeyEvent(AppCompatActivity.java:569) at androidx.appcompat.view.WindowCallbackWrapper.dispatchKeyEvent(WindowCallbackWrapper.java:59) at androidx.appcompat.app.AppCompatDelegateImpl$AppCompatWindowCallback.dispatchKeyEvent(AppCompatDelegateImpl.java:3054) at androidx.appcompat.view.WindowCallbackWrapper.dispatchKeyEvent(WindowCallbackWrapper.java:59) at com.android.internal.policy.DecorView.dispatchKeyEvent(DecorView.java:390) at android.view.ViewRootImpl$ViewPostImeInputStage.processKeyEvent(ViewRootImpl.java:5947) at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:5815) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:5310) at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:5367) at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:5333) at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:5485) at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:5341) at android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:5542) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:5314) at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:5367) at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:5333) at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:5341) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:5314) at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:5367) at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:5333) at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:5518) at android.view.ViewRootImpl$ImeInputStage.onFinishedInputEvent(ViewRootImpl.java:5676) at android.view.inputmethod.InputMethodManager$PendingEvent.run(InputMethodManager.java:3179) at android.view.inputmethod.InputMethodManager.invokeFinishedInputEventCallback(InputMethodManager.java:2721) at android.view.inputmethod.InputMethodManager.finishedInputEvent(InputMethodManager.java:2712) at android.view.inputmethod.InputMethodManager$ImeInputEventSender.onInputEventFinished(InputMethodManager.java:3156) at android.view.InputEventSender.dispatchInputEventFinished(InputEventSender.java:143) at android.os.MessageQueue.nativePollOnce(Native Method) at android.os.MessageQueue.next(MessageQueue.java:335) at android.os.Looper.loop(Looper.java:183) at android.app.ActivityThread.main(ActivityThread.java:7656) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)

LuisMossburger commented 3 years ago

Discussed in team meeting: @SarahKurek will have another look at this.