mirror of
https://github.com/Kunzisoft/KeePassDX.git
synced 2025-12-04 15:49:33 +01:00
Change upload icon
This commit is contained in:
@@ -124,6 +124,7 @@ class AttachmentFileNotificationService: LockNotificationService() {
|
||||
return START_REDELIVER_INTENT
|
||||
}
|
||||
|
||||
@Synchronized
|
||||
fun checkCurrentAttachmentProgress() {
|
||||
attachmentNotificationList.forEach { attachmentNotification ->
|
||||
mActionTaskListeners.forEach { actionListener ->
|
||||
@@ -135,6 +136,7 @@ class AttachmentFileNotificationService: LockNotificationService() {
|
||||
}
|
||||
}
|
||||
|
||||
@Synchronized
|
||||
fun removeAttachmentAction(entryAttachment: EntryAttachmentState) {
|
||||
attachmentNotificationList.firstOrNull {
|
||||
it.entryAttachmentState == entryAttachment
|
||||
@@ -164,12 +166,13 @@ class AttachmentFileNotificationService: LockNotificationService() {
|
||||
val fileName = DocumentFile.fromSingleUri(this, attachmentNotification.uri)?.name ?: ""
|
||||
|
||||
val builder = buildNewNotification().apply {
|
||||
setSmallIcon(R.drawable.ic_file_download_white_24dp)
|
||||
when (attachmentNotification.streamDirection) {
|
||||
AttachmentFileAction.StreamDirection.UPLOAD -> {
|
||||
setSmallIcon(R.drawable.ic_file_upload_white_24dp)
|
||||
setContentTitle(getString(R.string.upload_attachment, fileName))
|
||||
}
|
||||
AttachmentFileAction.StreamDirection.DOWNLOAD -> {
|
||||
setSmallIcon(R.drawable.ic_file_download_white_24dp)
|
||||
setContentTitle(getString(R.string.download_attachment, fileName))
|
||||
}
|
||||
}
|
||||
|
||||
5
app/src/main/res/drawable/ic_file_upload_white_24dp.xml
Normal file
5
app/src/main/res/drawable/ic_file_upload_white_24dp.xml
Normal file
@@ -0,0 +1,5 @@
|
||||
<rotate xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:drawable="@drawable/ic_file_download_white_24dp"
|
||||
android:fromDegrees="180"
|
||||
android:toDegrees="180"
|
||||
android:visible="true" />
|
||||
Reference in New Issue
Block a user