GML Layers is no more visible in vector sandbox revision 2823

classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

GML Layers is no more visible in vector sandbox revision 2823

Christine Spietz
Hi,

I updated my OpenLayers libraries to the actual version on
http://svn.openlayers.org/sandbox/vector/. Now my GML-layers (working in
previous versions) do not work any more.

I set a variable url with the WFS-request of my WFS which provides a
FeatureCollection and createt my GML-layer:

>----------------------------------->CODE>----------------------------------->
var myGMLLayer= new OpenLayers.Layer.GML("myGMLLayer",url,
{style: new OpenLayers.Style({
    strokeColor: "rgb(128,0,255)",
    strokeWidth: 3,
    strokeOpacity: 0.5,
    fillColor: "rgb(100,100,255)",
    fillOpacity: 0.1,
    hoverStrokeColor: "red"
})}
);

map.addLayer(myGMLLayer);
>----------------------------------->END OF
>CODE>----------------------------------->

This worked in previos versions of OpenLayers vector-sandbox-lib.

The GML-examples I found on
- http://dev.openlayers.org/sandbox/vector/examples/ GML.html and
GMLTasmania.html seem also not to work. They also use the same procedure,
for example generating a GML-layer with
>----------------------------------->CODE>----------------------------------->
l1 = new OpenLayers.Layer.GML("Tasmania
Cities","tasmania/TasmaniaCities.xml", {style: new
OpenLayers.Style({strokeColor: "green"})});
>----------------------------------->END OF
>CODE>----------------------------------->

Can anybody tell me how to handle GML-Layers/ make them visible again.

Thank you for help!!!!


Christine

_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: GML Layers is no more visible in vector sandbox revision 2823

Erik Uzureau-3
Christine,
You should update your libraries to the actual version on
http://svn.openlayers.org/trunk/openlayers

We have merged the vector code into trunk last week :-)
Erik

On 3/20/07, Christine Spietz <[hidden email]> wrote:

> Hi,
>
> I updated my OpenLayers libraries to the actual version on
> http://svn.openlayers.org/sandbox/vector/. Now my GML-layers (working in
> previous versions) do not work any more.
>
> I set a variable url with the WFS-request of my WFS which provides a
> FeatureCollection and createt my GML-layer:
>
> >----------------------------------->CODE>----------------------------------->
> var myGMLLayer= new OpenLayers.Layer.GML("myGMLLayer",url,
> {style: new OpenLayers.Style({
>     strokeColor: "rgb(128,0,255)",
>     strokeWidth: 3,
>     strokeOpacity: 0.5,
>     fillColor: "rgb(100,100,255)",
>     fillOpacity: 0.1,
>     hoverStrokeColor: "red"
> })}
> );
>
> map.addLayer(myGMLLayer);
> >----------------------------------->END OF
> >CODE>----------------------------------->
>
> This worked in previos versions of OpenLayers vector-sandbox-lib.
>
> The GML-examples I found on
> - http://dev.openlayers.org/sandbox/vector/examples/ GML.html and
> GMLTasmania.html seem also not to work. They also use the same procedure,
> for example generating a GML-layer with
> >----------------------------------->CODE>----------------------------------->
> l1 = new OpenLayers.Layer.GML("Tasmania
> Cities","tasmania/TasmaniaCities.xml", {style: new
> OpenLayers.Style({strokeColor: "green"})});
> >----------------------------------->END OF
> >CODE>----------------------------------->
>
> Can anybody tell me how to handle GML-Layers/ make them visible again.
>
> Thank you for help!!!!
>
>
> Christine
>
> _______________________________________________
> Dev mailing list
> [hidden email]
> http://openlayers.org/mailman/listinfo/dev
>
_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Pb with IE - Events click and mousedown

sylvainb
Hi,

Using events in OpenLayers, i'm setting these settings :

   map.events.register("click", map, queryMap);
   map.events.register("mousedown", map, clickOnMap);


It works fine on firefox. When i click, querymap is called, and not
clickOnMap. When i start to drag the map clickOnMap is called ok.

But under IE, queryMap is always called. I mean, when i start to grad
the map and then release the mouse button, the "click" event is fired.

a bug ?

Thanks.

Sylvain Beorchia.
Makina Corpus.
_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: Pb with IE - Events click and mousedown

