Merge "Fixed a bug where the image and the text were overlapping" into nyc-dev am: 33f39a96cb

am: 93492ed116

* commit '93492ed116bb5c47da9e8c929c36d5db93eae786':
  Fixed a bug where the image and the text were overlapping

Change-Id: Ic2e57c1a14f4463e2527b386c4a0e4359a9c91af
This commit is contained in:
Selim Cinek
2016-05-02 22:41:14 +00:00
committed by android-build-merger

View File

@@ -16,22 +16,19 @@
package com.android.internal.widget; package com.android.internal.widget;
import com.android.internal.R;
import android.annotation.Nullable; import android.annotation.Nullable;
import android.content.Context; import android.content.Context;
import android.content.res.Configuration;
import android.content.res.TypedArray;
import android.text.BoringLayout; import android.text.BoringLayout;
import android.text.Layout; import android.text.Layout;
import android.text.StaticLayout; import android.text.StaticLayout;
import android.text.TextUtils; import android.text.TextUtils;
import android.util.AttributeSet; import android.util.AttributeSet;
import android.util.TypedValue;
import android.view.RemotableViewMethod; import android.view.RemotableViewMethod;
import android.widget.RemoteViews; import android.widget.RemoteViews;
import android.widget.TextView; import android.widget.TextView;
import com.android.internal.R;
/** /**
* A TextView that can float around an image on the end. * A TextView that can float around an image on the end.
* *
@@ -96,9 +93,7 @@ public class ImageFloatingTextView extends TextView {
@RemotableViewMethod @RemotableViewMethod
public void setHasImage(boolean hasImage) { public void setHasImage(boolean hasImage) {
mIndentLines = hasImage ? 2 : 0; setNumIndentLines(hasImage ? 2 : 0);
// The new layout will be automatically created when the text is
// set again by the notification.
} }
/** /**