1
0
Fork 0
mirror of https://github.com/anyproto/anytype-kotlin.git synced 2025-06-11 18:20:25 +09:00

Should not show toast when clicking on markup url (#762)

This commit is contained in:
Evgenii Kozlov 2020-09-01 16:21:34 +03:00 committed by GitHub
parent ea82bd4f67
commit e847982278
Signed by: github
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 2 deletions

View file

@ -4,6 +4,7 @@
### Fixes & tech 🚒
* Should not show toast when clicking on markup url (#698)
* Checkbox state in action-menu preview is not synced with editor state (#748)
* User interactions with checkbox button are not synced correctly with the middleware (#749, #668)
* When searching for pages, if filter text is empty space, query returns only pages where title contains empty spaces (#746)

View file

@ -12,6 +12,7 @@ import android.util.AttributeSet
import android.view.inputmethod.EditorInfo
import androidx.appcompat.widget.AppCompatEditText
import androidx.core.graphics.withTranslation
import com.agileburo.anytype.core_ui.BuildConfig
import com.agileburo.anytype.core_ui.tools.ClipboardInterceptor
import com.agileburo.anytype.core_ui.tools.DefaultTextWatcher
import com.agileburo.anytype.core_ui.tools.MentionTextWatcher
@ -184,8 +185,10 @@ class TextInputWidget : AppCompatEditText {
*/
private fun makeLinksActive() {
BetterLinkMovementMethod.linkify(Linkify.ALL, this)
.setOnLinkClickListener { textView, url ->
textView.context.toast("On link click $url")
.setOnLinkClickListener { _, url ->
if (BuildConfig.DEBUG) {
context.toast("On link click $url")
}
false
}
}