You are here

public function Html5Widget::buildForm in Geolocation Field 8.3

Same name and namespace in other branches
  1. 8.2 modules/geolocation_demo/src/Form/Html5Widget.php \Drupal\geolocation_demo\Form\Html5Widget::buildForm()

Form constructor.

Parameters

array $form: An associative array containing the structure of the form.

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.

Return value

array The form structure.

Overrides FormInterface::buildForm

File

modules/geolocation_demo/src/Form/Html5Widget.php, line 22

Class

Html5Widget
Returns responses for geolocation_demo module routes.

Namespace

Drupal\geolocation_demo\Form

Code

public function buildForm(array $form, FormStateInterface $form_state) {
  $widget_form = $this
    ->getWidgetForm('geolocation_html5', $form, $form_state);
  $form['widget'] = $widget_form;
  return $form;
}