Skip to content

Commit 382af1b

Browse files
committed
Prevent crash on small screens when showing empty vault hint
Fixes #608
1 parent 18149e6 commit 382af1b

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

presentation/src/main/java/org/cryptomator/presentation/ui/layout/ArcAwareCoordinatorLayout.kt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,11 @@ class ArcAwareCoordinatorLayout : CoordinatorLayout {
3535
override fun dispatchDraw(canvas: Canvas) {
3636
super.dispatchDraw(canvas)
3737
if (findViewById<View>(R.id.rl_creation_hint).visibility == VISIBLE) {
38-
drawArcFromHintToFloatingActionButton(canvas)
38+
try {
39+
drawArcFromHintToFloatingActionButton(canvas)
40+
} catch (e: IllegalArgumentException) {
41+
Timber.tag("ArcAwareCoordinatorLayout").e(e, "Failed to draw Arc.")
42+
}
3943
}
4044
}
4145

0 commit comments

Comments
 (0)