Here i have issue with swipe event conflict with html5 page image gallery and webview swipe event in android.
I create an EBookReader app to read .epub files for android. My app have feature of swiping page. I have one .epub file with images, videos and image gallery, image gallery have 5 images on html page and at a time see 1 image, to see another image html page have scrollable image gallery, html page uses iScroll.js and panelnav.js for image gallery.
My ePub file has 10 html pages and my reader page support swipe scroll on page.
I implemented for navigation page using Custom Horizontal Scroller. i display html5 pages on webview and scroll one after another webview on Horizontal scroller pager. my web page swipe perfectly but when html5 page have image gallery with swipe feature, images are swipe but my webview is also swipe. i want to stop my webview swipe when my html page have image gallery with swipe in android.
Please Help.
Thanks in Advance.
Related
I want to get a preview of a webpage for a given url, how can I achieve that?
I have a simple Activity with a layout only with an ImageView, and I want to display a preview of the web page inside the ImageView.
The only solution will probably be to have a small disabled webview and load the url from the webview.
I'm looking for an image viewer which has zoom functionality (pinch-zoom) and page-flip functionality.
I've found a lot of fancy image viewers and page-flippers out there but I can't find one that has best of both. Is there anything out there what can do this? Or even better, how can I combine an image viewer with a page curl library?
Here is a list of views that I've already tried:
Android Page Curl
Page Turner
An SO Article here about flipping pages
If this is really to hard/impossible to do, it's alright if it's just a swipe animation where the pages get's pushed into the screen.
I've just written an app with a nice photo gallery for iOS, now I'd like to do the same thing with my Android version of the app. I see that the Android Gallery API allows me to build a scrolling gallery of images. But what I really want is an apple-photo gallery style interface with a grid of thumbnails which, when tapped, open up a full screen display of the selected image and allows me to navigate through the photo gallery using swipes or left/right arrows on a tool bar.
In iOS I used the KTPhotoBrowser to achieve this interface, but I haven't been able to find anything like that for Android. Can anybody point me to a library, or even a tutorial with example code which will give me an interface like that without having to roll it myself?
Update: I've found the GridView Tutorial which describes how to put image thumbnails into a grid, seems to be the perfect thing. The Gallery API can be used for the full size photo browser as shown in #ariefbayu sample code (see link in comments below). It's not quite the same as the iPhone style gallery, but it's pretty good.
I've done this kind of interface. The basic is:
MainActivity load images into GridView.
On each Gallery click, load another activity using Intent, called SlideActivity which extends 'Gallery' in full screen mode where this will:
show Gallery and set current image to selected
set currently selected image in gallery, to what is clicked in first layout.
Link to sample code: https://www.dropbox.com/s/xk2oupma8zcxqpf/GridToGallery.zip
I want to develop html5 application in android.I am taking WebView and loading url (path to html5 which i place in android assets folder)but iam getting scrolling effect.How should i avoid it, where should i place images and css file
For removing horizontal scroll effect just add it
mWebView.getSettings().setLayoutAlgorithm(LayoutAlgorithm.SINGLE_COLUMN);
I want to download and load images into Webview as they are downloaded (embedding direct image url's into the HTML is not an option)
When I call the webView.loadData(myData.. the full page is refreshed and the user's app is repositioned to 0,0 - is there a way where I can append to the HTML with the new image as and when it is downloaded? I am looking for a way to override the functionality of resetting the position of the webView on a call to loadData
Thanks
Can you handle the problem in JS side by trigering an event to document when the app has downloaded images ?
Like :
myWebView.loadUrl("javascript:imagesLoaded()");