Schuyler Erle-2
On Tue, 2007-03-20 at 18:14 +0100, Sylvain Beorchia wrote:

>
> Using events in OpenLayers, i'm setting these settings :
>
>    map.events.register("click", map, queryMap);
>    map.events.register("mousedown", map, clickOnMap);
>
>
> It works fine on firefox. When i click, querymap is called, and not
> clickOnMap. When i start to drag the map clickOnMap is called ok.
>
> But under IE, queryMap is always called. I mean, when i start to grad
> the map and then release the mouse button, the "click" event is fired.

I think you need to make sure that you call OpenLayers.Event.stop(evt)
in your clickOnMap handler, so that the event doesn't fall through to
the browser default behavior. Try it?

SDE

_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: Pb with IE - Events click and mousedown

sylvainb
Hi,

as a matter of fact, i forgot the OpenLayers.Event.stop(evt) in my
handlers. But it's still not working. I mean when i stop draging the
map, and release the mouse button, the OnClik() event is still fired
(only under IE).

I've tried to put the OpenLayers.Event.stop(evt) in the mousedown
handler, and in the move handler. Nothing works.

Any ideas ?

Thank you.

Sylvain Beorchia.


Schuyler Erle a e'crit :

> On Tue, 2007-03-20 at 18:14 +0100, Sylvain Beorchia wrote:
>> Using events in OpenLayers, i'm setting these settings :
>>
>>    map.events.register("click", map, queryMap);
>>    map.events.register("mousedown", map, clickOnMap);
>>
>>
>> It works fine on firefox. When i click, querymap is called, and not
>> clickOnMap. When i start to drag the map clickOnMap is called ok.
>>
>> But under IE, queryMap is always called. I mean, when i start to grad
>> the map and then release the mouse button, the "click" event is fired.
>
> I think you need to make sure that you call OpenLayers.Event.stop(evt)
> in your clickOnMap handler, so that the event doesn't fall through to
> the browser default behavior. Try it?
>
> SDE
>
> _______________________________________________
> Dev mailing list
> [hidden email]
> http://openlayers.org/mailman/listinfo/dev

_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: GML Layers is no more visible in vector sandbox revision 2823

Christine Spietz
In reply to this post by Erik Uzureau-3
Hi Erik,

I have updated to the libraries of
http://svn.openlayers.org/trunk/openlayers revision 2828, but now it's
working less then before.
I can not see any map anymore.
>----------------------------------->ERROR-MESSAGE>----------------------------------->
OpenLayers.MouseListener.MouseDefaults is not a constructor
var mouseListener = new OpenLayers.MouseListener.MouseDefaults();
in Map.js line 229.
>----------------------------------->END OF
>ERROR-MESSAGE>----------------------------------->

The thing is: This line (mouseListener = ...) is not contained in Map.js of
the actual trunk-version of OpenLayers. So I thought I might have embedded
the wrong OpenLayers-folder in my page, but this is also not the case.

Do you have an idea, what may have gone wrong? Is it a bug in the actual
trunk version or what else coul be the cause?

Some code snippets:
>----------------------------------->CODE>----------------------------------->
<script src="lib/OpenLayers.js" />

map = new OpenLayers.Map($('map'), {projection: "EPSG:31467",maxExtent:
maxEBBOX,maxResolution: "auto",units: 'meters'});

var freedop_baselayer = new
OpenLayers.Layer.WMS.Untiled("FreeDOP","http://geo.service24.rlp.de/wmsconnector/com.esri.wms.Esrimap/RLP_FREEDOP?",{layers:"dop",format:"image/png",bgcolor:"0xffffff",transparent:"true"},
{isBaseLayer:true});
map.addLayers([freedop_baselayer]);
...
map.addControl(new OpenLayers.Control.LayerSwitcher());
...
var schlaege = new OpenLayers.Layer.GML("Schlaege",url,{style: new
OpenLayers.Style({strokeColor: "rgb(128,0,255)",strokeWidth:
3,strokeOpacity: 0.5,fillColor: "rgb(100,100,255)",fillOpacity:
0.1,hoverStrokeColor: "red"})});
map.addLayer(schlaege);
map.zoomToMaxExtent();
>----------------------------------->END OF
>CODE>----------------------------------->

Christine



