LocationPickerPlusUnifiedWidget constructor
const
LocationPickerPlusUnifiedWidget({
- Key? key,
- dynamic onLocationSelected()?,
- LocationPickerMode mode = LocationPickerMode.all,
- LocationPickerTheme? theme,
- String? googlePlacesApiKey,
- String? initialSearchText,
- LocationResult? initialLocation,
- String? country,
- List<
String> placesTypes = const [], - String placesHintText = 'Search for a place...',
- bool useDropdownsForCountryState = true,
- String addressLabel = 'Address',
- String cityLabel = 'City',
- String stateLabel = 'State/Province',
- String countryLabel = 'Country',
- String postalCodeLabel = 'Postal Code',
- List<
String> ? allowedCountries, - bool lockFieldsForGooglePlaces = true,
- String currentLocationButtonText = 'Use My Location',
- bool showCoordinates = true,
- bool autoDetectOnInit = false,
- String searchTabLabel = 'Search',
- String gpsTabLabel = 'GPS',
- String manualTabLabel = 'Manual',
Implementation
const LocationPickerPlusUnifiedWidget({
super.key,
this.onLocationSelected,
this.mode = LocationPickerMode.all,
this.theme,
this.googlePlacesApiKey,
this.initialSearchText,
this.initialLocation,
// Google Places
this.country,
this.placesTypes = const [],
this.placesHintText = 'Search for a place...',
// Manual entry
this.useDropdownsForCountryState = true,
this.addressLabel = 'Address',
this.cityLabel = 'City',
this.stateLabel = 'State/Province',
this.countryLabel = 'Country',
this.postalCodeLabel = 'Postal Code',
this.allowedCountries,
this.lockFieldsForGooglePlaces = true,
// Current location
this.currentLocationButtonText = 'Use My Location',
this.showCoordinates = true,
this.autoDetectOnInit = false,
// UI
this.searchTabLabel = 'Search',
this.gpsTabLabel = 'GPS',
this.manualTabLabel = 'Manual',
});