Android Imagemap with webview - android

I am trying to make an image map similar to AndroidImageMap. Now, i need to know whether the same implementation with android webview is possible? Because, the image map can be processed in the server side and implemented as HTML image map. If we use to display the HTML image map's URL in a webview, then how can the click events be recognized from the webview co-ordinates clicked?
Note : I need to perform respected action when the corresponding image map co-ordinates clicked.

Related

How to use image as a map with zoom level in android

I am trying to implement an app where a simple image (floor plan of a room ) is used as a map.
Actually I am not clearly sure about how to do it. But after some searching, I follow one of instructions in a blog.
I am using a WebView to show the image. I am using three different size of the image for three specific zoom level.
There are two button zoomIn and zoomOut. I am just loading a different image when zoom level is changed.
Is it right way?
To enable zoom on the WebView, add the following code:
webView.getSettings().setBuiltInZoomControls(true);
for your button 1:
int zoom_level=100;
webview1.setInitialScale(zoom_level);
webview1.loadData("url");
repeat same for other buttons.

Displaying a preview of a webpage inside imageview

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.

Android WebView PDF View

I want to View PDF file within my Android Application. Currently I am using below code to view PDF file,
webView.loadUrl("http://docs.google.com/gview?embedded=true&url=http://www.xyz/docs/pdf1.pdf");
I don't want to use above method i.e. Google Doc, as it shows light blue title with two small magnifying lens for zoom in-zoom out, i just want to view the plain PDF, where zooming is done by fingers. Is that possible?

Android, How to show array of address of images with intent?

I have an array which includes URL address of for example 20 images. When user clicks on a button i need to show image in full screen mode and if user touched the screen and his finger points to right or left then show next or previous image (something like loading image from gallery and navigating to right or left).
Is it possible to do it with intents? Thank you.
Yes you can do it, find out the Gallery example in Android Universal Image loader.

Android: loadData into Webview without repositioning screen

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()");

Categories

Resources