Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

all: less build: warnings is more (fixes #4820) #4823

Merged
merged 3 commits into from
Dec 2, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
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 @@ -189,7 +189,7 @@ class TakeExamFragment : BaseExamFragment(), View.OnClickListener, CompoundButto
if (isRadio) {
fragmentTakeExamBinding.groupChoices.addView(rdBtn)
} else {
rdBtn.setTextColor(resources.getColor(R.color.daynight_textColor))
rdBtn.setTextColor(ContextCompat.getColor(requireContext(), R.color.daynight_textColor))
rdBtn.buttonTintList = ContextCompat.getColorStateList(requireContext(), R.color.daynight_textColor)
fragmentTakeExamBinding.llCheckbox.addView(rdBtn)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import android.widget.ImageView
import android.widget.LinearLayout
import android.widget.TextView
import androidx.appcompat.app.AppCompatActivity
import androidx.core.content.ContextCompat
import androidx.fragment.app.Fragment
import androidx.recyclerview.widget.RecyclerView
import io.realm.Realm
Expand Down Expand Up @@ -81,10 +82,10 @@ class AdapterMyLife(private val context: Context, private val myLifeList: List<R
it, myLifeList[position].userId)
}
}, {
Handler(Looper.getMainLooper()).post {
if (isVisible) {
changeVisibility(holder, R.drawable.ic_visibility, hide)
Utilities.toast(context, myLifeList[position].title + context.getString(R.string.is_now_hidden))
Handler(Looper.getMainLooper()).post {
if (isVisible) {
changeVisibility(holder, R.drawable.ic_visibility, hide)
Utilities.toast(context, myLifeList[position].title + context.getString(R.string.is_now_hidden))
} else {
changeVisibility(holder, R.drawable.ic_visibility_off, show)
Utilities.toast(context, myLifeList[position].title + context.getString(R.string.is_now_shown))
Expand Down Expand Up @@ -120,11 +121,11 @@ class AdapterMyLife(private val context: Context, private val myLifeList: List<R
var rvItemContainer: LinearLayout = itemView.findViewById(R.id.rv_item_parent_layout)

override fun onItemSelected() {
itemView.setBackgroundColor(context.resources.getColor(R.color.user_profile_background))
itemView.setBackgroundColor(ContextCompat.getColor(context, R.color.user_profile_background))
}

override fun onItemClear(viewHolder: RecyclerView.ViewHolder?) {
itemView.setBackgroundColor(context.resources.getColor(R.color.daynight_grey))
itemView.setBackgroundColor(ContextCompat.getColor(context, R.color.daynight_grey))
if (viewHolder != null) {
if (!myLifeList[viewHolder.bindingAdapterPosition].isVisible) {
(viewHolder as ViewHolderMyLife?)?.rvItemContainer?.alpha = hide
Expand Down