Skip to content

Commit

Permalink
Added methods to start a ripple manually #25
Browse files Browse the repository at this point in the history
  • Loading branch information
balysv committed Jan 31, 2015
1 parent ce4be50 commit 0483d16
Showing 1 changed file with 10 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -574,6 +574,16 @@ public void setDefaultRippleAlpha(int alpha) {
invalidate();
}

public void performRipple() {
currentCoords = new Point(getWidth() / 2, getHeight() / 2);
startRipple(null);
}

public void performRipple(Point anchor) {
currentCoords = new Point(anchor.x, anchor.y);
startRipple(null);
}

/**
* {@link Canvas#clipPath(Path)} is not supported in hardware accelerated layers
* before API 18. Use software layer instead
Expand Down

0 comments on commit 0483d16

Please sign in to comment.