File tree Expand file tree Collapse file tree 5 files changed +26
-0
lines changed
Expand file tree Collapse file tree 5 files changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -22532,6 +22532,7 @@ package android.view {
2253222532 method public abstract java.lang.CharSequence getSubtitle();
2253322533 method public java.lang.Object getTag();
2253422534 method public abstract java.lang.CharSequence getTitle();
22535+ method public boolean getTitleOptionalHint();
2253522536 method public abstract void invalidate();
2253622537 method public boolean isTitleOptional();
2253722538 method public abstract void setCustomView(android.view.View);
Original file line number Diff line number Diff line change 3030 */
3131public abstract class ActionMode {
3232 private Object mTag ;
33+ private boolean mTitleOptionalHint ;
3334
3435 /**
3536 * Set a tag object associated with this ActionMode.
@@ -119,6 +120,18 @@ public Object getTag() {
119120 * @param titleOptional true if the title only presents optional information.
120121 */
121122 public void setTitleOptionalHint (boolean titleOptional ) {
123+ mTitleOptionalHint = titleOptional ;
124+ }
125+
126+ /**
127+ * @return true if this action mode has been given a hint to consider the
128+ * title/subtitle display to be optional.
129+ *
130+ * @see #setTitleOptionalHint(boolean)
131+ * @see #isTitleOptional()
132+ */
133+ public boolean getTitleOptionalHint () {
134+ return mTitleOptionalHint ;
122135 }
123136
124137 /**
Original file line number Diff line number Diff line change @@ -5423,6 +5423,11 @@ public boolean isLayoutRtl() {
54235423 * app should not need to concern itself with saving and restoring, but that
54245424 * the framework should take special note to preserve when possible.
54255425 *
5426+ * <p>A view with transient state cannot be trivially rebound from an external
5427+ * data source, such as an adapter binding item views in a list. This may be
5428+ * because the view is performing an animation, tracking user selection
5429+ * of content, or similar.</p>
5430+ *
54265431 * @return true if the view has transient state
54275432 */
54285433 @ViewDebug.ExportedProperty(category = "layout")
@@ -5436,6 +5441,11 @@ public boolean hasTransientState() {
54365441 * so every call to setHasTransientState(true) should be paired with a later call
54375442 * to setHasTransientState(false).
54385443 *
5444+ * <p>A view with transient state cannot be trivially rebound from an external
5445+ * data source, such as an adapter binding item views in a list. This may be
5446+ * because the view is performing an animation, tracking user selection
5447+ * of content, or similar.</p>
5448+ *
54395449 * @param hasTransientState true if this view has transient state
54405450 */
54415451 public void setHasTransientState(boolean hasTransientState) {
Original file line number Diff line number Diff line change @@ -817,6 +817,7 @@ public CharSequence getSubtitle() {
817817
818818 @ Override
819819 public void setTitleOptionalHint (boolean titleOptional ) {
820+ super .setTitleOptionalHint (titleOptional );
820821 mContextView .setTitleOptional (titleOptional );
821822 }
822823
Original file line number Diff line number Diff line change @@ -73,6 +73,7 @@ public void setSubtitle(int resId) {
7373
7474 @ Override
7575 public void setTitleOptionalHint (boolean titleOptional ) {
76+ super .setTitleOptionalHint (titleOptional );
7677 mContextView .setTitleOptional (titleOptional );
7778 }
7879
You can’t perform that action at this time.
0 commit comments