fix overlay position by AhmedRaza

This commit is contained in:
ΞTΞRNAL
2026-03-11 11:57:12 +05:30
committed by GitHub
parent 216bb71fef
commit 481e5840f0

View File

@@ -113,9 +113,14 @@ class OperaStoryCounter : Feature("OperaStoryCounter") {
FrameLayout.LayoutParams.WRAP_CONTENT,
FrameLayout.LayoutParams.WRAP_CONTENT
).apply {
gravity = Gravity.TOP or Gravity.END
val isOperaDownloadEnabled = this@OperaStoryCounter.context.config.downloader.operaDownloadButton.get()
gravity = Gravity.TOP or if (isOperaDownloadEnabled) Gravity.START else Gravity.END
topMargin = this@OperaStoryCounter.context.userInterface.dpToPx(50)
marginEnd = this@OperaStoryCounter.context.userInterface.dpToPx(10)
if (isOperaDownloadEnabled) {
marginStart = this@OperaStoryCounter.context.userInterface.dpToPx(10)
} else {
marginEnd = this@OperaStoryCounter.context.userInterface.dpToPx(10)
}
}
}
viewGroup.addView(composeView)