SwitchPreference constructor

const SwitchPreference(
  1. String title,
  2. String localKey, {
  3. Key? key,
  4. String? summary,
  5. String? summaryPrefix,
  6. String? summarySuffix,
  7. bool defaultValue = false,
  8. Widget? leading,
  9. bool enabled = true,
  10. bool useValueAsSummary = false,
  11. ValueChanged<bool>? onChange,
})

Implementation

const SwitchPreference(
  this.title,
  this.localKey, {
  super.key,
  this.summary,
  this.summaryPrefix,
  this.summarySuffix,
  this.defaultValue = false,
  this.leading,
  this.enabled = true,
  this.useValueAsSummary = false,
  this.onChange,
});