ColorPickerPreference icon indicating copy to clipboard operation
ColorPickerPreference copied to clipboard

holder.findViewById(R.id.preference_colorBox) must not be null

Open luckyzyx opened this issue 3 years ago • 0 comments

Please complete the following information:

  • Library Version 2.0.6
  • Affected Device(s) OnePlus 9RT Android 12

Describe the Bug:

        preferenceScreen = preferenceManager.createPreferenceScreen(requireActivity()).apply {
            addPreference(
                ColorPickerPreference(requireActivity()).apply {
                    setTitle("ColorPicker")
                    setSummary("summer")
                    key = "color_picker_test"
                    isIconSpaceReserved = false
                }
            )
        }

Adding Preference after importing will crash when the ColorPickerPreference is displayed, and the crash information preference_colorBox is null.

luckyzyx avatar Jul 28 '22 19:07 luckyzyx