aboutsummaryrefslogtreecommitdiff
path: root/app/src/main/kotlin/com/pitchedapps/frost/utils/WebContextMenu.kt
diff options
context:
space:
mode:
authorAllan Wang <me@allanwang.ca>2019-09-22 22:47:07 -0700
committerAllan Wang <me@allanwang.ca>2019-09-22 22:47:07 -0700
commit142b95f0ae82a849b1e9ef390a2a068b4c792be6 (patch)
tree10e7cfbca87fdc3ad904d5b0f38e493d088496e1 /app/src/main/kotlin/com/pitchedapps/frost/utils/WebContextMenu.kt
parent981d6ffb409a501e6efcf4fe0cbe719e192beee7 (diff)
downloadfrost-142b95f0ae82a849b1e9ef390a2a068b4c792be6.tar.gz
frost-142b95f0ae82a849b1e9ef390a2a068b4c792be6.tar.bz2
frost-142b95f0ae82a849b1e9ef390a2a068b4c792be6.zip
Optimize imports and update changelog
Diffstat (limited to 'app/src/main/kotlin/com/pitchedapps/frost/utils/WebContextMenu.kt')
-rw-r--r--app/src/main/kotlin/com/pitchedapps/frost/utils/WebContextMenu.kt4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/src/main/kotlin/com/pitchedapps/frost/utils/WebContextMenu.kt b/app/src/main/kotlin/com/pitchedapps/frost/utils/WebContextMenu.kt
index 7fdd485d..9089d891 100644
--- a/app/src/main/kotlin/com/pitchedapps/frost/utils/WebContextMenu.kt
+++ b/app/src/main/kotlin/com/pitchedapps/frost/utils/WebContextMenu.kt
@@ -34,7 +34,7 @@ fun Context.showWebContextMenu(wc: WebContext) {
if (wc.isEmpty) return
var title = wc.url ?: string(R.string.menu)
title =
- title.substring(title.indexOf("m/") + 1) //just so if defaults to 0 in case it's not .com/
+ title.substring(title.indexOf("m/") + 1) // just so if defaults to 0 in case it's not .com/
if (title.length > 100) title = title.substring(0, 100) + '\u2026'
val menuItems = WebContextType.values
@@ -46,7 +46,7 @@ fun Context.showWebContextMenu(wc: WebContext) {
menuItems[position].onClick(this@showWebContextMenu, wc)
}
onDismiss {
- //showing the dialog interrupts the touch down event, so we must ensure that the viewpager's swipe is enabled
+ // showing the dialog interrupts the touch down event, so we must ensure that the viewpager's swipe is enabled
(this@showWebContextMenu as? MainActivity)?.viewPager?.enableSwipe = true
}
}