mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2024-11-22 01:15:54 +03:00
Draft
This commit is contained in:
parent
0169396d7d
commit
e6995cbdd4
2 changed files with 24 additions and 0 deletions
|
@ -0,0 +1,22 @@
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2020 New Vector Ltd
|
||||||
|
* Copyright (C) 2018 stfalcon.com
|
||||||
|
*
|
||||||
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
* you may not use this file except in compliance with the License.
|
||||||
|
* You may obtain a copy of the License at
|
||||||
|
*
|
||||||
|
* http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
*
|
||||||
|
* Unless required by applicable law or agreed to in writing, software
|
||||||
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
* See the License for the specific language governing permissions and
|
||||||
|
* limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
package im.vector.lib.attachmentviewer
|
||||||
|
|
||||||
|
class AttachmentViewerViewModel {
|
||||||
|
|
||||||
|
}
|
|
@ -554,6 +554,7 @@ class MessageActionsViewModel @AssistedInject constructor(@Assisted
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO need to add this check into media viewer?
|
||||||
private fun canShare(msgType: String?): Boolean {
|
private fun canShare(msgType: String?): Boolean {
|
||||||
return when (msgType) {
|
return when (msgType) {
|
||||||
MessageType.MSGTYPE_TEXT,
|
MessageType.MSGTYPE_TEXT,
|
||||||
|
@ -568,6 +569,7 @@ class MessageActionsViewModel @AssistedInject constructor(@Assisted
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO need to add this into Viewer screen to check if it is saveable? => create extension on MessageType?
|
||||||
private fun canSave(msgType: String?): Boolean {
|
private fun canSave(msgType: String?): Boolean {
|
||||||
return when (msgType) {
|
return when (msgType) {
|
||||||
MessageType.MSGTYPE_IMAGE,
|
MessageType.MSGTYPE_IMAGE,
|
||||||
|
|
Loading…
Reference in a new issue