File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2929
3030Add it in your build.gradle at the end of repositories:
3131
32- ```
32+ ``` groovy
3333allprojects {
3434 repositories {
3535 ...
@@ -40,9 +40,9 @@ allprojects {
4040
4141Add the dependency in the form:
4242
43- ```
43+ ``` groovy
4444dependencies {
45- compile 'com.github.hzw1199:FloatingView:1.6 .0'
45+ compile 'com.github.hzw1199:FloatingView:1.7 .0'
4646}
4747```
4848
@@ -52,6 +52,11 @@ Configure and display
5252
5353* ``` OverlaySystem ``` mode
5454
55+ AndroidManifest.xml:
56+ ``` xml
57+ <uses-permission android : name =" android.permission.SYSTEM_ALERT_WINDOW" />
58+ ```
59+
5560onCreate:
5661
5762``` java
@@ -68,7 +73,7 @@ floatingView.showOverlaySystem();
6873
6974onDestroy:
7075
71- ```
76+ ``` java
7277if (floatingView != null ) {
7378 floatingView. hide();
7479}
@@ -92,7 +97,7 @@ floatingView.showOverlayActivity();
9297
9398onDetachedFromWindow:
9499
95- ```
100+ ``` java
96101if (floatingView != null ) {
97102 floatingView. hide();
98103}
@@ -123,7 +128,7 @@ lyViewGroup.post(new Runnable() {
123128
124129onDestroy:
125130
126- ```
131+ ``` java
127132if (floatingView != null ) {
128133 floatingView. hide();
129134}
Original file line number Diff line number Diff line change 2727
2828在project的build.gradle中加入以下语句:
2929
30- ```
30+ ``` groovy
3131allprojects {
3232 repositories {
3333 ...
@@ -38,9 +38,9 @@ allprojects {
3838
3939在module的build.gradle中加入以下语句:
4040
41- ```
41+ ``` groovy
4242dependencies {
43- compile 'com.github.hzw1199:FloatingView:1.6 .0'
43+ compile 'com.github.hzw1199:FloatingView:1.7 .0'
4444}
4545```
4646
@@ -50,6 +50,11 @@ dependencies {
5050
5151* ``` OverlaySystem ``` 模式
5252
53+ AndroidManifest.xml:
54+ ``` xml
55+ <uses-permission android : name =" android.permission.SYSTEM_ALERT_WINDOW" />
56+ ```
57+
5358onCreate:
5459
5560``` java
@@ -66,7 +71,7 @@ floatingView.showOverlaySystem();
6671
6772onDestroy:
6873
69- ```
74+ ``` java
7075if (floatingView != null ) {
7176 floatingView. hide();
7277}
@@ -90,7 +95,7 @@ floatingView.showOverlayActivity();
9095
9196onDetachedFromWindow:
9297
93- ```
98+ ``` java
9499if (floatingView != null ) {
95100 floatingView. hide();
96101}
@@ -121,7 +126,7 @@ lyViewGroup.post(new Runnable() {
121126
122127onDestroy:
123128
124- ```
129+ ``` java
125130if (floatingView != null ) {
126131 floatingView. hide();
127132}
Original file line number Diff line number Diff line change 11<?xml version =" 1.0" encoding =" utf-8" ?>
22<manifest xmlns : android =" http://schemas.android.com/apk/res/android" >
33
4+ <uses-permission android : name =" android.permission.SYSTEM_ALERT_WINDOW" />
45 <application
56 android : allowBackup =" true"
67 android : icon =" @mipmap/ic_launcher"
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ publishing {
66 release(MavenPublication ) {
77 groupId = ' com.github.hzw1199'
88 artifactId = ' FloatingView'
9- version = ' 1.6 .0'
9+ version = ' 1.7 .0'
1010
1111 afterEvaluate {
1212 from components. release
Original file line number Diff line number Diff line change 11<manifest xmlns : android =" http://schemas.android.com/apk/res/android" >
22
3- <uses-permission android : name =" android.permission.SYSTEM_ALERT_WINDOW" />
43</manifest >
You can’t perform that action at this time.
0 commit comments