[BUGFIX] SelfRemovingPreference: set visibility at early stage

Change-Id: Ic23c4a78fa424b045d8f38b6b799339570a6fda0
Signed-off-by: rmp22 <195054967+rmp22@users.noreply.github.com>
This commit is contained in:
rmp22
2025-08-09 09:24:57 +08:00
committed by Joey
parent 09b858311a
commit 6b4867d982

View File

@@ -22,6 +22,7 @@ public class SelfRemovingPreference extends Preference {
int defStyle, int defStyleRes) {
super(context, attrs, defStyle, defStyleRes);
mConstraints = new ConstraintsHelper(context, attrs, this);
setVisible(mConstraints.isAvailable());
}
public SelfRemovingPreference(Context context, AttributeSet attrs, int defStyle) {