Added logging

This commit is contained in:
M66B 2019-09-20 08:39:31 +02:00
parent 9c64ac20f0
commit 6e804cbc0b
1 changed files with 3 additions and 0 deletions

View File

@ -35,10 +35,12 @@ public class PopupMenuLifecycle extends PopupMenu implements LifecycleObserver {
public PopupMenuLifecycle(@NonNull Context context, LifecycleOwner owner, @NonNull View anchor) {
super(context, anchor);
this.owner = owner;
Log.i("Instantiate " + this);
}
@Override
public void show() {
Log.i("Show " + this);
try {
super.show();
} catch (Throwable ex) {
@ -48,6 +50,7 @@ public class PopupMenuLifecycle extends PopupMenu implements LifecycleObserver {
@OnLifecycleEvent(Lifecycle.Event.ON_DESTROY)
public void onDestroy() {
Log.i("Destroy " + this);
this.dismiss();
owner = null;
}