Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ class ChatDetailFragment : Fragment() {
private fun createProviderButton(context: Context, providerName: String, modelName: String): Button =
Button(context).apply {
text = providerName.lowercase(Locale.getDefault())
setTextColor(ContextCompat.getColor(context, R.color.md_black_1000))
setTextColor(ContextCompat.getColor(context, com.mikepenz.materialize.R.color.md_black_1000))
textSize = 18f
setTypeface(null, Typeface.BOLD)
setPadding(16, 8, 16, 8)
Expand Down Expand Up @@ -350,7 +350,7 @@ class ChatDetailFragment : Fragment() {
view.setTextColor(ContextCompat.getColor(context, R.color.textColorPrimary))
} else {
view.setBackgroundColor(ContextCompat.getColor(context, R.color.disable_color))
view.setTextColor(ContextCompat.getColor(context, R.color.md_black_1000))
view.setTextColor(ContextCompat.getColor(context, com.mikepenz.materialize.R.color.md_black_1000))
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ class AdapterProgressGrid(private val context: Context, private val list: JsonAr
if (list[position].asJsonObject.has("percentage")) {
holder.tvProgress.text = context.getString(R.string.percentage, list[position].asJsonObject["percentage"].asString)
if (list[position].asJsonObject["completed"].asBoolean) {
holder.itemView.setBackgroundColor(ContextCompat.getColor(context, R.color.md_green_500))
holder.itemView.setBackgroundColor(ContextCompat.getColor(context, com.mikepenz.materialize.R.color.md_green_500))
} else {
holder.itemView.setBackgroundColor(ContextCompat.getColor(context, R.color.md_yellow_500))
holder.itemView.setBackgroundColor(ContextCompat.getColor(context, com.mikepenz.materialize.R.color.md_yellow_500))
}
} else {
holder.itemView.setBackgroundColor(ContextCompat.getColor(context, R.color.mainColor))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ class TakeCourseFragment : Fragment(), ViewPager.OnPageChangeListener, View.OnCl
} else {
binding.nextStep.visibility = View.VISIBLE
binding.nextStep.isClickable = true
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), R.color.md_white_1000))
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), com.mikepenz.materialize.R.color.md_white_1000))
}

updateStepDisplay(position)
Expand All @@ -240,14 +240,14 @@ class TakeCourseFragment : Fragment(), ViewPager.OnPageChangeListener, View.OnCl
if (courseId == "4e6b78800b6ad18b4e8b0e1e38a98cac") {
if (isStepCompleted(mRealm, steps[position - 1]?.id, userModel?.id)) {
binding.nextStep.isClickable = true
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), R.color.md_white_1000))
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), com.mikepenz.materialize.R.color.md_white_1000))
} else {
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), R.color.md_grey_500))
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), com.mikepenz.materialize.R.color.md_grey_500))
binding.nextStep.isClickable = false
}
} else {
binding.nextStep.isClickable = true
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), R.color.md_white_1000))
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), com.mikepenz.materialize.R.color.md_white_1000))
}
}

