widget: Fix changes of copyright year
[lhc/web/wiklou.git] / includes / widget / SelectWithInputWidget.php
index 8faae82..5ceed4c 100644 (file)
@@ -1,17 +1,15 @@
 <?php
-/**
- * MediaWiki Widgets – SelectWithInputWidget class.
- *
- * @copyright 2011-2017 MediaWiki Widgets Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
- */
+
 namespace MediaWiki\Widget;
 
-use \OOUI\TextInputWidget;
-use \OOUI\DropdownInputWidget;
+use OOUI\DropdownInputWidget;
+use OOUI\TextInputWidget;
 
 /**
  * Select and input widget.
+ *
+ * @copyright 2011-2017 MediaWiki Widgets Team and others; see AUTHORS.txt
+ * @license MIT
  */
 class SelectWithInputWidget extends \OOUI\Widget {
 
@@ -22,9 +20,9 @@ class SelectWithInputWidget extends \OOUI\Widget {
         * A version of the SelectWithInputWidget, with `or` set to true.
         *
         * @param array $config Configuration options
-        * @param array $config['textinput'] Configuration for the TextInputWidget
-        * @param array $config['dropdowninput'] Configuration for the DropdownInputWidget
-        * @param boolean $config['or'] Configuration for whether the widget is dropdown AND input
+        *   - array $config['textinput'] Configuration for the TextInputWidget
+        *   - array $config['dropdowninput'] Configuration for the DropdownInputWidget
+        *   - bool $config['or'] Configuration for whether the widget is dropdown AND input
         *                              or dropdown OR input
         */
        public function __construct( array $config = [] ) {
@@ -38,7 +36,6 @@ class SelectWithInputWidget extends \OOUI\Widget {
                        $config
                );
 
-               // Parent constructor
                parent::__construct( $config );
 
                // Properties
@@ -59,6 +56,7 @@ class SelectWithInputWidget extends \OOUI\Widget {
        public function getConfig( &$config ) {
                $config['textinput'] = $this->config['textinput'];
                $config['dropdowninput'] = $this->config['dropdowninput'];
+               $config['dropdowninput']['dropdown']['$overlay'] = true;
                $config['or'] = $this->config['or'];
                return parent::getConfig( $config );
        }