code: private void initializeShowListDialogPreference() {
          Preference preference = findPreference(getString(R.string.show_list_dialog_preference_key));
          preference.setOnPreferenceClickListener(new OnPreferenceClickListener() {
  
              @Override
              public boolean onPreferenceClick(final Preference preference) {
                  initializeListDialog();
                  listDialog.setShowAnimation(createRectangularRevealAnimation(preference));
                  listDialog.setDismissAnimation(createRectangularRevealAnimation(preference));
                  listDialog.setCancelAnimation(createRectangularRevealAnimation(preference));
                  listDialog.show();
                  return true;
              }
  
          });
      }
docs: Initializes the preference, which allows to show the list dialog.