Expand All @@ -256,11 +256,11 @@ class TakeCourseFragment : Fragment(), ViewPager.OnPageChangeListener, View.OnCl
private fun onClickNext() {
binding.tvStep.text = String.format(Locale.getDefault(), "${getString(R.string.step)} %d/%d", binding.viewPager2.currentItem, steps.size)
if (binding.viewPager2.currentItem >= steps.size - 1) {
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), R.color.md_grey_500))
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), com.mikepenz.materialize.R.color.md_grey_500))
binding.nextStep.visibility = View.GONE
binding.finishStep.visibility = View.VISIBLE
} else {
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), R.color.md_white_1000))
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), com.mikepenz.materialize.R.color.md_white_1000))
binding.nextStep.visibility = View.VISIBLE
binding.finishStep.visibility = View.GONE
}
Expand All @@ -273,7 +273,7 @@ class TakeCourseFragment : Fragment(), ViewPager.OnPageChangeListener, View.OnCl
binding.nextStep.visibility = View.VISIBLE
binding.finishStep.visibility = View.GONE
}else{
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), R.color.md_white_1000))
binding.nextStep.setTextColor(ContextCompat.getColor(requireContext(), com.mikepenz.materialize.R.color.md_white_1000))
binding.nextStep.visibility = View.VISIBLE
binding.finishStep.visibility = View.GONE
}
Expand Down Expand Up @@ -340,7 +340,7 @@ class TakeCourseFragment : Fragment(), ViewPager.OnPageChangeListener, View.OnCl
Toast.makeText(context, getString(R.string.please_complete_survey), Toast.LENGTH_SHORT).show() }
} else {
binding.finishStep.isEnabled = true
binding.finishStep.setTextColor(ContextCompat.getColor(requireContext(), R.color.md_white_1000))
binding.finishStep.setTextColor(ContextCompat.getColor(requireContext(), com.mikepenz.materialize.R.color.md_white_1000))
binding.finishStep.setOnClickListener {
NavigationHelper.popBackStack(requireActivity().supportFragmentManager)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,15 +125,15 @@ class BellDashboardFragment : BaseDashboardFragment() {
}

private suspend fun handleConnectingState() {
setNetworkIndicatorColor(R.color.md_yellow_600)
setNetworkIndicatorColor(com.mikepenz.materialize.R.color.md_yellow_600)
val updateUrl = settings.getString("serverURL", "") ?: return
val mapping = ServerUrlMapper().processUrl(updateUrl)
try {
val reachable = isServerReachable(mapping)
setNetworkIndicatorColor(if (reachable) R.color.green else R.color.md_yellow_600)
setNetworkIndicatorColor(if (reachable) R.color.green else com.mikepenz.materialize.R.color.md_yellow_600)
} catch (e: Exception) {
e.printStackTrace()
setNetworkIndicatorColor(R.color.md_yellow_600)
setNetworkIndicatorColor(com.mikepenz.materialize.R.color.md_yellow_600)
}
}

Expand All @@ -142,7 +142,7 @@ class BellDashboardFragment : BaseDashboardFragment() {
context ?: return

when (status) {
is NetworkStatus.Disconnected -> setNetworkIndicatorColor(R.color.md_red_700)
is NetworkStatus.Disconnected -> setNetworkIndicatorColor(com.mikepenz.materialize.R.color.md_red_700)
is NetworkStatus.Connecting -> handleConnectingState()
is NetworkStatus.Connected -> setNetworkIndicatorColor(R.color.green)
}
Expand Down Expand Up @@ -393,7 +393,7 @@ class BellDashboardFragment : BaseDashboardFragment() {
if (RealmCertification.isCourseCertified(mRealm, courseId)) {
star.setColorFilter(ContextCompat.getColor(requireContext(), R.color.colorPrimary))
} else {
star.setColorFilter(ContextCompat.getColor(requireContext(), R.color.md_blue_grey_300))
star.setColorFilter(ContextCompat.getColor(requireContext(), com.mikepenz.materialize.R.color.md_blue_grey_300))
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1005,7 +1005,7 @@ class DashboardActivity : DashboardElementActivity(), OnHomeItemClickListener, N
if (AppCompatDelegate.getDefaultNightMode() == AppCompatDelegate.MODE_NIGHT_NO ||
(AppCompatDelegate.getDefaultNightMode() == AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM && currentNightMode == Configuration.UI_MODE_NIGHT_NO)) {
headerBackground.setColorFilter(
ContextCompat.getColor(this, R.color.md_white_1000),
ContextCompat.getColor(this, com.mikepenz.materialize.R.color.md_white_1000),
PorterDuff.Mode.SRC_IN
)
}
Expand Down Expand Up @@ -1168,9 +1168,9 @@ class DashboardActivity : DashboardElementActivity(), OnHomeItemClickListener, N
return PrimaryDrawerItem().withName(iconText)
.withIcon(drawable)
.withTextColor(ContextCompat.getColor(this, R.color.textColorPrimary))
.withSelectedTextColor(ContextCompat.getColor(this, R.color.primary_dark))
.withSelectedTextColor(ContextCompat.getColor(this, com.mikepenz.materialize.R.color.primary_dark))
.withIconColor(ContextCompat.getColor(this, R.color.textColorPrimary))
.withSelectedIconColor(ContextCompat.getColor(this, R.color.primary_dark))
.withSelectedIconColor(ContextCompat.getColor(this, com.mikepenz.materialize.R.color.primary_dark))
.withSelectedColor(ContextCompat.getColor(this, R.color.textColorPrimary))
.withIconTintingEnabled(true)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,10 @@ class AdapterHealthExamination(private val context: Context, private val list: L
val model = mRealm.where(RealmUserModel::class.java).equalTo("id", createdBy).findFirst()
val name: String = model?.getFullName() ?: createdBy.split(":".toRegex()).dropLastWhile { it.isEmpty() }.toTypedArray()[1]
rowExaminationBinding.txtDate.text = context.getString(R.string.two_strings, rowExaminationBinding.txtDate.text, name).trimIndent()
holder.itemView.setBackgroundColor(ContextCompat.getColor(context, R.color.md_grey_50))
holder.itemView.setBackgroundColor(ContextCompat.getColor(context, com.mikepenz.materialize.R.color.md_grey_50))
} else {
rowExaminationBinding.txtDate.text = context.getString(R.string.self_examination, rowExaminationBinding.txtDate.text)
holder.itemView.setBackgroundColor(ContextCompat.getColor(context, R.color.md_green_50))
holder.itemView.setBackgroundColor(ContextCompat.getColor(context, com.mikepenz.materialize.R.color.md_green_50))
}

rowExaminationBinding.txtPulse.text = list?.get(position)?.let { checkEmptyInt(it.pulse) }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -481,14 +481,14 @@ class AdapterNews(var context: Context, private var currentUser: RealmUserModel?
private fun getNews(holder: RecyclerView.ViewHolder, position: Int): RealmNews? {
val news: RealmNews? = if (parentNews != null) {
if (position == 0) {
(holder.itemView as CardView).setCardBackgroundColor(ContextCompat.getColor(context, R.color.md_blue_50))
(holder.itemView as CardView).setCardBackgroundColor(ContextCompat.getColor(context, com.mikepenz.materialize.R.color.md_blue_50))
parentNews
} else {
(holder.itemView as CardView).setCardBackgroundColor(ContextCompat.getColor(context, R.color.md_white_1000))
(holder.itemView as CardView).setCardBackgroundColor(ContextCompat.getColor(context, com.mikepenz.materialize.R.color.md_white_1000))
getItem(position - 1)
}
} else {
(holder.itemView as CardView).setCardBackgroundColor(ContextCompat.getColor(context, R.color.md_white_1000))
(holder.itemView as CardView).setCardBackgroundColor(ContextCompat.getColor(context, com.mikepenz.materialize.R.color.md_white_1000))
getItem(position)
}
return news
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ class ResourceDetailFragment : BaseContainerFragment(), OnRatingChangeListener {
val currentUserId = profileDbHandler.userModel?.id
if (currentUserId != null && library.userId?.contains(currentUserId) != true) {
Utilities.toast(activity, getString(R.string.added_to_my_library))
binding.btnRemove.setImageResource(R.drawable.close_x)
binding.btnRemove.setImageResource(eu.fiskur.chipcloud.R.drawable.close_x)
}
}
}
Expand Down Expand Up @@ -202,7 +202,7 @@ class ResourceDetailFragment : BaseContainerFragment(), OnRatingChangeListener {
if (isAdd) {
R.drawable.ic_add_library
} else {
R.drawable.close_x
eu.fiskur.chipcloud.R.drawable.close_x
}
)
binding.btnRemove.contentDescription =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ abstract class DashboardElementActivity : SyncActivity(), FragmentManager.OnBack
}
if (resIcon != null) {
DrawableCompat.setTintMode(resIcon.mutate(), PorterDuff.Mode.SRC_ATOP)
DrawableCompat.setTint(resIcon, ContextCompat.getColor(this, R.color.accent))
DrawableCompat.setTint(resIcon, ContextCompat.getColor(this, com.mikepenz.materialize.R.color.accent))
}
goOnline.icon = resIcon
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,10 @@ class AudioPlayerActivity : AppCompatActivity() {

binding.trackTitle.text = extractedFileName
binding.artistName.text = resourceTitle
playButton = binding.playerView.findViewById(R.id.exo_play)
pauseButton = binding.playerView.findViewById(R.id.exo_pause)
playButton = binding.playerView.findViewById(androidx.media3.ui.R.id.exo_play)
pauseButton = binding.playerView.findViewById(androidx.media3.ui.R.id.exo_pause)

val overlay = binding.playerView.findViewById<FrameLayout>(R.id.exo_overlay)
val overlay = binding.playerView.findViewById<FrameLayout>(androidx.media3.ui.R.id.exo_overlay)


val blurredImageView = ImageView(this).apply {
Expand All @@ -71,7 +71,7 @@ class AudioPlayerActivity : AppCompatActivity() {
.into(blurredImageView)

overlay.addView(blurredImageView, 0)
val controller = binding.playerView.findViewById<View>(R.id.exo_controller)
val controller = binding.playerView.findViewById<View>(androidx.media3.ui.R.id.exo_controller)
controller?.setBackgroundColor(android.graphics.Color.TRANSPARENT)


Expand All @@ -91,7 +91,7 @@ class AudioPlayerActivity : AppCompatActivity() {
player.prepare()
player.playWhenReady = true

val controller = binding.playerView.findViewById<View>(R.id.exo_controller)
val controller = binding.playerView.findViewById<View>(androidx.media3.ui.R.id.exo_controller)
controller?.setBackgroundColor(android.graphics.Color.TRANSPARENT)

val timeBar = binding.playerView.findViewById<DefaultTimeBar>(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,15 +100,15 @@ class WebViewActivity : AppCompatActivity() {
when (nightModeFlags) {
android.content.res.Configuration.UI_MODE_NIGHT_YES -> {
forceDark = WebSettings.FORCE_DARK_ON
activityWebViewBinding.contentWebView.webTitle.setTextColor(ContextCompat.getColor(this@WebViewActivity, R.color.md_white_1000))
activityWebViewBinding.contentWebView.webSource.setTextColor(ContextCompat.getColor(this@WebViewActivity, R.color.md_white_1000))
activityWebViewBinding.contentWebView.contentWebView.setBackgroundColor(ContextCompat.getColor(this@WebViewActivity, R.color.md_black_1000))
activityWebViewBinding.contentWebView.webTitle.setTextColor(ContextCompat.getColor(this@WebViewActivity, com.mikepenz.materialize.R.color.md_white_1000))
activityWebViewBinding.contentWebView.webSource.setTextColor(ContextCompat.getColor(this@WebViewActivity, com.mikepenz.materialize.R.color.md_white_1000))
activityWebViewBinding.contentWebView.contentWebView.setBackgroundColor(ContextCompat.getColor(this@WebViewActivity, com.mikepenz.materialize.R.color.md_black_1000))
}

android.content.res.Configuration.UI_MODE_NIGHT_NO -> {
forceDark = WebSettings.FORCE_DARK_OFF
activityWebViewBinding.contentWebView.webTitle.setTextColor(ContextCompat.getColor(this@WebViewActivity, R.color.md_black_1000))
activityWebViewBinding.contentWebView.webSource.setTextColor(ContextCompat.getColor(this@WebViewActivity, R.color.md_black_1000))
activityWebViewBinding.contentWebView.webTitle.setTextColor(ContextCompat.getColor(this@WebViewActivity, com.mikepenz.materialize.R.color.md_black_1000))
activityWebViewBinding.contentWebView.webSource.setTextColor(ContextCompat.getColor(this@WebViewActivity, com.mikepenz.materialize.R.color.md_black_1000))
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ kapt.incremental.apt=true
org.gradle.warning.mode=all
android.useAndroidX=true
android.enableJetifier=true
android.nonTransitiveRClass=false
android.nonTransitiveRClass=true
android.nonFinalResIds=true

PLANET_LEARNING_URL=planet.learning.ole.org
Expand Down