Skip to content

Commit

Permalink
fix IllegalArgumentException: height must be > 0
Browse files Browse the repository at this point in the history
  • Loading branch information
firemaples committed Sep 9, 2023
1 parent ebff937 commit 1240f85
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,10 @@ class ScreenCirclingView(context: Context) : FloatingView(context) {

viewModel.lastSelectedArea.observe(lifecycleOwner) { selected ->
selected ?: return@observe
circlingView.selectedBox = selected
onAreaSelected?.invoke(circlingView.getViewRect(), selected)
if (circlingView.getViewRect().contains(selected)) {
circlingView.selectedBox = selected
onAreaSelected?.invoke(circlingView.getViewRect(), selected)
}
}
}

Expand Down

0 comments on commit 1240f85

Please sign in to comment.