mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-12-25 10:07:38 +00:00
Fix an NPE
java.lang.NullPointerException: Attempt to invoke virtual method 'int android.text.Layout.getEllipsisCount(int)' on a null object reference
This commit is contained in:
parent
571b8986a4
commit
591788c0df
@ -26,7 +26,7 @@ class HomeFragment : BaseUIFragment<HomeViewModel, FragmentHomeMd2Binding>() {
|
|||||||
|
|
||||||
private fun checkTitle(text: TextView, icon: ImageView) {
|
private fun checkTitle(text: TextView, icon: ImageView) {
|
||||||
text.post {
|
text.post {
|
||||||
if (text.layout.getEllipsisCount(0) != 0) {
|
if (text.layout?.getEllipsisCount(0) != 0) {
|
||||||
with (icon) {
|
with (icon) {
|
||||||
layoutParams.width = 0
|
layoutParams.width = 0
|
||||||
layoutParams.height = 0
|
layoutParams.height = 0
|
||||||
|
Loading…
x
Reference in New Issue
Block a user