----- Original Message -----
From: "Erik Uzureau" <[hidden email]>
To: "Christine Spietz" <[hidden email]>
Cc: <[hidden email]>
Sent: Tuesday, March 20, 2007 4:31 PM
Subject: Re: [OpenLayers-Dev] GML Layers is no more visible in vector
sandbox revision 2823


> Christine,
> You should update your libraries to the actual version on
> http://svn.openlayers.org/trunk/openlayers
>
> We have merged the vector code into trunk last week :-)
> Erik
>
> On 3/20/07, Christine Spietz <[hidden email]> wrote:
>> Hi,
>>
>> I updated my OpenLayers libraries to the actual version on
>> http://svn.openlayers.org/sandbox/vector/. Now my GML-layers (working in
>> previous versions) do not work any more.
>>
>> I set a variable url with the WFS-request of my WFS which provides a
>> FeatureCollection and createt my GML-layer:
>>
>> >----------------------------------->CODE>----------------------------------->
>> var myGMLLayer= new OpenLayers.Layer.GML("myGMLLayer",url,
>> {style: new OpenLayers.Style({
>>     strokeColor: "rgb(128,0,255)",
>>     strokeWidth: 3,
>>     strokeOpacity: 0.5,
>>     fillColor: "rgb(100,100,255)",
>>     fillOpacity: 0.1,
>>     hoverStrokeColor: "red"
>> })}
>> );
>>
>> map.addLayer(myGMLLayer);
>> >----------------------------------->END OF
>> >CODE>----------------------------------->
>>
>> This worked in previos versions of OpenLayers vector-sandbox-lib.
>>
>> The GML-examples I found on
>> - http://dev.openlayers.org/sandbox/vector/examples/ GML.html and
>> GMLTasmania.html seem also not to work. They also use the same procedure,
>> for example generating a GML-layer with
>> >----------------------------------->CODE>----------------------------------->
>> l1 = new OpenLayers.Layer.GML("Tasmania
>> Cities","tasmania/TasmaniaCities.xml", {style: new
>> OpenLayers.Style({strokeColor: "green"})});
>> >----------------------------------->END OF
>> >CODE>----------------------------------->
>>
>> Can anybody tell me how to handle GML-Layers/ make them visible again.
>>
>> Thank you for help!!!!
>>
>>
>> Christine
>>
>> _______________________________________________
>> Dev mailing list
>> [hidden email]
>> http://openlayers.org/mailman/listinfo/dev
>>
>

_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: GML Layers is no more visible in vector sandbox revision 2823

Christopher Schmidt-2
On Wed, Mar 21, 2007 at 08:49:59AM +0100, Christine Spietz wrote:

> Hi Erik,
>
> I have updated to the libraries of
> http://svn.openlayers.org/trunk/openlayers revision 2828, but now it's
> working less then before.
> I can not see any map anymore.
> >----------------------------------->ERROR-MESSAGE>----------------------------------->
> OpenLayers.MouseListener.MouseDefaults is not a constructor
> var mouseListener = new OpenLayers.MouseListener.MouseDefaults();
> in Map.js line 229.
> >----------------------------------->END OF
> >ERROR-MESSAGE>----------------------------------->
>
> The thing is: This line (mouseListener = ...) is not contained in Map.js of
> the actual trunk-version of OpenLayers. So I thought I might have embedded
> the wrong OpenLayers-folder in my page, but this is also not the case.
>
> Do you have an idea, what may have gone wrong? Is it a bug in the actual
> trunk version or what else coul be the cause?

Much of the code between the existing trunk and the old vector branch
was refactored. http://openlayers.org/dev/examples/ has a list of
examples -- including gml-layer and EditingToolbar -- that demonstrate
the new functionality. Please refer to these examples for more
information on how to get started with the trunk version of the vector
tools.

Regards,
--
Christopher Schmidt
MetaCarta
_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: GML Layers is no more visible in vector sandbox revision 2823

Christine Spietz
Hi again,

I took a look at the http://openlayers.org/dev/examples/  especially at the
gml-layer-example.
The GML-layer displays the polygon.xml and may also display the other files
in http://openlayers.org/dev/examples/gml/. I get a response of my WFS which
looks like this:

