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

Commit 1243b967 authored by Chris Wren's avatar Chris Wren Committed by Android (Google) Code Review
Browse files

Merge "rework big text to handle gmail use case" into jb-dev

parents 71964645 e4a2a4f1
Loading
Loading
Loading
Loading
+3 −4
Original line number Diff line number Diff line
@@ -1651,11 +1651,11 @@ public class Notification implements Parcelable
        }

        private RemoteViews makeBigContentView() {
            RemoteViews contentView = mBuilder.applyStandardTemplateWithActions(R.layout.notification_template_big_text);

            int bigTextId = R.layout.notification_template_big_text;
            RemoteViews contentView = mBuilder.applyStandardTemplateWithActions(bigTextId);
            contentView.setTextViewText(R.id.big_text, mBigText);
            contentView.setViewVisibility(R.id.big_text, View.VISIBLE);
            contentView.setTextViewText(R.id.text, ""); // XXX: what do do with this spot?
            contentView.setViewVisibility(R.id.text2, View.GONE);

            return contentView;
        }
@@ -1665,7 +1665,6 @@ public class Notification implements Parcelable
            if (mBuilder == null) {
                throw new IllegalArgumentException("Style requires a valid Builder object");
            }
            mBuilder.mSubText = null;
            Notification wip = mBuilder.buildUnstyled();
            wip.bigContentView = makeBigContentView();
            return wip;
+0 −7
Original line number Diff line number Diff line
@@ -85,13 +85,6 @@
            android:ellipsize="marquee"
            android:visibility="gone"
            />
        <TextView android:id="@+id/big_text"
            android:textAppearance="@style/TextAppearance.StatusBar.EventContent"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:singleLine="false"
            android:visibility="gone"
            />
        <LinearLayout
            android:id="@+id/line3"
            android:layout_width="match_parent"
+52 −43
Original line number Diff line number Diff line
@@ -33,13 +33,18 @@
        android:layout_height="wrap_content"
        android:layout_gravity="fill_vertical"
        android:layout_marginLeft="@dimen/notification_large_icon_width"
        android:minHeight="@dimen/notification_large_icon_height"
        android:orientation="vertical"
        android:paddingLeft="12dp"
        android:paddingRight="12dp"
        android:paddingTop="4dp"
        android:paddingBottom="4dp"
        android:gravity="center_vertical"
        >
        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:minHeight="@dimen/notification_large_icon_height"
            android:orientation="vertical"
           >
            <LinearLayout
                android:id="@+id/line1"
@@ -88,9 +93,21 @@
                android:textAppearance="@style/TextAppearance.StatusBar.EventContent"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginTop="2dp"
                android:layout_marginBottom="2dp"
                android:singleLine="false"
                android:visibility="gone"
                />
        </LinearLayout>
        <LinearLayout
                android:id="@+id/actions"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="vertical"
            android:visibility="gone"
                >
                <!-- actions will be added here -->
        </LinearLayout>
        <LinearLayout
            android:id="@+id/line3"
            android:layout_width="match_parent"
@@ -135,13 +152,5 @@
            android:visibility="gone"
            style="?android:attr/progressBarStyleHorizontal"
            />
        <LinearLayout
                android:id="@+id/actions"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:visibility="gone"
                >
                <!-- actions will be added here -->
        </LinearLayout>
    </LinearLayout>
</FrameLayout>