Code Duplication    Length = 7-7 lines in 8 locations

src/Map.php 8 locations

@@ 807-813 (lines=7) @@
804
				var circle_'.count($this->circles).' = new google.maps.Circle(circleOptions);
805
			';
806
807
            if ($circle['onclick'] != "") {
808
                $circle_output .= '
809
				google.maps.event.addListener(circle_'.count($this->circles).', "click", function() {
810
					'.$circle['onclick'].'
811
				});
812
				';
813
            }
814
            if ($circle['ondblclick'] != "") {
815
                $circle_output .= '
816
				google.maps.event.addListener(circle_'.count($this->circles).', "dblclick", function() {
@@ 814-820 (lines=7) @@
811
				});
812
				';
813
            }
814
            if ($circle['ondblclick'] != "") {
815
                $circle_output .= '
816
				google.maps.event.addListener(circle_'.count($this->circles).', "dblclick", function() {
817
					'.$circle['ondblclick'].'
818
				});
819
				';
820
            }
821
            if ($circle['onmousedown'] != "") {
822
                $circle_output .= '
823
				google.maps.event.addListener(circle_'.count($this->circles).', "mousedown", function() {
@@ 821-827 (lines=7) @@
818
				});
819
				';
820
            }
821
            if ($circle['onmousedown'] != "") {
822
                $circle_output .= '
823
				google.maps.event.addListener(circle_'.count($this->circles).', "mousedown", function() {
824
					'.$circle['onmousedown'].'
825
				});
826
				';
827
            }
828
            if ($circle['onmousemove'] != "") {
829
                $circle_output .= '
830
				google.maps.event.addListener(circle_'.count($this->circles).', "mousemove", function() {
@@ 828-834 (lines=7) @@
825
				});
826
				';
827
            }
828
            if ($circle['onmousemove'] != "") {
829
                $circle_output .= '
830
				google.maps.event.addListener(circle_'.count($this->circles).', "mousemove", function() {
831
					'.$circle['onmousemove'].'
832
				});
833
				';
834
            }
835
            if ($circle['onmouseout'] != "") {
836
                $circle_output .= '
837
				google.maps.event.addListener(circle_'.count($this->circles).', "mouseout", function() {
@@ 835-841 (lines=7) @@
832
				});
833
				';
834
            }
835
            if ($circle['onmouseout'] != "") {
836
                $circle_output .= '
837
				google.maps.event.addListener(circle_'.count($this->circles).', "mouseout", function() {
838
					'.$circle['onmouseout'].'
839
				});
840
				';
841
            }
842
            if ($circle['onmouseover'] != "") {
843
                $circle_output .= '
844
				google.maps.event.addListener(circle_'.count($this->circles).', "mouseover", function() {
@@ 842-848 (lines=7) @@
839
				});
840
				';
841
            }
842
            if ($circle['onmouseover'] != "") {
843
                $circle_output .= '
844
				google.maps.event.addListener(circle_'.count($this->circles).', "mouseover", function() {
845
					'.$circle['onmouseover'].'
846
				});
847
				';
848
            }
849
            if ($circle['onmouseup'] != "") {
850
                $circle_output .= '
851
				google.maps.event.addListener(circle_'.count($this->circles).', "mouseup", function() {
@@ 849-855 (lines=7) @@
846
				});
847
				';
848
            }
849
            if ($circle['onmouseup'] != "") {
850
                $circle_output .= '
851
				google.maps.event.addListener(circle_'.count($this->circles).', "mouseup", function() {
852
					'.$circle['onmouseup'].'
853
				});
854
				';
855
            }
856
            if ($circle['onrightclick'] != "") {
857
                $circle_output .= '
858
				google.maps.event.addListener(circle_'.count($this->circles).', "rightclick", function() {
@@ 856-862 (lines=7) @@
853
				});
854
				';
855
            }
856
            if ($circle['onrightclick'] != "") {
857
                $circle_output .= '
858
				google.maps.event.addListener(circle_'.count($this->circles).', "rightclick", function() {
859
					'.$circle['onrightclick'].'
860
				});
861
				';
862
            }
863
864
            array_push($this->circles, $circle_output);
865
        }