Prevent usage of bottom row for widgets

This commit is contained in:
Ensar Sarajčić 2023-07-17 11:59:56 +02:00
parent 5d642eefe2
commit 822b373a72
1 changed files with 1 additions and 1 deletions

View File

@ -239,7 +239,7 @@ class WidgetsFragment(context: Context, attributeSet: AttributeSet) : MyFragment
}
override fun onWidgetLongPressed(appWidget: AppWidget) {
if (appWidget.heightCells > context.config.homeRowCount || appWidget.widthCells > context.config.homeColumnCount) {
if (appWidget.heightCells > context.config.homeRowCount - 1 || appWidget.widthCells > context.config.homeColumnCount) {
context.toast("Widget is too big for current home screen size")
return
}