mirror of
https://github.com/SimpleMobileTools/Simple-Launcher.git
synced 2025-06-05 21:59:15 +02:00
Fix shadow drawing in folders
This commit is contained in:
@ -469,8 +469,8 @@ class HomeScreenGrid(context: Context, attrs: AttributeSet, defStyle: Int) : Rel
|
|||||||
|
|
||||||
val folder = currentlyOpenFolder
|
val folder = currentlyOpenFolder
|
||||||
if (folder != null && folder.getItemsDrawingRect().contains(
|
if (folder != null && folder.getItemsDrawingRect().contains(
|
||||||
(sideMargins.left + draggedItemCurrentCoords.first).toFloat(),
|
(draggedItemCurrentCoords.first).toFloat(),
|
||||||
(sideMargins.top + draggedItemCurrentCoords.second).toFloat()
|
(draggedItemCurrentCoords.second).toFloat()
|
||||||
)
|
)
|
||||||
) {
|
) {
|
||||||
val center = folder.getItemsGridCenters().minBy {
|
val center = folder.getItemsGridCenters().minBy {
|
||||||
@ -1040,8 +1040,8 @@ class HomeScreenGrid(context: Context, attrs: AttributeSet, defStyle: Int) : Rel
|
|||||||
if (draggedItem != null && draggedItemCurrentCoords.first != -1 && draggedItemCurrentCoords.second != -1) {
|
if (draggedItem != null && draggedItemCurrentCoords.first != -1 && draggedItemCurrentCoords.second != -1) {
|
||||||
if (draggedItem!!.isSingleCellType()) {
|
if (draggedItem!!.isSingleCellType()) {
|
||||||
if (folder != null && folder.getItemsDrawingRect().contains(
|
if (folder != null && folder.getItemsDrawingRect().contains(
|
||||||
(sideMargins.left + draggedItemCurrentCoords.first).toFloat(),
|
(draggedItemCurrentCoords.first).toFloat(),
|
||||||
(sideMargins.top + draggedItemCurrentCoords.second).toFloat()
|
(draggedItemCurrentCoords.second).toFloat()
|
||||||
)
|
)
|
||||||
) {
|
) {
|
||||||
|
|
||||||
@ -1346,7 +1346,7 @@ class HomeScreenGrid(context: Context, attrs: AttributeSet, defStyle: Int) : Rel
|
|||||||
if (currentlyOpenFolder == null) {
|
if (currentlyOpenFolder == null) {
|
||||||
currentlyOpenFolder = folder.toFolder(animateOpening = true)
|
currentlyOpenFolder = folder.toFolder(animateOpening = true)
|
||||||
redrawGrid()
|
redrawGrid()
|
||||||
} else if (currentlyOpenFolder?.item?.id != folder.id ){
|
} else if (currentlyOpenFolder?.item?.id != folder.id) {
|
||||||
closeFolder()
|
closeFolder()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user