diff options
author | Allan Wang <me@allanwang.ca> | 2017-07-17 12:38:42 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-07-17 12:38:42 -0700 |
commit | e4679b1663fa78a99c6c8225e454595c6c6f4e38 (patch) | |
tree | a777ee782207c89d6e9243399471b9ad936736d0 /app/src/main/kotlin/com/pitchedapps/frost/web/FrostWebViewClientMenu.kt | |
parent | 7bf93ea74b00ab7e8ceedac2aac6ad08fdf099ab (diff) | |
download | frost-1.3.2.tar.gz frost-1.3.2.tar.bz2 frost-1.3.2.zip |
Fix notifications and long press for albums (#69)v1.3.2
* Allow for album images to be viewed
* Update listing info
* Web refractoring
* Test message notifications
* Fix notifications and context press
Diffstat (limited to 'app/src/main/kotlin/com/pitchedapps/frost/web/FrostWebViewClientMenu.kt')
-rw-r--r-- | app/src/main/kotlin/com/pitchedapps/frost/web/FrostWebViewClientMenu.kt | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/app/src/main/kotlin/com/pitchedapps/frost/web/FrostWebViewClientMenu.kt b/app/src/main/kotlin/com/pitchedapps/frost/web/FrostWebViewClientMenu.kt deleted file mode 100644 index 10648e73..00000000 --- a/app/src/main/kotlin/com/pitchedapps/frost/web/FrostWebViewClientMenu.kt +++ /dev/null @@ -1,35 +0,0 @@ -package com.pitchedapps.frost.web - -import android.webkit.WebView -import com.pitchedapps.frost.facebook.FB_URL_BASE -import com.pitchedapps.frost.injectors.JsAssets -import com.pitchedapps.frost.injectors.jsInject - -/** - * Created by Allan Wang on 2017-05-31. - */ -class FrostWebViewClientMenu(webCore: FrostWebViewCore) : FrostWebViewClient(webCore) { - - private val String.shouldInjectMenu - get() = when (removePrefix(FB_URL_BASE)) { - "settings", - "settings#", - "settings#!/settings?soft=bookmarks" -> true - else -> false - } - - override fun onPageFinished(view: WebView, url: String) { - super.onPageFinished(view, url) - if (url.shouldInjectMenu) jsInject(JsAssets.MENU) - } - - override fun emit(flag: Int) { - super.emit(flag) - super.injectAndFinish() - } - - override fun onPageFinishedActions(url: String) { - if (!url.shouldInjectMenu) injectAndFinish() - } - -}
\ No newline at end of file |