Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
AloqaIM-Android
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
AloqaIM-Android
Commits
3955c8d3
Commit
3955c8d3
authored
Jun 03, 2018
by
Leonardo Aramaki
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add Message_Read_Receipt_Enabled and Message_Read_Receipt_Store_Users
settings fetch support.
parent
bf2c5496
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
1 deletion
+6
-1
RefreshSettingsInteractor.kt
...rocket/android/server/domain/RefreshSettingsInteractor.kt
+1
-1
SettingsRepository.kt
...a/chat/rocket/android/server/domain/SettingsRepository.kt
+5
-0
No files found.
app/src/main/java/chat/rocket/android/server/domain/RefreshSettingsInteractor.kt
View file @
3955c8d3
...
...
@@ -25,7 +25,7 @@ class RefreshSettingsInteractor @Inject constructor(
HIDE_USER_JOIN
,
HIDE_USER_LEAVE
,
HIDE_TYPE_AU
,
HIDE_MUTE_UNMUTE
,
HIDE_TYPE_RU
,
ALLOW_MESSAGE_DELETING
,
ALLOW_MESSAGE_EDITING
,
ALLOW_MESSAGE_PINNING
,
ALLOW_MESSAGE_STARRING
,
SHOW_DELETED_STATUS
,
SHOW_EDITED_STATUS
,
WIDE_TILE_310
,
STORE_LAST_MESSAGE
)
WIDE_TILE_310
,
STORE_LAST_MESSAGE
,
MESSAGE_READ_RECEIPT_ENABLED
,
MESSAGE_READ_RECEIPT_STORE_USERS
)
suspend
fun
refresh
(
server
:
String
)
{
withContext
(
CommonPool
)
{
...
...
app/src/main/java/chat/rocket/android/server/domain/SettingsRepository.kt
View file @
3955c8d3
...
...
@@ -51,6 +51,8 @@ const val SHOW_EDITED_STATUS = "Message_ShowEditedStatus"
const
val
ALLOW_MESSAGE_PINNING
=
"Message_AllowPinning"
const
val
ALLOW_MESSAGE_STARRING
=
"Message_AllowStarring"
const
val
STORE_LAST_MESSAGE
=
"Store_Last_Message"
const
val
MESSAGE_READ_RECEIPT_ENABLED
=
"Message_Read_Receipt_Enabled"
const
val
MESSAGE_READ_RECEIPT_STORE_USERS
=
"Message_Read_Receipt_Store_Users"
/*
* Extension functions for Public Settings.
...
...
@@ -91,6 +93,9 @@ fun PublicSettings.allowedMessageDeleting(): Boolean = this[ALLOW_MESSAGE_DELETI
fun
PublicSettings
.
hasShowLastMessage
():
Boolean
=
this
[
STORE_LAST_MESSAGE
]
!=
null
fun
PublicSettings
.
showLastMessage
():
Boolean
=
this
[
STORE_LAST_MESSAGE
]
?.
value
==
true
fun
PublicSettings
.
messageReadReceiptEnabled
():
Boolean
=
this
[
MESSAGE_READ_RECEIPT_ENABLED
]
?.
value
==
true
fun
PublicSettings
.
messageReadReceiptStoreUsers
():
Boolean
=
this
[
MESSAGE_READ_RECEIPT_STORE_USERS
]
?.
value
==
true
fun
PublicSettings
.
uploadMimeTypeFilter
():
Array
<
String
>?
{
val
values
=
this
[
UPLOAD_WHITELIST_MIMETYPES
]
?.
value
as
String
?
if
(!
values
.
isNullOrBlank
())
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment