Commit tests and code for #610, reviewed by Schuyler, to resolve
PanZoom/PanZoomBar position argument. git-svn-id: http://svn.openlayers.org/trunk/openlayers@2965 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -4,10 +4,13 @@
|
||||
<script type="text/javascript"><!--
|
||||
var map;
|
||||
function test_01_Control_PanZoom_constructor (t) {
|
||||
t.plan( 1 );
|
||||
t.plan( 3 );
|
||||
|
||||
control = new OpenLayers.Control.PanZoom();
|
||||
t.ok( control instanceof OpenLayers.Control.PanZoom, "new OpenLayers.Control.PanZoom returns object" );
|
||||
control = new OpenLayers.Control.PanZoom({position: new OpenLayers.Pixel(100,100)});
|
||||
t.eq( control.position.x, 100, "PanZoom X Set correctly.");
|
||||
t.eq( control.position.y, 100, "PanZoom y Set correctly.");
|
||||
}
|
||||
function test_02_Control_PanZoom_addControl (t) {
|
||||
t.plan( 8 );
|
||||
|
||||
@@ -4,10 +4,12 @@
|
||||
<script type="text/javascript"><!--
|
||||
var map;
|
||||
function test_01_Control_PanZoomBar_constructor (t) {
|
||||
t.plan( 1 );
|
||||
t.plan( 3 );
|
||||
|
||||
control = new OpenLayers.Control.PanZoomBar();
|
||||
control = new OpenLayers.Control.PanZoomBar({position: new OpenLayers.Pixel(100,100)});
|
||||
t.ok( control instanceof OpenLayers.Control.PanZoomBar, "new OpenLayers.Control.PanZoomBar returns object" );
|
||||
t.eq( control.position.x, 100, "PanZoom X Set correctly.");
|
||||
t.eq( control.position.y, 100, "PanZoom y Set correctly.");
|
||||
}
|
||||
function test_02_Control_PanZoomBar_addControl (t) {
|
||||
t.plan( 8 );
|
||||
|
||||
Reference in New Issue
Block a user