<wfs:FeatureCollection xsi:schemaLocation="http://www.opengis.net/wfs
http://schemas.opengeospatial.net/wfs/1.0.0/WFS-basic.xsd
http://mapserver.gis.umn.edu/mapserver
https://www.flo.rlp.de/mapserv?map=gazetteer.map&SERVICE=WFS&SERVICE=WFS&VERSION=1.0.0&REQUEST=DescribeFeatureType&TYPENAME=schlag_box&OUTPUTFORMAT=XMLSCHEMA">
 <gml:boundedBy>
 <gml:Box srsName="epsg:31467">
 <gml:coordinates>
3407301.115000,5507652.775000 3409374.573000,5512980.496000
</gml:coordinates>
</gml:Box>
</gml:boundedBy>
 <gml:featureMember>
 <ms:schlag_box>
 <gml:boundedBy>
 <gml:Box srsName="epsg:31467">
 <gml:coordinates>
3407802.158000,5512683.680000 3408109.996000,5512980.496000
</gml:coordinates>
</gml:Box>
</gml:boundedBy>
 <ms:msGeometry>
 <gml:Polygon srsName="epsg:31467">
 <gml:outerBoundaryIs>
 <gml:LinearRing>
 <gml:coordinates>
3407867.940000,5512748.922000 3407881.750000,5512721.861000
3407888.890000,5512716.341000 3408047.394000,5512683.680000
3408052.984000,5512687.700000 3408065.415000,5512780.432000
3408109.966000,5512798.002000 3408109.996000,5512803.212000
3408078.155000,5512816.252000 3407998.713000,5512878.844000
3407971.482000,5512919.865000 3407970.602000,5512960.705000
3407966.822000,5512968.965000 3407953.602000,5512979.856000
3407945.481000,5512980.496000 3407810.388000,5512900.355000
3407803.118000,5512889.415000 3407802.158000,5512880.515000
3407807.188000,5512865.754000 3407825.288000,5512840.994000
3407823.338000,5512837.034000 3407837.569000,5512817.553000
3407844.819000,5512802.883000 3407867.940000,5512748.922000
</gml:coordinates>
</gml:LinearRing>
</gml:outerBoundaryIs>
</gml:Polygon>
</ms:msGeometry>
<ms:SLNR>0001</ms:SLNR>
<ms:SUNA>0</ms:SUNA>
<ms:SUNG>0</ms:SUNG>
<ms:STYP> </ms:STYP>
<ms:JAHR>2007</ms:JAHR>
<ms:BTNR>0107133050580001</ms:BTNR>
<ms:SLFL>49133</ms:SLFL>
<ms:NUAR>311</ms:NUAR>
<ms:BENA>B</ms:BENA>
<ms:GEO_ID>6974205</ms:GEO_ID>
</ms:schlag_box>
</gml:featureMember>
.... //lot of featureMembers
</wfs:FeatureCollection>

So the structure is little bit different. May this perhaps be the cause,
that my GML-layer displays nothing?

Also I 'm still getting the curios error:
>>OpenLayers.MouseListener.MouseDefaults is not a constructor
>> var mouseListener = new OpenLayers.MouseListener.MouseDefaults();
>> in Map.js line 229.

I'm really convinced that I do not use the code which causes the error, so I
guessed it was an error in OpenLayers. But this also seems not to be the
case....

Here is my "whole" code (at least the code which contains OpenLayers
things). There really is no use of MouseDefaults in it. I really have no
idea what to do. My form has to be ready next week, so I'm really in a tight
spot. Perhaps I indeirectly use the MouseDefaults??


