Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 224577df authored by Mady Mellor's avatar Mady Mellor
Browse files

Protect against null expanded bubble & hide header for notifications

Test: manual - dismiss an activity view based bubble
             - look at expanded notif based bubble
Change-Id: Ie3db725d6fac522ea0f8cc50612404cca3b7afca
parent fb922e9b
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -21,6 +21,7 @@ import android.content.Context;
import android.content.res.Resources;
import android.graphics.Color;
import android.graphics.drawable.ShapeDrawable;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.view.View;
import android.widget.LinearLayout;
@@ -88,6 +89,7 @@ public class BubbleExpandedViewContainer extends LinearLayout {
     */
    public void setHeaderText(CharSequence text) {
        mHeaderView.setText(text);
        mHeaderView.setVisibility(TextUtils.isEmpty(text) ? GONE : VISIBLE);
    }

    /**
+2 −1
Original line number Diff line number Diff line
@@ -417,7 +417,8 @@ public class BubbleStackView extends FrameLayout implements BubbleTouchHandler.F

                @Override
                public void onActivityViewDestroyed(ActivityView view) {
                    NotificationEntry entry = mExpandedBubble.getEntry();
                    NotificationEntry entry = mExpandedBubble != null
                            ? mExpandedBubble.getEntry() : null;
                    Log.d(TAG, "onActivityViewDestroyed(key="
                            + ((entry != null) ? entry.key : "(none)") + "): " + view);
                }