From f398684d0fa0cec7a05773f5cedc4465e0899136 Mon Sep 17 00:00:00 2001 From: Blatzar <46196380+Blatzar@users.noreply.github.com> Date: Fri, 19 Aug 2022 00:05:39 +0200 Subject: [PATCH] 3rd try fixing nginx --- .../src/main/kotlin/com/lagradost/NginxSettingsFragment.kt | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/NginxProvider/src/main/kotlin/com/lagradost/NginxSettingsFragment.kt b/NginxProvider/src/main/kotlin/com/lagradost/NginxSettingsFragment.kt index 2f582ce..4903e6d 100644 --- a/NginxProvider/src/main/kotlin/com/lagradost/NginxSettingsFragment.kt +++ b/NginxProvider/src/main/kotlin/com/lagradost/NginxSettingsFragment.kt @@ -41,12 +41,12 @@ class NginxSettingsFragment(private val plugin: Plugin, val nginxApi: NginxApi) } private fun getString(name: String): String { - val id = this.resources.getIdentifier(name, "string", "com.lagradost.cloudstream3") + val id = plugin.resources!!.getIdentifier(name, "string", "com.lagradost") return this.getString(id) } private fun getAttr(name: String): Int { - return this.resources.getIdentifier(name, "attr", "com.lagradost.cloudstream3") + return plugin.resources!!.getIdentifier(name, "attr", "com.lagradost") } override fun onViewCreated(view: View, savedInstanceState: Bundle?) { @@ -61,7 +61,8 @@ class NginxSettingsFragment(private val plugin: Plugin, val nginxApi: NginxApi) infoImageView.setImageDrawable( getDrawable("nginx_question") ) - infoImageView.imageTintList = ColorStateList.valueOf(view.context.colorFromAttribute(getAttr("white"))) + infoImageView.imageTintList = + ColorStateList.valueOf(view.context.colorFromAttribute(getAttr("white"))) val loginView = view.findView("nginx_login") val loginTextView = view.findView("main_text")