Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/AhmadNemati/ClickableWebView
Simple WebView to Detect click on an image
https://github.com/AhmadNemati/ClickableWebView
android android-library click library webview
Last synced: about 1 month ago
JSON representation
Simple WebView to Detect click on an image
- Host: GitHub
- URL: https://github.com/AhmadNemati/ClickableWebView
- Owner: AhmadNemati
- License: apache-2.0
- Created: 2016-10-23T11:24:59.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2017-03-31T12:29:00.000Z (over 7 years ago)
- Last Synced: 2024-08-03T01:14:14.639Z (4 months ago)
- Topics: android, android-library, click, library, webview
- Language: Java
- Homepage:
- Size: 9.01 MB
- Stars: 41
- Watchers: 6
- Forks: 13
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-github-android-ui - ClickableWebView - 检测图片上的点击 (WebView)
README
[![License Apache 2.0](https://img.shields.io/badge/License-Apache%202.0-blue.svg?style=true)](http://www.apache.org/licenses/LICENSE-2.0)
![minSdkVersion 9](https://img.shields.io/badge/minSdkVersion-9-red.svg?style=true)
![compileSdkVersion 24](https://img.shields.io/badge/compileSdkVersion-24-yellow.svg?style=true)
# ClickableWebView
Simple WebView to Detect click on an image# Demo
![alt tag](https://raw.githubusercontent.com/AhmadNemati/ClickableWebView/test/art/webview.gif)
# Setup
# Step 1 :Add it as a dependency in your app's build.gradle file```gradle
compile 'com.ahmadnemati.clickablewebview:clickablewebview:1.1.2' //jcenter()
```
# Step 2 :Add it to your layout
```xml
```
# Step 3 :Initialize WebView and setOnWebViewClickListener Method
```java
ClickableWebView clickableWebView;
clickableWebView= (ClickableWebView) findViewById(R.id.clickable_webview);
clickableWebView.setOnWebViewClickListener(new OnWebViewClicked() {
@Override
public void onClick(String url) {
//just use url
}
});
```
# Developed By* Ahmad Nemati
* [ahmadnemati.com](http://ahmadnemati.com) -# License
Copyright 2016 Ahmad Nemati
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License athttp://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.