mirror of
https://github.com/nextcloud/talk-android
synced 2025-07-10 06:14:10 +01:00
Merge pull request #3922 from nextcloud/bugfix/3669/fixToOpenPreviewLinksInFilesApp
Bugfix/3669/fix to open preview links in files app
This commit is contained in:
commit
f3187187a8
@ -98,7 +98,7 @@ class IncomingLinkPreviewMessageViewHolder(incomingView: View, payload: Any) :
|
||||
message,
|
||||
ncApi,
|
||||
binding.referenceInclude,
|
||||
context
|
||||
itemView.context
|
||||
)
|
||||
binding.referenceInclude.referenceWrapper.setOnLongClickListener { l: View? ->
|
||||
commonMessageInterface.onOpenMessageActionsDialog(message)
|
||||
|
@ -109,7 +109,7 @@ class OutcomingLinkPreviewMessageViewHolder(outcomingView: View, payload: Any) :
|
||||
message,
|
||||
ncApi,
|
||||
binding.referenceInclude,
|
||||
context
|
||||
itemView.context
|
||||
)
|
||||
binding.referenceInclude.referenceWrapper.setOnLongClickListener { l: View? ->
|
||||
commonMessageInterface.onOpenMessageActionsDialog(message)
|
||||
|
@ -22,8 +22,8 @@ class UriUtils {
|
||||
|
||||
fun isInstanceInternalFileShareUrl(baseUrl: String, url: String): Boolean {
|
||||
// https://cloud.nextcloud.com/f/41
|
||||
return url.startsWith("$baseUrl/f/") || url.startsWith("$baseUrl/index.php/f/") &&
|
||||
Regex(".*/f/d*").matches(url)
|
||||
return (url.startsWith("$baseUrl/f/") || url.startsWith("$baseUrl/index.php/f/")) &&
|
||||
Regex(".*/f/\\d*").matches(url)
|
||||
}
|
||||
|
||||
fun extractInstanceInternalFileShareFileId(url: String): String {
|
||||
|
Loading…
Reference in New Issue
Block a user