X-Git-Url: https://git.gag.com/?p=fw%2Faltos;a=blobdiff_plain;f=altosdroid%2Fsrc%2Forg%2Faltusmetrum%2FAltosDroid%2FAltosViewPager.java;h=039ba149a219a36aa5d53761f8e6560183354778;hp=e8299b09aeda4f2de7f6f0d334b7cbda14c545b4;hb=4a257455b2dc57069c41e1845daf66239c5cbe1d;hpb=7975d088a4ac44c0943134fa41d0e3b88f50b98f diff --git a/altosdroid/src/org/altusmetrum/AltosDroid/AltosViewPager.java b/altosdroid/src/org/altusmetrum/AltosDroid/AltosViewPager.java index e8299b09..039ba149 100644 --- a/altosdroid/src/org/altusmetrum/AltosDroid/AltosViewPager.java +++ b/altosdroid/src/org/altusmetrum/AltosDroid/AltosViewPager.java @@ -3,7 +3,8 @@ * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; version 2 of the License. + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. * * This program is distributed in the hope that it will be useful, but * WITHOUT ANY WARRANTY; without even the implied warranty of @@ -34,17 +35,19 @@ public class AltosViewPager extends ViewPager { @Override protected boolean canScroll(View v, boolean checkV, int dx, int x, int y) { - if (v.getClass().getName().endsWith("MapView")) - return true; - - if(v.getClass() != null && - v.getClass().getPackage() != null && - v.getClass().getPackage().getName() != null && - v.getClass().getPackage().getName().startsWith("maps.")) - { - return true; - } - return super.canScroll(v, checkV, dx, x, y); + + if (v.getClass() != null && + v.getClass().getName() != null && + v.getClass().getName().endsWith("MapOffline")) + return true; + + if(v.getClass() != null && + v.getClass().getPackage() != null && + v.getClass().getPackage().getName() != null && + v.getClass().getPackage().getName().startsWith("maps.")) + return true; + + return super.canScroll(v, checkV, dx, x, y); } }