Skip to content

Commit b77a203

Browse files
author
jfeinstein10
committed
fixing naming convention
1 parent d30de3f commit b77a203

File tree

2 files changed

+18
-16
lines changed

2 files changed

+18
-16
lines changed

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

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1116,28 +1116,28 @@ private void completeScroll() {
11161116
}
11171117
}
11181118

1119-
private int mAboveTouchMode = SlidingMenu.TOUCHMODE_MARGIN;
1120-
private int mBehindTouchMode = SlidingMenu.TOUCHMODE_MARGIN;
1119+
private int mTouchModeAbove = SlidingMenu.TOUCHMODE_MARGIN;
1120+
private int mTouchModeBehind = SlidingMenu.TOUCHMODE_MARGIN;
11211121

1122-
public void setAboveTouchMode(int i) {
1123-
mAboveTouchMode = i;
1122+
public void setTouchModeAbove(int i) {
1123+
mTouchModeAbove = i;
11241124
}
11251125

1126-
public int getAboveTouchMode() {
1127-
return mAboveTouchMode;
1126+
public int getTouchModeAbove() {
1127+
return mTouchModeAbove;
11281128
}
11291129

1130-
public void setBehindTouchMode(int i) {
1131-
mBehindTouchMode = i;
1130+
public void setTouchModeBehind(int i) {
1131+
mTouchModeBehind = i;
11321132
}
11331133

1134-
public int getBehindTouchMode() {
1135-
return mBehindTouchMode;
1134+
public int getTouchModeBehind() {
1135+
return mTouchModeBehind;
11361136
}
11371137

11381138
private boolean thisTouchAllowed(float x) {
11391139
if (isMenuOpen()) {
1140-
switch (mBehindTouchMode) {
1140+
switch (mTouchModeBehind) {
11411141
case SlidingMenu.TOUCHMODE_FULLSCREEN:
11421142
return true;
11431143
case SlidingMenu.TOUCHMODE_MARGIN:
@@ -1146,7 +1146,7 @@ private boolean thisTouchAllowed(float x) {
11461146
return false;
11471147
}
11481148
} else {
1149-
switch (mAboveTouchMode) {
1149+
switch (mTouchModeAbove) {
11501150
case SlidingMenu.TOUCHMODE_FULLSCREEN:
11511151
return true;
11521152
case SlidingMenu.TOUCHMODE_MARGIN:

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

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,8 @@ public SlidingMenu(Context context, AttributeSet attrs, int defStyle) {
5757
setBehindOffset(offsetBehind);
5858
float scrollOffsetBehind = ta.getFloat(R.styleable.SlidingMenu_behindScrollScale, 0.0f);
5959
setBehindScrollScale(scrollOffsetBehind);
60+
61+
showAbove();
6062
}
6163

6264
public void setViewAbove(int res) {
@@ -171,27 +173,27 @@ public void setBehindScrollScale(float f) {
171173
}
172174

173175
public int getTouchModeAbove() {
174-
return mViewAbove.getAboveTouchMode();
176+
return mViewAbove.getTouchModeAbove();
175177
}
176178

177179
public void setTouchModeAbove(int i) {
178180
if (i != TOUCHMODE_FULLSCREEN && i != TOUCHMODE_MARGIN) {
179181
throw new IllegalStateException("TouchMode must be set to either" +
180182
"TOUCHMODE_FULLSCREEN or TOUCHMODE_MARGIN.");
181183
}
182-
mViewAbove.setAboveTouchMode(i);
184+
mViewAbove.setTouchModeAbove(i);
183185
}
184186

185187
public int getTouchModeBehind() {
186-
return mViewAbove.getBehindTouchMode();
188+
return mViewAbove.getTouchModeBehind();
187189
}
188190

189191
public void setTouchModeBehind(int i) {
190192
if (i != TOUCHMODE_FULLSCREEN && i != TOUCHMODE_MARGIN) {
191193
throw new IllegalStateException("TouchMode must be set to either" +
192194
"TOUCHMODE_FULLSCREEN or TOUCHMODE_MARGIN.");
193195
}
194-
mViewAbove.setBehindTouchMode(i);
196+
mViewAbove.setTouchModeBehind(i);
195197
}
196198

197199
}

0 commit comments

Comments
 (0)