remove side tapping as clumsy/clashing with urls (closes #702)
This commit is contained in:
parent
d363cb5346
commit
4057f5ac69
@ -423,44 +423,9 @@ public class ArticleFragment extends Fragment implements GestureDetector.OnDoubl
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void onLeftSideTapped() {
|
|
||||||
ArticlePager ap = (ArticlePager) m_activity.getSupportFragmentManager().findFragmentByTag(CommonActivity.FRAG_ARTICLE);
|
|
||||||
|
|
||||||
if (ap != null && ap.isAdded()) {
|
|
||||||
ap.selectArticle(false);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private void onRightSideTapped() {
|
|
||||||
ArticlePager ap = (ArticlePager) m_activity.getSupportFragmentManager().findFragmentByTag(CommonActivity.FRAG_ARTICLE);
|
|
||||||
|
|
||||||
if (ap != null && ap.isAdded()) {
|
|
||||||
ap.selectArticle(true);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onSingleTapConfirmed(MotionEvent e) {
|
public boolean onSingleTapConfirmed(MotionEvent arg0) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
int width = getView().getWidth();
|
|
||||||
int x = Math.round(e.getX());
|
|
||||||
|
|
||||||
if (x <= width/15) {
|
|
||||||
onLeftSideTapped();
|
|
||||||
return true;
|
|
||||||
} else if (x >= width-(width/15)) {
|
|
||||||
onRightSideTapped();
|
|
||||||
return true;
|
|
||||||
} /* else if (!m_activity.isCompatMode()) {
|
|
||||||
ActionBar bar = m_activity.getSupportActionBar();
|
|
||||||
|
|
||||||
if (bar.isShowing()) {
|
|
||||||
bar.hide();
|
|
||||||
} else {
|
|
||||||
bar.show();
|
|
||||||
}
|
|
||||||
} */
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -373,46 +373,9 @@ public class OfflineArticleFragment extends Fragment implements GestureDetector.
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void onLeftSideTapped() {
|
|
||||||
OfflineArticlePager ap = (OfflineArticlePager) m_activity.getSupportFragmentManager().findFragmentByTag(CommonActivity.FRAG_ARTICLE);
|
|
||||||
|
|
||||||
if (ap != null && ap.isAdded()) {
|
|
||||||
ap.selectArticle(false);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private void onRightSideTapped() {
|
|
||||||
OfflineArticlePager ap = (OfflineArticlePager) m_activity.getSupportFragmentManager().findFragmentByTag(CommonActivity.FRAG_ARTICLE);
|
|
||||||
|
|
||||||
if (ap != null && ap.isAdded()) {
|
|
||||||
ap.selectArticle(true);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onSingleTapConfirmed(MotionEvent e) {
|
public boolean onSingleTapConfirmed(MotionEvent e) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
int width = getView().getWidth();
|
|
||||||
int x = Math.round(e.getX());
|
|
||||||
|
|
||||||
if (x <= width/15) {
|
|
||||||
onLeftSideTapped();
|
|
||||||
return true;
|
|
||||||
} else if (x >= width-(width/15)) {
|
|
||||||
onRightSideTapped();
|
|
||||||
return true;
|
|
||||||
} /* else if (!m_activity.isCompatMode()) {
|
|
||||||
ActionBar bar = m_activity.getSupportActionBar();
|
|
||||||
|
|
||||||
if (bar.isShowing()) {
|
|
||||||
bar.hide();
|
|
||||||
} else {
|
|
||||||
bar.show();
|
|
||||||
}
|
|
||||||
} */
|
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user