mirror of
https://codeberg.org/Bazsalanszky/Infinity-For-Lemmy.git
synced 2025-10-05 21:39:50 +02:00
Disable ViewPager2's swiping if swipe between posts is disabled.
This commit is contained in:
@@ -165,8 +165,11 @@ public class ViewPostDetailActivity extends BaseActivity implements SortTypeSele
|
||||
}
|
||||
|
||||
boolean swipeBetweenPosts = mSharedPreferences.getBoolean(SharedPreferencesUtils.SWIPE_BETWEEN_POSTS, false);
|
||||
if (!swipeBetweenPosts && mSharedPreferences.getBoolean(SharedPreferencesUtils.SWIPE_RIGHT_TO_GO_BACK, true)) {
|
||||
mSlidrInterface = Slidr.attach(this);
|
||||
if (!swipeBetweenPosts) {
|
||||
if (mSharedPreferences.getBoolean(SharedPreferencesUtils.SWIPE_RIGHT_TO_GO_BACK, true)) {
|
||||
mSlidrInterface = Slidr.attach(this);
|
||||
}
|
||||
viewPager2.setUserInputEnabled(false);
|
||||
}
|
||||
postFragmentId = getIntent().getLongExtra(EXTRA_POST_FRAGMENT_ID, -1);
|
||||
if (swipeBetweenPosts && posts == null && postFragmentId > 0) {
|
||||
|
Reference in New Issue
Block a user