Skip to content

Commit

Permalink
update README, upgrade version name to v0.5.2
Browse files Browse the repository at this point in the history
  • Loading branch information
dofire committed Apr 16, 2023
1 parent 37ed6a9 commit 9b97362
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 12 deletions.
22 changes: 12 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# 🍀Floating Bubble View
An Android library that adds floating bubbles to your home screen 🎨, supporting both XML and 💘 Jetpack Compose
An Android library that adds floating bubbles to your home screen 🎨, supports both XML and 💘 Jetpack Compose

 

Expand Down Expand Up @@ -158,7 +158,7 @@ Declare the dependencies in the module-level `build.gradle` file 🍀 <img src="
</br>

### 3, start bubble service and enjoy 3️⃣ 🎉🍀
> Make sure "display over other apps" permission is granted, otherwise the app will crash ⚠
> Make sure "display over other apps" permission is granted, otherwise the app will crash ⚠❗💥
<details><summary><b>Java version</b></summary>

Expand Down Expand Up @@ -209,8 +209,9 @@ public class MyService extends FloatingBubbleService {
// set style for bubble, fade animation by default
.bubbleStyle(null)

// set start location of bubble, (x=0, y=0) is the top-left
.startLocation(0, 0)
// set start location for the bubble, (x=0, y=0) is the top-left
.startLocation(100, 100) // in dp
.startLocationPx(100, 100) // in px

// enable auto animate bubble to the left/right side when release, true by default
.enableAnimateToEdge(true)
Expand All @@ -224,8 +225,8 @@ public class MyService extends FloatingBubbleService {
// show close-bubble, true by default
.enableCloseBubble(true)

// the more value (dp), the larger closeable-area
.closablePerimeter(100)
// the more value (dp), the larger closable-area
.distanceToClose(100)

// choose behavior of the bubbles
// DYNAMIC_CLOSE_BUBBLE: close-bubble moving based on the bubble's location
Expand Down Expand Up @@ -307,8 +308,9 @@ class MyService : FloatingBubbleService() {
// set style for bubble, fade animation by default
.bubbleStyle(null)

// set start location of bubble, (x=0, y=0) is the top-left
.startLocation(0, 0)
// set start location for the bubble, (x=0, y=0) is the top-left
.startLocation(100, 100) // in dp
.startLocationPx(100, 100) // in px

// enable auto animate bubble to the left/right side when release, true by default
.enableAnimateToEdge(true)
Expand All @@ -323,7 +325,7 @@ class MyService : FloatingBubbleService() {
.enableCloseBubble(true)

// the more value (dp), the larger closeable-area
.closablePerimeter(100)
.distanceToClose(100)

// choose behavior of the bubbles
// DYNAMIC_CLOSE_BUBBLE: close-bubble moving based on the bubble's location
Expand Down Expand Up @@ -353,7 +355,7 @@ class MyService : FloatingBubbleService() {
val layout = inflater.inflate(R.layout.layout_view_test, null)

layout.findViewById<View>(R.id.card_view).setOnClickListener { v: View? ->
Toast.makeText(this, "hello from card view from kotlin", Toast.LENGTH_SHORT).show();
Toast.makeText(this, "hello from kotlin", Toast.LENGTH_SHORT).show();
action.popToBubble()
}

Expand Down
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ RELEASE_SIGNING_ENABLED=true

GROUP=io.github.torrydo
POM_ARTIFACT_ID=floating-bubble-view
VERSION_NAME=0.5.1
#prev: 0.5.0
VERSION_NAME=0.5.2
#prev: 0.5.1

POM_NAME=FloatingBubbleView
POM_PACKAGING=aar
Expand Down

0 comments on commit 9b97362

Please sign in to comment.