Feature/lucide icons pt3 (#864)

* Starting to import Lucide icons and clean up

* Removing unused icons

* Lucide icons + removing unsued stuff

Removed the whole EMoji/MediaKeyboard classes as they didn't seem used

* More Lucide icons + ui tweaks + clean up

* comment

* Wrong tinting

* delete icon

* More icons

* check icons

* edit icon (ic_pencil)

* edit icon

* Search icon (ic_search)

* settings icons (ic_settings)

* back icon (ic_chevron_left)

* icon forward arrow (ic_chevron_right)

* icon circle dots (ic_circle_dots_custom)

* icon read (ic_eye)

* icon disappearing messages (ic_clock_x)

* refresh icon (ic_refresh_cw)

* globe icon

* message icon (ic_message_square)

* icon message request (ic_message_square_warning)

* group and invite icons (ic_users_group_custom, ic_user_round_plus))

* icons: lock, unlock, audio/notification (ic_lock_keyhole, ic_lock_keyhole_open, ic_volume_2, ic_volume_off )

* icon mute / mic off (ic_mic_off)

* icon appearance, recovery (ic_paintbrush_vertical, ic_recovery_password_custom)

* icons: help, help circle, qr code

* icon block/ban

* close icon (ic_x)

* pin/unpin icons

* switch camera icon (ic_switch_camera)

* warning icon (ic_triangle_alert)

* phone icons

* share icon  + clean up unused files

* mark as read icon + clean up

* default video placeholder + clean up

Removed the caption icon from the media rail
Cleaned up logic for thumbnail error and placeholder

