Code is automatically reformatted

This commit is contained in:
serso 2016-04-01 20:54:13 +02:00
parent f29cfbc563
commit 41e07b7571

View File

@ -45,20 +45,21 @@ public class CustomPopupMenuHelper implements AdapterView.OnItemClickListener, V
private final int mPopupMaxWidth; private final int mPopupMaxWidth;
private final int mPopupStyleAttr; private final int mPopupStyleAttr;
private final int mPopupStyleRes; private final int mPopupStyleRes;
boolean mForceShowIcon;
private View mAnchorView; private View mAnchorView;
private ListPopupWindow mPopup; private ListPopupWindow mPopup;
private ViewTreeObserver mTreeObserver; private ViewTreeObserver mTreeObserver;
private Callback mPresenterCallback; private Callback mPresenterCallback;
boolean mForceShowIcon;
private ViewGroup mMeasureParent; private ViewGroup mMeasureParent;
/** Whether the cached content width value is valid. */ /**
* Whether the cached content width value is valid.
*/
private boolean mHasContentWidth; private boolean mHasContentWidth;
/** Cached content width from {@link #measureContentWidth}. */ /**
* Cached content width from {@link #measureContentWidth}.
*/
private int mContentWidth; private int mContentWidth;
private int mDropDownGravity = Gravity.NO_GRAVITY; private int mDropDownGravity = Gravity.NO_GRAVITY;
@ -104,14 +105,14 @@ public class CustomPopupMenuHelper implements AdapterView.OnItemClickListener, V
mForceShowIcon = forceShow; mForceShowIcon = forceShow;
} }
public void setGravity(int gravity) {
mDropDownGravity = gravity;
}
public int getGravity() { public int getGravity() {
return mDropDownGravity; return mDropDownGravity;
} }
public void setGravity(int gravity) {
mDropDownGravity = gravity;
}
public void show() { public void show() {
if (!tryShow()) { if (!tryShow()) {
throw new IllegalStateException("MenuPopupHelper cannot be used without an anchor"); throw new IllegalStateException("MenuPopupHelper cannot be used without an anchor");