use of fr.free.nrw.commons.media.zoomControllers.zoomable.DoubleTapGestureListener in project apps-android-commons by commons-app.
the class ZoomableActivity method init.
private void init() {
if (imageUri != null) {
GenericDraweeHierarchy hierarchy = GenericDraweeHierarchyBuilder.newInstance(getResources()).setActualImageScaleType(ScalingUtils.ScaleType.FIT_CENTER).setProgressBarImage(new ProgressBarDrawable()).setProgressBarImageScaleType(ScalingUtils.ScaleType.FIT_CENTER).build();
photo.setHierarchy(hierarchy);
photo.setAllowTouchInterceptionWhileZoomed(true);
photo.setIsLongpressEnabled(false);
photo.setTapListener(new DoubleTapGestureListener(photo));
DraweeController controller = Fresco.newDraweeControllerBuilder().setUri(imageUri).setControllerListener(loadingListener).build();
photo.setController(controller);
}
}
Aggregations