Completed
Push — 3.1 ( 9bc055...44afa5 )
by Gordon
19:43
created
code/MapExtension.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -204,7 +204,7 @@
 block discarded – undo
204 204
     /**
205 205
      * Access the map editing field for the purpose of adding guide points.
206 206
      *
207
-     * @return [LatLongField] instance of location editing field
207
+     * @return FormField instance of location editing field
208 208
      */
209 209
     public function getMapField()
210 210
     {
Please login to merge, or discard this patch.
tests/MapExtensionTest.php 1 patch
Doc Comments   +7 added lines patch added patch discarded remove patch
@@ -265,6 +265,10 @@  discard block
 block discarded – undo
265 265
     /*
266 266
     Add a map layer to an existing instance
267 267
      */
268
+
269
+    /**
270
+     * @param Member $instance
271
+     */
268 272
     private function addLayerToInstance(&$instance)
269 273
     {
270 274
         // Create a layer
@@ -279,6 +283,9 @@  discard block
 block discarded – undo
279 283
         $layers->add($layer);
280 284
     }
281 285
 
286
+    /**
287
+     * @param Member $instance
288
+     */
282 289
     private function addMapPinToInstance(&$instance)
283 290
     {
284 291
         // Create a pin
Please login to merge, or discard this patch.
code/LatLongField.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
             'data-LonFieldName' => $this->longField,
66 66
             'data-ZoomFieldName' => $this->zoomField,
67 67
             'data-UseMapBounds' => false,
68
-       );
68
+        );
69 69
 
70 70
         Requirements::css('mappable/css/mapField.css');
71 71
 
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
         $content = '<div class="editableMapWrapper">'.$this->create_tag(
90 90
             'div',
91 91
             $attributes
92
-       ).'</div>';
92
+        ).'</div>';
93 93
 
94 94
         $this->FieldList()->push(new LiteralField('locationEditor', $content));
95 95
 
Please login to merge, or discard this patch.
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -18,8 +18,7 @@
 block discarded – undo
18 18
      * @param string[] $buttonText
19 19
      */
20 20
     public function __construct($children = array(), $buttonText = null)
21
-    {
22
-        ++self::$ctr;
21
+    {++self::$ctr;
23 22
 
24 23
         if ((sizeof($children) < 2) || (sizeof($children) > 3) ||
25 24
              (!$children[0] instanceof FormField) ||
Please login to merge, or discard this patch.
code/MapAPI.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -626,7 +626,7 @@
 block discarded – undo
626 626
             $kmlJson = stripslashes(json_encode($this->kmlFiles, JSON_UNESCAPED_UNICODE));
627 627
         }
628 628
 
629
-         // Center of the GMap - text centre takes precedence
629
+            // Center of the GMap - text centre takes precedence
630 630
         $geocodeCentre = ($this->latLongCenter) ?
631 631
                             $this->latLongCenter : $this->geocoding($this->center);
632 632
 
Please login to merge, or discard this patch.
code/MapField.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -1,12 +1,12 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Map field to point for pois langitude and longitude positioning.
4
- */
3
+     * Map field to point for pois langitude and longitude positioning.
4
+     */
5 5
 class MapField extends DatalessField
6 6
 {
7 7
     /**
8
-         * @var int The level of the <h1> to <h6> HTML tag. Default: 2
9
-         */
8
+     * @var int The level of the <h1> to <h6> HTML tag. Default: 2
9
+     */
10 10
         protected $headingLevel = 2;
11 11
     private $divId;
12 12
 
Please login to merge, or discard this patch.
code/MapUtil.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -132,8 +132,7 @@
 block discarded – undo
132 132
      * @return MapAPI
133 133
      */
134 134
     public static function instance()
135
-    {
136
-        ++self::$instances;
135
+    {++self::$instances;
137 136
 
138 137
         if (self::$allow_full_screen == null) {
139 138
             self::$allow_full_screen = Config::inst()->get('Mappable', 'allow_full_screen');
Please login to merge, or discard this patch.
code/Mappable.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,11 +1,11 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Defines the interface for a mappable DataObject. Implementors of this interface
4
- * must define the following functions in order to work with the {@link GoogleMapUtil}
5
- * helper class.
6
- *
7
- * @author Uncle Cheese
8
- */
3
+     * Defines the interface for a mappable DataObject. Implementors of this interface
4
+     * must define the following functions in order to work with the {@link GoogleMapUtil}
5
+     * helper class.
6
+     *
7
+     * @author Uncle Cheese
8
+     */
9 9
 interface Mappable
10 10
 {
11 11
     /**
Please login to merge, or discard this patch.
code/shortcodes/GoogleStreetViewShortCodeHandler.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -53,8 +53,7 @@
 block discarded – undo
53 53
         // the id of the dom element to be used to render the street view
54 54
         $arguments['DomID'] = 'google_streetview_'.self::$gsv_ctr;
55 55
 
56
-        // incrememt the counter to ensure a unique id for each map canvas
57
-        ++self::$gsv_ctr;
56
+        // incrememt the counter to ensure a unique id for each map canvas++self::$gsv_ctr;
58 57
 
59 58
         // merge defaults and arguments
60 59
         $customised = array_merge($defaults, $arguments);
Please login to merge, or discard this patch.
tests/LatLongFieldTest.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -24,8 +24,8 @@  discard block
 block discarded – undo
24 24
             $this->fail('Creation of lat long field should have failed');
25 25
         } catch (Exception $e) {
26 26
             $expected = 'LatLongField argument 1 must be an array containing at'
27
-                      .' least two FormField objects for Lat/Long values, resp'
28
-                      .'ectively.';
27
+                        .' least two FormField objects for Lat/Long values, resp'
28
+                        .'ectively.';
29 29
             $this->assertEquals($expected, $e->getMessage());
30 30
         }
31 31
     }
@@ -118,8 +118,8 @@  discard block
 block discarded – undo
118 118
 
119 119
         $html = $mapField->FieldHolder();
120 120
         $expected = 'data-GuidePoints="[{&quot;latitude&quot;:42,&quot;longitude&quot;:&quot;113.1&'
121
-                  .'quot;},{&quot;latitude&quot;:14.9,&quot;longitude&quot;:&quot;113.2&quot;},{&q'
122
-                  .'uot;latitude&quot;:42.3,&quot;longitude&quot;:&quot;113.4&quot;}]"';
121
+                    .'quot;},{&quot;latitude&quot;:14.9,&quot;longitude&quot;:&quot;113.2&quot;},{&q'
122
+                    .'uot;latitude&quot;:42.3,&quot;longitude&quot;:&quot;113.4&quot;}]"';
123 123
 
124 124
         $this->assertContains($expected, $html);
125 125
     }
Please login to merge, or discard this patch.