* Clean up
pull/1710/head
ThomasSession 3 months ago committed by GitHub
parent b2e8b1ccc5
commit 2c4a6f04c8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -308,7 +308,7 @@ public class PassphrasePromptActivity extends BaseActionBarActivity {
public void onAuthenticationFailed() {
Log.w(TAG, "onAuthenticationFailed()");
fingerprintPrompt.setImageResource(R.drawable.ic_close_white_48dp);
fingerprintPrompt.setImageResource(R.drawable.ic_x);
fingerprintPrompt.getBackground().setColorFilter(errorColor, PorterDuff.Mode.SRC_IN);
TranslateAnimation shake = new TranslateAnimation(0, 30, 0, 0);

@ -17,6 +17,7 @@ import android.widget.Space
import android.widget.TextView
import androidx.annotation.AttrRes
import androidx.annotation.ColorRes
import androidx.annotation.DrawableRes
import androidx.annotation.LayoutRes
import androidx.annotation.StringRes
import androidx.annotation.StyleRes
@ -111,8 +112,6 @@ class SessionDialogBuilder(val context: Context) {
fun view(@LayoutRes layout: Int): View = LayoutInflater.from(context).inflate(layout, contentView)
fun iconAttribute(@AttrRes icon: Int): AlertDialog.Builder = dialogBuilder.setIconAttribute(icon)
fun singleChoiceItems(
options: Collection<String>,
currentSelected: Int = 0,

@ -1,68 +0,0 @@
package org.thoughtcrime.securesms.components;
import android.content.Context;
import android.content.res.TypedArray;
import android.util.AttributeSet;
import android.view.View;
import android.widget.ImageView;
import android.widget.LinearLayout;
import network.loki.messenger.R;
public class ConversationItemAlertView extends LinearLayout {
private static final String TAG = ConversationItemAlertView.class.getSimpleName();
private ImageView approvalIndicator;
private ImageView failedIndicator;
public ConversationItemAlertView(Context context) {
this(context, null);
}
public ConversationItemAlertView(Context context, AttributeSet attrs) {
super(context, attrs);
initialize(attrs);
}
public ConversationItemAlertView(final Context context, AttributeSet attrs, int defStyle) {
super(context, attrs, defStyle);
initialize(attrs);
}
private void initialize(AttributeSet attrs) {
inflate(getContext(), R.layout.alert_view, this);
approvalIndicator = findViewById(R.id.pending_approval_indicator);
failedIndicator = findViewById(R.id.sms_failed_indicator);
if (attrs != null) {
TypedArray typedArray = getContext().getTheme().obtainStyledAttributes(attrs, R.styleable.AlertView, 0, 0);
boolean useSmallIcon = typedArray.getBoolean(R.styleable.AlertView_useSmallIcon, false);
typedArray.recycle();
if (useSmallIcon) {
int size = getResources().getDimensionPixelOffset(R.dimen.alertview_small_icon_size);
failedIndicator.getLayoutParams().width = size;
failedIndicator.getLayoutParams().height = size;
requestLayout();
}
}
}
public void setNone() {
this.setVisibility(View.GONE);
}
public void setPendingApproval() {
this.setVisibility(View.VISIBLE);
approvalIndicator.setVisibility(View.VISIBLE);
failedIndicator.setVisibility(View.GONE);
}
public void setFailed() {
this.setVisibility(View.VISIBLE);
approvalIndicator.setVisibility(View.GONE);
failedIndicator.setVisibility(View.VISIBLE);
}
}

@ -39,7 +39,7 @@ public class SearchToolbar extends Toolbar {
}
private void initialize() {
setNavigationIcon(getContext().getResources().getDrawable(R.drawable.ic_baseline_clear_24));
setNavigationIcon(getContext().getResources().getDrawable(R.drawable.ic_x));
inflateMenu(R.menu.conversation_list_search);
this.searchItem = getMenu().findItem(R.id.action_filter_search);

@ -1,182 +0,0 @@
package org.thoughtcrime.securesms.components
import android.animation.LayoutTransition
import android.content.Context
import android.util.AttributeSet
import android.view.View
import android.widget.FrameLayout
import android.widget.TextView
import androidx.core.content.ContextCompat
import com.annimon.stream.Stream
import com.pnikosis.materialishprogress.ProgressWheel
import kotlin.math.max
import network.loki.messenger.R
import org.greenrobot.eventbus.EventBus
import org.greenrobot.eventbus.Subscribe
import org.greenrobot.eventbus.ThreadMode
import org.session.libsession.messaging.sending_receiving.attachments.Attachment
import org.session.libsession.messaging.sending_receiving.attachments.AttachmentTransferProgress
import org.session.libsession.utilities.StringSubstitutionConstants.COUNT_KEY
import org.session.libsession.utilities.ViewUtil
import org.thoughtcrime.securesms.events.PartProgressEvent
import org.thoughtcrime.securesms.mms.Slide
import org.thoughtcrime.securesms.ui.getSubbedString
class TransferControlView @JvmOverloads constructor(context: Context?, attrs: AttributeSet? = null, defStyleAttr: Int = 0) : FrameLayout(context!!, attrs, defStyleAttr) {
private var slides: List<Slide>? = null
private var current: View? = null
private val progressWheel: ProgressWheel
private val downloadDetails: View
private val downloadDetailsText: TextView
private val downloadProgress: MutableMap<Attachment, Float>
init {
inflate(context, R.layout.transfer_controls_view, this)
isLongClickable = false
ViewUtil.setBackground(this, ContextCompat.getDrawable(context!!, R.drawable.transfer_controls_background))
visibility = GONE
layoutTransition = LayoutTransition()
this.downloadProgress = HashMap()
this.progressWheel = ViewUtil.findById(this, R.id.progress_wheel)
this.downloadDetails = ViewUtil.findById(this, R.id.download_details)
this.downloadDetailsText = ViewUtil.findById(this, R.id.download_details_text)
}
override fun setFocusable(focusable: Boolean) {
super.setFocusable(focusable)
downloadDetails.isFocusable = focusable
}
override fun setClickable(clickable: Boolean) {
super.setClickable(clickable)
downloadDetails.isClickable = clickable
}
override fun onAttachedToWindow() {
super.onAttachedToWindow()
if (!EventBus.getDefault().isRegistered(this)) EventBus.getDefault().register(this)
}
override fun onDetachedFromWindow() {
super.onDetachedFromWindow()
EventBus.getDefault().unregister(this)
}
private fun setSlides(slides: List<Slide>) {
require(slides.isNotEmpty()) { "Must provide at least one slide." }
this.slides = slides
if (!isUpdateToExistingSet(slides)) {
downloadProgress.clear()
Stream.of(slides).forEach { s: Slide -> downloadProgress[s.asAttachment()] = 0f }
}
for (slide in slides) {
if (slide.asAttachment().transferState == AttachmentTransferProgress.TRANSFER_PROGRESS_DONE) {
downloadProgress[slide.asAttachment()] = 1f
}
}
when (getTransferState(slides)) {
AttachmentTransferProgress.TRANSFER_PROGRESS_STARTED -> showProgressSpinner(calculateProgress(downloadProgress))
AttachmentTransferProgress.TRANSFER_PROGRESS_PENDING, AttachmentTransferProgress.TRANSFER_PROGRESS_FAILED -> {
downloadDetailsText.text = getDownloadText(this.slides!!)
display(downloadDetails)
}
else -> display(null)
}
}
@JvmOverloads
fun showProgressSpinner(progress: Float = calculateProgress(downloadProgress)) {
if (progress == 0f) {
progressWheel.spin()
} else {
progressWheel.setInstantProgress(progress)
}
display(progressWheel)
}
fun clear() {
clearAnimation()
visibility = GONE
if (current != null) {
current!!.clearAnimation()
current!!.visibility = GONE
}
current = null
slides = null
}
private fun isUpdateToExistingSet(slides: List<Slide>): Boolean {
if (slides.size != downloadProgress.size) {
return false
}
for (slide in slides) {
if (!downloadProgress.containsKey(slide.asAttachment())) {
return false
}
}
return true
}
private fun getTransferState(slides: List<Slide>): Int {
var transferState = AttachmentTransferProgress.TRANSFER_PROGRESS_DONE
for (slide in slides) {
transferState = if (slide.transferState == AttachmentTransferProgress.TRANSFER_PROGRESS_PENDING && transferState == AttachmentTransferProgress.TRANSFER_PROGRESS_DONE) {
slide.transferState
} else {
max(transferState.toDouble(), slide.transferState.toDouble()).toInt()
}
}
return transferState
}
private fun getDownloadText(slides: List<Slide>): String {
if (slides.size == 1) {
return slides[0].contentDescription
} else {
val downloadCount = Stream.of(slides).reduce(0) { count: Int, slide: Slide ->
if (slide.transferState != AttachmentTransferProgress.TRANSFER_PROGRESS_DONE) count + 1 else count
}
return context.getSubbedString(R.string.andMore, COUNT_KEY to downloadCount.toString())
}
}
private fun display(view: View?) {
if (current != null) {
current!!.visibility = GONE
}
if (view != null) {
view.visibility = VISIBLE
} else {
visibility = GONE
}
current = view
}
private fun calculateProgress(downloadProgress: Map<Attachment, Float>): Float {
var totalProgress = 0f
for (progress in downloadProgress.values) {
totalProgress += progress / downloadProgress.size
}
return totalProgress
}
@Subscribe(sticky = true, threadMode = ThreadMode.MAIN)
fun onEventAsync(event: PartProgressEvent) {
if (downloadProgress.containsKey(event.attachment)) {
downloadProgress[event.attachment] = event.progress.toFloat() / event.total
progressWheel.setInstantProgress(calculateProgress(downloadProgress))
}
}
}

@ -1,18 +0,0 @@
package org.thoughtcrime.securesms.components.dialogs
import android.content.Context
import network.loki.messenger.R
import org.thoughtcrime.securesms.showSessionDialog
class DeleteMediaDialog {
companion object {
@JvmStatic
fun show(context: Context, recordCount: Int, doDelete: Runnable) = context.showSessionDialog {
iconAttribute(R.attr.dialog_alert_icon)
title(context.resources.getQuantityString(R.plurals.deleteMessage, recordCount, recordCount))
text(context.resources.getString(R.string.deleteMessageDescriptionEveryone))
dangerButton(R.string.delete) { doDelete.run() }
cancelButton()
}
}
}

@ -9,7 +9,6 @@ class DeleteMediaPreviewDialog {
@JvmStatic
fun show(context: Context, doDelete: Runnable) {
context.showSessionDialog {
iconAttribute(R.attr.dialog_alert_icon)
title(context.resources.getQuantityString(R.plurals.deleteMessage, 1, 1))
text(R.string.deleteMessageDescriptionEveryone)
dangerButton(R.string.delete) { doDelete.run() }

@ -3,11 +3,15 @@ package org.thoughtcrime.securesms.conversation.v2.messages
import android.Manifest
import android.content.Context
import android.content.Intent
import android.graphics.Bitmap
import android.graphics.drawable.BitmapDrawable
import android.util.AttributeSet
import android.view.LayoutInflater
import android.view.View
import android.widget.LinearLayout
import androidx.compose.ui.graphics.Color
import androidx.core.content.res.ResourcesCompat
import androidx.core.graphics.drawable.toBitmap
import androidx.core.view.isGone
import androidx.core.view.isVisible
import androidx.recyclerview.widget.RecyclerView
@ -57,6 +61,10 @@ class ControlMessageView : LinearLayout {
val controlContentView: View get() = binding.controlContentView
val iconSize by lazy {
resources.getDimensionPixelSize(R.dimen.medium_spacing)
}
init {
layoutParams = RecyclerView.LayoutParams(RecyclerView.LayoutParams.MATCH_PARENT, RecyclerView.LayoutParams.WRAP_CONTENT)
}
@ -127,15 +135,30 @@ class ControlMessageView : LinearLayout {
binding.root.contentDescription = context.getString(R.string.AccessibilityId_message_request_config_message)
}
message.isCallLog -> {
val drawable = when {
message.isIncomingCall -> R.drawable.ic_incoming_call
message.isOutgoingCall -> R.drawable.ic_outgoing_call
val drawableRes = when {
message.isIncomingCall -> R.drawable.ic_phone_incoming
message.isOutgoingCall -> R.drawable.ic_phone_outgoing
else -> R.drawable.ic_missed_call
}
// Since this is using text drawable we need to go the long way around to size and style the drawable
// We could set the colour and style directly in the drawable's xml but it then makes it non reusable
// This will all be simplified once we turn this all to Compose
val icon = ResourcesCompat.getDrawable(resources, drawableRes, context.theme)?.toBitmap()
icon?.let{
val drawable = BitmapDrawable(resources, Bitmap.createScaledBitmap(icon, iconSize, iconSize, true));
binding.callTextView.setCompoundDrawablesRelativeWithIntrinsicBounds(
drawable,null, null, null)
val iconTint = when {
message.isIncomingCall || message.isOutgoingCall -> R.attr.message_received_text_color
else -> R.attr.danger
}
drawable.setTint(context.getColorFromAttr(iconTint))
}
binding.textView.isVisible = false
binding.callTextView.setCompoundDrawablesRelativeWithIntrinsicBounds(
ResourcesCompat.getDrawable(resources, drawable, context.theme),
null, null, null)
binding.callTextView.text = messageBody
if (message.expireStarted > 0 && message.expiresIn > 0) {

@ -394,13 +394,13 @@ class VisibleMessageView : FrameLayout {
private fun getMessageStatusInfo(message: MessageRecord): MessageStatusInfo? = when {
message.isFailed ->
MessageStatusInfo(R.drawable.ic_delivery_status_failed,
MessageStatusInfo(R.drawable.ic_triangle_alert,
getThemedColor(context, R.attr.danger),
R.string.messageStatusFailedToSend
)
message.isSyncFailed ->
MessageStatusInfo(
R.drawable.ic_delivery_status_failed,
R.drawable.ic_triangle_alert,
context.getColor(R.color.accent_orange),
R.string.messageStatusFailedToSync
)

@ -6,29 +6,27 @@ import android.graphics.Outline
import android.graphics.drawable.Drawable
import android.net.Uri
import android.util.AttributeSet
import android.util.TypedValue
import android.view.View
import android.view.ViewOutlineProvider
import android.view.ViewTreeObserver
import android.widget.FrameLayout
import androidx.core.content.res.ResourcesCompat
import androidx.core.view.isVisible
import com.bumptech.glide.RequestBuilder
import com.bumptech.glide.RequestManager
import com.bumptech.glide.load.engine.DiskCacheStrategy
import com.bumptech.glide.load.resource.bitmap.CenterCrop
import com.bumptech.glide.load.resource.bitmap.RoundedCorners
import com.bumptech.glide.load.resource.drawable.DrawableTransitionOptions
import com.bumptech.glide.request.RequestOptions
import network.loki.messenger.R
import network.loki.messenger.databinding.ThumbnailViewBinding
import org.session.libsession.messaging.sending_receiving.attachments.AttachmentTransferProgress
import org.session.libsession.utilities.Util.equals
import org.session.libsession.utilities.getColorFromAttr
import org.session.libsignal.utilities.ListenableFuture
import org.session.libsignal.utilities.SettableFuture
import org.thoughtcrime.securesms.components.GlideBitmapListeningTarget
import org.thoughtcrime.securesms.components.GlideDrawableListeningTarget
import org.thoughtcrime.securesms.mms.DecryptableStreamUriLoader.DecryptableUri
import com.bumptech.glide.RequestBuilder
import com.bumptech.glide.RequestManager
import org.session.libsignal.utilities.Log
import org.thoughtcrime.securesms.mms.Slide
import org.thoughtcrime.securesms.ui.afterMeasured
import java.lang.Float.min
@ -54,6 +52,12 @@ open class ThumbnailView @JvmOverloads constructor(
private var slide: Slide? = null
private val errorDrawable by lazy {
val drawable = ResourcesCompat.getDrawable(resources, R.drawable.ic_triangle_alert, context.theme)
drawable?.setTint(context.getColorFromAttr(android.R.attr.textColorTertiary))
drawable
}
init {
attrs?.let { context.theme.obtainStyledAttributes(it, R.styleable.ThumbnailView, 0, 0) }
?.apply {
@ -178,7 +182,7 @@ open class ThumbnailView @JvmOverloads constructor(
.overrideDimensions()
.transition(DrawableTransitionOptions.withCrossFade())
.transform(CenterCrop())
.missingThumbnailPicture(slide.isInProgress)
.missingThumbnailPicture(slide.isInProgress, errorDrawable)
private fun buildPlaceholderGlideRequest(
glide: RequestManager,
@ -186,8 +190,6 @@ open class ThumbnailView @JvmOverloads constructor(
): RequestBuilder<Bitmap> = glide.asBitmap()
.load(slide.getPlaceholderRes(context.theme))
.diskCacheStrategy(DiskCacheStrategy.NONE)
.overrideDimensions()
.fitCenter()
open fun clear(glideRequests: RequestManager) {
glideRequests.clear(binding.thumbnailImage)
@ -217,5 +219,6 @@ open class ThumbnailView @JvmOverloads constructor(
}
private fun <T> RequestBuilder<T>.missingThumbnailPicture(
inProgress: Boolean
) = takeIf { inProgress } ?: apply(RequestOptions.errorOf(R.drawable.ic_missing_thumbnail_picture)) //todo ICONS replace with /!\ and test tint
inProgress: Boolean,
errorDrawable: Drawable?
) = takeIf { inProgress } ?: apply(RequestOptions.errorOf(errorDrawable))

@ -1,6 +1,7 @@
package org.thoughtcrime.securesms.home
import android.content.Context
import android.content.res.ColorStateList
import android.content.res.Resources
import android.graphics.Typeface
import android.graphics.drawable.ColorDrawable
@ -51,14 +52,9 @@ class ConversationView : LinearLayout {
fun bind(thread: ThreadRecord, isTyping: Boolean, overriddenSnippet: CharSequence?) {
this.thread = thread
if (thread.isPinned) {
binding.conversationViewDisplayNameTextView.setCompoundDrawablesRelativeWithIntrinsicBounds(
0,
0,
R.drawable.ic_pin,
0
)
binding.iconPinned.isVisible = true
} else {
binding.conversationViewDisplayNameTextView.setCompoundDrawablesRelativeWithIntrinsicBounds(0, 0, 0, 0)
binding.iconPinned.isVisible = false
}
binding.root.background = if (thread.unreadCount > 0) {
ContextCompat.getDrawable(context, R.drawable.conversation_unread_background)
@ -122,12 +118,13 @@ class ConversationView : LinearLayout {
}
binding.typingIndicatorView.root.visibility = if (isTyping) View.VISIBLE else View.GONE
binding.statusIndicatorImageView.visibility = View.VISIBLE
binding.statusIndicatorImageView.imageTintList = ColorStateList.valueOf(ThemeUtil.getThemedColor(context, android.R.attr.textColorTertiary)) // tertiary in the current xml styling is actually what figma uses as secondary text color...
when {
!thread.isOutgoing -> binding.statusIndicatorImageView.visibility = View.GONE
thread.isFailed -> {
val drawable = ContextCompat.getDrawable(context, R.drawable.ic_error)?.mutate()
drawable?.setTint(ThemeUtil.getThemedColor(context, R.attr.danger))
val drawable = ContextCompat.getDrawable(context, R.drawable.ic_triangle_alert)?.mutate()
binding.statusIndicatorImageView.setImageDrawable(drawable)
binding.statusIndicatorImageView.imageTintList = ColorStateList.valueOf(ThemeUtil.getThemedColor(context, R.attr.danger))
}
thread.isPending -> binding.statusIndicatorImageView.setImageResource(R.drawable.ic_circle_dots_custom)
thread.isRead -> binding.statusIndicatorImageView.setImageResource(R.drawable.ic_circle_check)

@ -153,30 +153,20 @@ private fun ThumbnailRow(
it.diskCacheStrategy(DiskCacheStrategy.NONE)
}
} else {
// The resource given by the placeholder needs tinting according to our theme.
// But the missing thumbnail picture does not.
//todo ICONS replace with /!\ and simplify logic >> Do we need a bg for broken image? right now the icon is floating
var (placeholder, shouldTint) = if (item.hasPlaceholder) {
item.placeholder(LocalContext.current) to true
val placeholder = if (item.hasPlaceholder) {
item.placeholder(LocalContext.current)
} else {
R.drawable.ic_missing_thumbnail_picture to false
R.drawable.ic_triangle_alert
}
if (placeholder == 0) {
placeholder = R.drawable.ic_missing_thumbnail_picture
shouldTint = false
}
Image(
painter = painterResource(placeholder),
contentDescription = null,
modifier = Modifier.fillMaxSize(),
contentScale = ContentScale.Inside,
colorFilter = if (shouldTint) {
ColorFilter.tint(LocalColors.current.textSecondary)
} else {
null
}
colorFilter = ColorFilter.tint(LocalColors.current.textSecondary)
)
}

@ -138,14 +138,12 @@ public class MediaRailAdapter extends RecyclerView.Adapter<MediaRailAdapter.Medi
private final ThumbnailView image;
private final View outline;
private final View deleteButton;
private final View captionIndicator;
MediaViewHolder(@NonNull View itemView) {
super(itemView);
image = itemView.findViewById(R.id.rail_item_image);
outline = itemView.findViewById(R.id.rail_item_outline);
deleteButton = itemView.findViewById(R.id.rail_item_delete);
captionIndicator = itemView.findViewById(R.id.rail_item_caption);
}
void bind(@NonNull Media media, boolean isActive, @NonNull RequestManager glideRequests,
@ -158,8 +156,6 @@ public class MediaRailAdapter extends RecyclerView.Adapter<MediaRailAdapter.Medi
outline.setVisibility(isActive ? View.VISIBLE : View.GONE);
captionIndicator.setVisibility(media.getCaption().isPresent() ? View.VISIBLE : View.GONE);
if (editable && isActive) {
deleteButton.setVisibility(View.VISIBLE);
deleteButton.setOnClickListener(v -> railItemListener.onRailItemDeleteClicked(distanceFromActive));

@ -55,7 +55,7 @@ public class VideoSlide extends Slide {
@Override
public @DrawableRes int getPlaceholderRes(Theme theme) {
return ResUtil.getDrawableRes(theme, R.attr.conversation_icon_attach_video);
return R.drawable.ic_square_play;
}
@Override

@ -162,7 +162,7 @@ class SettingsActivity : PassphraseRequiredActionBarActivity() {
setContentView(binding.root)
// set the toolbar icon to a close icon
supportActionBar?.setHomeAsUpIndicator(R.drawable.ic_baseline_close_24)
supportActionBar?.setHomeAsUpIndicator(R.drawable.ic_x)
// set the compose dialog content
binding.avatarDialog.setThemedContent {

@ -108,7 +108,7 @@ fun AlertDialog(
modifier = Modifier.align(Alignment.TopEnd)
) {
Icon(
painter = painterResource(id = R.drawable.ic_dialog_x),
painter = painterResource(id = R.drawable.ic_x),
tint = LocalColors.current.text,
contentDescription = "back"
)

@ -46,7 +46,7 @@ class CallNotificationBuilder {
val builder = NotificationCompat.Builder(context, NotificationChannels.CALLS)
.setSound(null)
.setSmallIcon(R.drawable.ic_baseline_call_24)
.setSmallIcon(R.drawable.ic_phone)
.setContentIntent(pendingIntent)
.setOngoing(true)
@ -69,7 +69,7 @@ class CallNotificationBuilder {
builder.addAction(getServiceNotificationAction(
context,
WebRtcCallService.ACTION_DENY_CALL,
R.drawable.ic_close_grey600_32dp,
R.drawable.ic_x,
R.string.decline
))
// If notifications aren't enabled, we will trigger the intent from WebRtcCallService
@ -77,7 +77,7 @@ class CallNotificationBuilder {
builder.addAction(getActivityNotificationAction(
context,
if (type == TYPE_INCOMING_PRE_OFFER) WebRtcCallActivity.ACTION_PRE_OFFER else WebRtcCallActivity.ACTION_ANSWER,
R.drawable.ic_phone_grey600_32dp,
R.drawable.ic_phone,
R.string.accept
))
builder.priority = NotificationCompat.PRIORITY_MAX
@ -87,7 +87,7 @@ class CallNotificationBuilder {
builder.addAction(getServiceNotificationAction(
context,
WebRtcCallService.ACTION_LOCAL_HANGUP,
R.drawable.ic_call_end_grey600_32dp,
R.drawable.ic_phone_fill_custom,
R.string.cancel
))
}
@ -96,7 +96,7 @@ class CallNotificationBuilder {
builder.addAction(getServiceNotificationAction(
context,
WebRtcCallService.ACTION_LOCAL_HANGUP,
R.drawable.ic_call_end_grey600_32dp,
R.drawable.ic_phone_fill_custom,
R.string.callsEnd
)).setUsesChronometer(true)
}

@ -55,7 +55,6 @@ class SaveAttachmentTask @JvmOverloads constructor(context: Context, count: Int
// potential risks of other apps accessing their saved attachments.
context.showSessionDialog {
title(R.string.warning)
iconAttribute(R.attr.dialog_alert_icon)
text(context.getString(R.string.attachmentsWarning))
dangerButton(R.string.save) {
// Set our 'haveWarned' SharedPref and perform the save on accept

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:color="@color/call_action_foreground_highlighted" android:state_selected="true"/>
<item android:color="@color/call_action_foreground"/>
<item android:color="@color/white"/>
</selector>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 834 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 404 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 966 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 123 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 327 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 585 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 662 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 276 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 201 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 347 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 595 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 291 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 568 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 350 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 569 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 371 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 211 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 273 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 941 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 350 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 847 B

@ -1,9 +0,0 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="50"
android:viewportHeight="50">
<path
android:pathData="M34.425,36.527L19.159,24.147L34.753,11.491C34.947,11.342 35.111,11.152 35.236,10.933C35.361,10.714 35.443,10.471 35.479,10.217C35.515,9.963 35.504,9.704 35.446,9.455C35.387,9.206 35.284,8.972 35.14,8.767C34.996,8.562 34.816,8.39 34.61,8.261C34.404,8.132 34.176,8.049 33.939,8.016C33.702,7.983 33.462,8.001 33.232,8.07C33.002,8.139 32.787,8.256 32.6,8.416L15.545,22.254C15.363,22.406 15.208,22.592 15.09,22.804C15.007,22.888 14.93,22.978 14.86,23.074C14.574,23.482 14.451,23.995 14.517,24.501C14.584,25.006 14.834,25.463 15.212,25.77L32.268,39.609C32.455,39.762 32.668,39.873 32.896,39.937C33.123,40.001 33.36,40.016 33.593,39.982C33.826,39.947 34.05,39.863 34.252,39.735C34.455,39.607 34.632,39.437 34.773,39.235C34.916,39.032 35.02,38.802 35.079,38.556C35.139,38.311 35.153,38.055 35.121,37.803C35.089,37.552 35.011,37.31 34.891,37.091C34.772,36.872 34.614,36.68 34.425,36.527Z"
android:fillColor="#000000"/>
</vector>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 118 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 286 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 377 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 329 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 199 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 149 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 257 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 442 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 232 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 397 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 238 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 384 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 265 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 272 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 188 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 596 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 298 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 442 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 152 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 532 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 758 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 682 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 308 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 221 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 436 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 758 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 315 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 811 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 433 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 750 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 456 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 452 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 312 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 532 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 177 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 699 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 628 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 386 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 302 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 524 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 426 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 610 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 675 B

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save