Skip to content

Commit 193c6cd

Browse files
author
Arne Stockmans
committed
Added getter and setter for the touchmode margin threshold
1 parent 2bd360d commit 193c6cd

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

library/src/com/slidingmenu/lib/CustomViewBehind.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,14 @@ public void setWidthOffset(int i) {
5050
mWidthOffset = i;
5151
requestLayout();
5252
}
53+
54+
public void setMarginThreshold(int marginThreshold) {
55+
mMarginThreshold = marginThreshold;
56+
}
57+
58+
public int getMarginThreshold() {
59+
return mMarginThreshold;
60+
}
5361

5462
public int getBehindWidth() {
5563
return mContent.getWidth();

library/src/com/slidingmenu/lib/SlidingMenu.java

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -617,6 +617,22 @@ public void setBehindWidthRes(int res) {
617617
public float getBehindScrollScale() {
618618
return mViewBehind.getScrollScale();
619619
}
620+
621+
/**
622+
* Gets the touch mode margin threshold
623+
* @return the touch mode margin threshold
624+
*/
625+
public int getTouchmodeMarginThreshold() {
626+
return mViewBehind.getMarginThreshold();
627+
}
628+
629+
/**
630+
* Set the touch mode margin threshold
631+
* @param touchmodeMarginThreshold
632+
*/
633+
public void setTouchmodeMarginThreshold(int touchmodeMarginThreshold) {
634+
mViewBehind.setMarginThreshold(touchmodeMarginThreshold);
635+
}
620636

621637
/**
622638
* Sets the behind scroll scale.

0 commit comments

Comments
 (0)