Merge "Create ListPopupWindow handler against main looper" into mnc-dev

This commit is contained in:
Alan Viverette
2015-06-19 19:21:09 +00:00
committed by Android (Google) Code Review

View File

@@ -105,7 +105,7 @@ public class ListPopupWindow {
private final ListSelectorHider mHideSelector = new ListSelectorHider(); private final ListSelectorHider mHideSelector = new ListSelectorHider();
private Runnable mShowDropDownRunnable; private Runnable mShowDropDownRunnable;
private Handler mHandler = new Handler(); private final Handler mHandler;
private Rect mTempRect = new Rect(); private Rect mTempRect = new Rect();
@@ -212,6 +212,7 @@ public class ListPopupWindow {
*/ */
public ListPopupWindow(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) { public ListPopupWindow(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
mContext = context; mContext = context;
mHandler = new Handler(context.getMainLooper());
final TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.ListPopupWindow, final TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.ListPopupWindow,
defStyleAttr, defStyleRes); defStyleAttr, defStyleRes);