0
0
mirror of https://github.com/ankidroid/Anki-Android.git synced 2024-09-20 03:52:15 +02:00

Fix whiteboard stroke width button visibility on black themes

This commit is contained in:
lukstbit 2022-06-01 06:02:13 +03:00 committed by Mike Hardy
parent 8491ebea17
commit 69f6e94e74
2 changed files with 6 additions and 3 deletions

View File

@ -20,6 +20,7 @@ package com.ichi2.anki
import android.annotation.SuppressLint
import android.graphics.*
import android.graphics.drawable.VectorDrawable
import android.net.Uri
import android.view.MotionEvent
import android.view.View
@ -536,6 +537,9 @@ class Whiteboard(activity: AnkiActivity, handleMultiTouch: Boolean, inverted: Bo
activity.findViewById<View>(R.id.pen_color_green).setOnClickListener { view: View -> onClick(view) }
activity.findViewById<View>(R.id.pen_color_blue).setOnClickListener { view: View -> onClick(view) }
activity.findViewById<View>(R.id.pen_color_yellow).setOnClickListener { view: View -> onClick(view) }
activity.findViewById<View>(R.id.stroke_width).setOnClickListener { view: View -> onClick(view) }
activity.findViewById<View>(R.id.stroke_width).apply {
setOnClickListener { view: View -> onClick(view) }
(background as? VectorDrawable)?.setTint(foregroundColor)
}
}
}

View File

@ -39,7 +39,6 @@
<Button
android:id="@+id/stroke_width"
android:background="@drawable/ic_mode_edit_white"
android:backgroundTint="@color/black"
style="@style/reviewer_whiteboard_editor_button_style"/>
</LinearLayout>
</LinearLayout>