Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: adblockplussbrowser/src/org/adblockplus/sbrowser/contentblocker/UrlInputOpenerPreference.java

Issue 29441558: Issue 5243 - Clipped text across languages (Closed)
Patch Set: Created May 18, 2017, 12:54 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: adblockplussbrowser/src/org/adblockplus/sbrowser/contentblocker/UrlInputOpenerPreference.java
===================================================================
--- a/adblockplussbrowser/src/org/adblockplus/sbrowser/contentblocker/UrlInputOpenerPreference.java
+++ b/adblockplussbrowser/src/org/adblockplus/sbrowser/contentblocker/UrlInputOpenerPreference.java
@@ -26,16 +26,17 @@
import android.support.annotation.DrawableRes;
import android.support.v4.content.ContextCompat;
import android.text.Editable;
import android.text.InputType;
import android.text.TextWatcher;
import android.util.AttributeSet;
import android.util.Patterns;
import android.view.KeyEvent;
+import android.view.View;
import android.view.inputmethod.EditorInfo;
import android.widget.EditText;
import android.widget.TextView;
import android.widget.Toast;
import org.adblockplus.adblockplussbrowser.R;
public class UrlInputOpenerPreference extends EditTextPreference implements TextWatcher,
@@ -117,16 +118,27 @@
{
Toast.makeText(getContext(), R.string.whitelist_website_invalid_url_error, Toast.LENGTH_SHORT).show();
}
return true;
}
return false;
}
+ @Override
+ protected void onBindView(View view)
+ {
+ super.onBindView(view);
+ final TextView title = (TextView) view.findViewById(android.R.id.title);
+ if (title != null) {
+ title.setSingleLine(false);
+ title.setEllipsize(null);
+ }
diegocarloslima 2017/05/25 18:53:56 To avoid duplication of this snippet here and in a
jens 2017/05/30 12:17:00 Acknowledged.
+ }
+
public void setIcon(@DrawableRes int iconResId)
{
final Drawable drawable = ContextCompat.getDrawable(getContext(), iconResId);
setIcon(drawable);
}
public void setIcon(Drawable icon)
{

Powered by Google App Engine
This is Rietveld