am 5062649a: Merge "Update list item text appearance"
* commit '5062649abac9bf873123fe560fbb7b0748b30a54': Update list item text appearance
This commit is contained in:
@@ -533,8 +533,7 @@ public class Preference implements Comparable<Preference> {
|
||||
* @see #onCreateView(ViewGroup)
|
||||
*/
|
||||
protected void onBindView(View view) {
|
||||
final TextView titleView = (TextView) view.findViewById(
|
||||
com.android.internal.R.id.title);
|
||||
final TextView titleView = (TextView) view.findViewById(com.android.internal.R.id.title);
|
||||
if (titleView != null) {
|
||||
final CharSequence title = getTitle();
|
||||
if (!TextUtils.isEmpty(title)) {
|
||||
@@ -557,7 +556,7 @@ public class Preference implements Comparable<Preference> {
|
||||
}
|
||||
}
|
||||
|
||||
ImageView imageView = (ImageView) view.findViewById(com.android.internal.R.id.icon);
|
||||
final ImageView imageView = (ImageView) view.findViewById(com.android.internal.R.id.icon);
|
||||
if (imageView != null) {
|
||||
if (mIconResId != 0 || mIcon != null) {
|
||||
if (mIcon == null) {
|
||||
@@ -570,6 +569,11 @@ public class Preference implements Comparable<Preference> {
|
||||
imageView.setVisibility(mIcon != null ? View.VISIBLE : View.GONE);
|
||||
}
|
||||
|
||||
final View imageFrame = view.findViewById(com.android.internal.R.id.icon_frame);
|
||||
if (imageFrame != null) {
|
||||
imageFrame.setVisibility(mIcon != null ? View.VISIBLE : View.GONE);
|
||||
}
|
||||
|
||||
if (mShouldDisableView) {
|
||||
setEnabledStateOnViews(view, isEnabled());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user