function initMap(){

map = new OpenLayers.Map($('map'), {projection: "EPSG:31467",maxExtent:
maxEBBOX,maxResolution: "auto",units: 'meters'});

var freedop_baselayer = new
OpenLayers.Layer.WMS.Untiled("FreeDOP","http://geo.service24.rlp.de/wmsconnector/com.esri.wms.Esrimap/RLP_FREEDOP?",{layers:"dop",format:"image/png",bgcolor:"0xffffff",transparent:"true"},
{isBaseLayer:true});

map.addLayers([freedop_baselayer]);

var geoportal_top_overlay_citiesnames= new
OpenLayers.Layer.WMS.Untiled("Ortsnamen","http://gdi.bkg.bund.de//cgi-bin/mapserv",{map:"/srv/www/htdocs/navigation_bkg_neu_2.map",layers:"ortsnamen_bdlm",JAHR:"2006",format:"image/png",bgcolor:"0xffffff",transparent:"true"},
{isBaseLayer:false});

var geoportal_top_overlay_street= new
OpenLayers.Layer.WMS.Untiled("Strassen","http://gdi.bkg.bund.de//cgi-bin/mapserv",{map:"/srv/www/htdocs/navigation_bkg_neu_2.map",layers:"ortsstrassen_bdlm,kreisstrassen_250,kreisstrassen_bdlm,landesstrassen_250,landesstrassen_bdlm,bundesstrassen_250,bundesstrassen_bdlm,autobahnen_dlm250,autobahnen_bdlm,landesgrenze_l",JAHR:"2006",format:"image/png",bgcolor:"0xffffff",transparent:"true"},
{isBaseLayer:false});

var geoportal_top_overlay_wald_see = new
OpenLayers.Layer.WMS.Untiled("Waelder/Seen/Ortslagen","http://gdi.bkg.bund.de//cgi-bin/mapserv",{map:"/srv/www/htdocs/navigation_bkg_neu_2.map",layers:"vegetation_1000,gewaesser_1000_l,gewaesser_dlm250_fl,binnengewaesser_bdlm,ortslage_bdlm",JAHR:"2006",format:"image/png",bgcolor:"0xffffff",transparent:"true"},
{isBaseLayer:false});

map.addLayers([geoportal_top_overlay_wald_see,geoportal_top_overlay_street,geoportal_top_overlay_citiesnames]);

var flo_overlay_kataster = new
OpenLayers.Layer.WMS.Untiled("Kataster","/agroConnect-Web/FLOrlpTineTunnel",{route:"https://www.flo.rlp.de/mapserver",map:"kataster.map",layers:"alk_ora",JAHR:"2006",format:"image/png",bgcolor:"0xffffff",transparent:"true"},
{isBaseLayer:false});

map.addLayers([flo_overlay_kataster]);

url="/agroConnect-Web/FLOrlpTineTunnel?getAllFeatures"; //URL to Servlet,
response = FeatureCollection

var schlaege = new OpenLayers.Layer.GML("Schlaege",url,{style: new
OpenLayers.Style({

strokeColor: "rgb(128,0,255)",strokeWidth: 3,strokeOpacity: 0.5,fillColor:
"rgb(100,100,255)",fillOpacity: 0.1,hoverStrokeColor: "red"})});

map.addLayer(schlaege);

map.zoomToMaxExtent();

regSelectField(map);

}


//----------------------------------------------

function regSelectField(map)

{

map.events.register('click', map, function (e) {

var
wfsCurrentURL="/agroConnect-Web/UpdateTineSelection?map=gazetteer.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=getFeature&TYPENAME=ms:schlag_box&BBOX="

var tolerance = new OpenLayers.Pixel(1, 1);

var min_px = new OpenLayers.Pixel(e.xy.x - tolerance.x, e.xy.y +
tolerance.y);

var max_px = new OpenLayers.Pixel(e.xy.x + tolerance.x, e.xy.y -
tolerance.y);

var min_ll = map.getLonLatFromPixel(min_px);

var max_ll = map.getLonLatFromPixel(max_px);

var url = wfsCurrentURL + min_ll.lon + ','+ min_ll.lat + ','+ max_ll.lon
+',' + max_ll.lat;

if(window.XMLHttpRequest){xmlhttp=new XMLHttpRequest();}

// code for IE

if (window.ActiveXObject){xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");}

if(xmlhttp!=null) {xmlhttp.open("GET",url,false);xmlhttp.send(null); }

drawGMLLayers();

});

}

//----------------------------------------------

function drawGMLLayers(){

if(single!=null)

map.removeLayer(single);

single= new OpenLayers.Layer.GML("Schlag",singleurl,{style: new
OpenLayers.Style({

strokeColor: "rgb(255,0,255)",strokeWidth: 3,strokeOpacity: 1.0,fillColor:
"rgb(255,0,255)",fillOpacity: 0.1,hoverStrokeColor: "red"})});

map.addLayer(single);

}


Regards

Christine






----- Original Message -----
From: "Christopher Schmidt" <[hidden email]>
To: "Christine Spietz" <[hidden email]>
Cc: <[hidden email]>
Sent: Wednesday, March 21, 2007 12:43 PM
Subject: Re: [OpenLayers-Dev] GML Layers is no more visible in vector
sandbox revision 2823


> On Wed, Mar 21, 2007 at 08:49:59AM +0100, Christine Spietz wrote:
>> Hi Erik,
>>
>> I have updated to the libraries of
>> http://svn.openlayers.org/trunk/openlayers revision 2828, but now it's
>> working less then before.
>> I can not see any map anymore.
>> >----------------------------------->ERROR-MESSAGE>----------------------------------->
>> OpenLayers.MouseListener.MouseDefaults is not a constructor
>> var mouseListener = new OpenLayers.MouseListener.MouseDefaults();
>> in Map.js line 229.
>> >----------------------------------->END OF
>> >ERROR-MESSAGE>----------------------------------->
>>
>> The thing is: This line (mouseListener = ...) is not contained in Map.js
>> of
>> the actual trunk-version of OpenLayers. So I thought I might have
>> embedded
>> the wrong OpenLayers-folder in my page, but this is also not the case.
>>
>> Do you have an idea, what may have gone wrong? Is it a bug in the actual
>> trunk version or what else coul be the cause?
>
> Much of the code between the existing trunk and the old vector branch
> was refactored. http://openlayers.org/dev/examples/ has a list of
> examples -- including gml-layer and EditingToolbar -- that demonstrate
> the new functionality. Please refer to these examples for more
> information on how to get started with the trunk version of the vector
> tools.
>
> Regards,
> --
> Christopher Schmidt
> MetaCarta
>

_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: GML Layers is no more visible in vector sandbox revision 2823

Christopher Schmidt-2
On Thu, Mar 22, 2007 at 12:36:22PM +0100, Christine Spietz wrote:

> Hi again,
>
> Also I 'm still getting the curios error:
> >>OpenLayers.MouseListener.MouseDefaults is not a constructor
> >>var mouseListener = new OpenLayers.MouseListener.MouseDefaults();
> >>in Map.js line 229.
>
> I'm really convinced that I do not use the code which causes the error, so
> I guessed it was an error in OpenLayers. But this also seems not to be the
> case....

Line 229 in Map.js is empty in SVN. Your Map.js is not the same as
http://svn.openlayers.org/trunk/openlayers/lib/OpenLayers/Map.js .

disciplina:~/world_factbk/openlayers/lib/OpenLayers crschmidt$ svn info
Map.js
Path: Map.js
Name: Map.js
URL: http://svn.openlayers.org/trunk/openlayers/lib/OpenLayers/Map.js

If you run svn info on your Map.js file, I expect you will find that it
does not have the above in the "URL" field of the output.  

Please try checking out a *fresh* copy of OpenLayers from SVN, and
report if you are still having the same problems with the MouseListener.

Regards,
--
Christopher Schmidt
MetaCarta
_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: GML Layers is no more visible in vector sandbox revision 2823

Christine Spietz
Hi Christopher,

I clicked the right mouse button on file Map.js and looked at properties
http://svn.openlayers.org/trunk/openlayers/lib/OpenLayers/Map.js is the path
of my Map.js and I know that the line is empty.

I included the libs with <script src="lib/OpenLayers.js" />
and in folder lib are the libs of the actual OpenLayers trunk :-(

I did a new checkout of the actual version (revision 2846) but still the
same error.

Regards

Christine

----- Original Message -----
From: "Christopher Schmidt" <[hidden email]>
To: "Christine Spietz" <[hidden email]>
Cc: <[hidden email]>
Sent: Thursday, March 22, 2007 2:27 PM
Subject: Re: [OpenLayers-Dev] GML Layers is no more visible in vector
sandbox revision 2823


> On Thu, Mar 22, 2007 at 12:36:22PM +0100, Christine Spietz wrote:
>> Hi again,
>>
>> Also I 'm still getting the curios error:
>> >>OpenLayers.MouseListener.MouseDefaults is not a constructor
>> >>var mouseListener = new OpenLayers.MouseListener.MouseDefaults();
>> >>in Map.js line 229.
>>
>> I'm really convinced that I do not use the code which causes the error,
>> so
>> I guessed it was an error in OpenLayers. But this also seems not to be
>> the
>> case....
>
> Line 229 in Map.js is empty in SVN. Your Map.js is not the same as
> http://svn.openlayers.org/trunk/openlayers/lib/OpenLayers/Map.js .
>
> disciplina:~/world_factbk/openlayers/lib/OpenLayers crschmidt$ svn info
> Map.js
> Path: Map.js
> Name: Map.js
> URL: http://svn.openlayers.org/trunk/openlayers/lib/OpenLayers/Map.js
>
> If you run svn info on your Map.js file, I expect you will find that it
> does not have the above in the "URL" field of the output.
>
> Please try checking out a *fresh* copy of OpenLayers from SVN, and
> report if you are still having the same problems with the MouseListener.
>
> Regards,
> --
> Christopher Schmidt
> MetaCarta
>

_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: Pb with IE - Events click and mousedown

sylvainb
In reply to this post by sylvainb
I saw this :

http://trac.openlayers.org/ticket/555

That was my first problem, but easily solved by changing the onmousedown
event by onclick on the close button.

But there's still the same problem on IE, whene you pan the map with the
mouse (drag). When you release the mouse button, the onclick event is fired.

Sylvain Beorchia.


Sylvain Beorchia a écrit :

> Hi,
>
> Using events in OpenLayers, i'm setting these settings :
>
>    map.events.register("click", map, queryMap);
>    map.events.register("mousedown", map, clickOnMap);
>
>
> It works fine on firefox. When i click, querymap is called, and not
> clickOnMap. When i start to drag the map clickOnMap is called ok.
>
> But under IE, queryMap is always called. I mean, when i start to grad
> the map and then release the mouse button, the "click" event is fired.
>
> a bug ?
>
> Thanks.
>
> Sylvain Beorchia.
> Makina Corpus.
> _______________________________________________
> Dev mailing list
> [hidden email]
> http://openlayers.org/mailman/listinfo/dev

_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Adding empty features

Jeff Dege
I'm not at all sure I'd call this a bug.

Build a polygon feature from an empty pointlist:

   var pointList = [];
   var linearRing = new OpenLayers.Geometry.LinearRing(pointList);
   var polygonFeature = new OpenLayers.Feature.Vector(
      new OpenLayers.Geometry.Polygon([linearRing]), null,
displayStyle);
   displayAreasLayer.addFeatures([polygonFeature]);
 

Error on line 192 of Renderer/VML.js:

        var scaledBox =
            new OpenLayers.Bounds((bbox.left/resolution).toFixed(),
                                  (bbox.bottom/resolution).toFixed(),
                                  (bbox.right/resolution).toFixed(),
                                  (bbox.top/resolution).toFixed());

Microsoft JScript runtime error: 'left' is null or not an object


_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: Adding empty features

Christopher Schmidt-2
On Fri, Mar 23, 2007 at 01:00:25PM -0500, Jeff Dege wrote:
> I'm not at all sure I'd call this a bug.

This is a case where a debugging framework would come in handy. I agree
it's not a bug, but it should be addressed when we have a useful way of
reporting unexpected behavior to users so that they can debug it.

-- Chris

> Build a polygon feature from an empty pointlist:
>
>    var pointList = [];
>    var linearRing = new OpenLayers.Geometry.LinearRing(pointList);
>    var polygonFeature = new OpenLayers.Feature.Vector(
>       new OpenLayers.Geometry.Polygon([linearRing]), null,
> displayStyle);
>    displayAreasLayer.addFeatures([polygonFeature]);
>  
>
> Error on line 192 of Renderer/VML.js:
>
>         var scaledBox =
>             new OpenLayers.Bounds((bbox.left/resolution).toFixed(),
>                                   (bbox.bottom/resolution).toFixed(),
>                                   (bbox.right/resolution).toFixed(),
>                                   (bbox.top/resolution).toFixed());
>
> Microsoft JScript runtime error: 'left' is null or not an object
>
>
> _______________________________________________
> Dev mailing list
> [hidden email]
> http://openlayers.org/mailman/listinfo/dev
>

--
Christopher Schmidt
MetaCarta
_______________________________________________
Dev mailing list
[hidden email]
http://openlayers.org/mailman/listinfo/dev