RE: [OpenMap Users] OverviewMapHandler

From: Rubén Ruiz <vinilo@cancerbero.org>
Date: Thu Jul 15 2004 - 08:39:04 EDT

Ok, I fixed it by myself, thanks anyway...

I was not loading correctly the layer onto the OverviewMapHandler.

Thanks,
Rubén.

-----Mensaje original-----
De: owner-openmap-users@bbn.com [mailto:owner-openmap-users@bbn.com] En
nombre de Rubén Ruiz
Enviado el: miércoles, 14 de julio de 2004 20:45
Para: openmap-users@bbn.com
Asunto: [OpenMap Users] OverviewMapHandler

Hi all,

I'm trying to add an OverviewMapHandler in my app.
I've managed to put it in a Jpanel, but I can't view anything in the
overview map.
It seems to respond to center and zoom events, and controls the managed
mapbean recentering and zooming....but I can't see nothing... I append some
code to see if anyone can help me...

Thanks in advance,
Rubén.

 public void cargaOverViewMap() {
    _locator.addControlledMap(this.bufferedMapBean1);
    this.bufferedMapBean1.addProjectionListener(_locator);
    jPanel3.add(_locator.getMap(),BorderLayout.CENTER);
    jPanel3.addComponentListener(_locator);
    
    Properties locatorProps = this.cargaProps("mapas/locator.properties");
    _locator.setProperties("",locatorProps);
    Properties ovmProps = this.cargaProps("mapas/overviewLayer.properties");
    _locator.setProperties("overviewLayer",ovmProps);
  
    _locator.repaint();
  
  }

The props file are:
Locator.properties:

class=com.bbn.opemap.gui.OverviewMapHandler
overviewLayers=overviewLayer
overviewScaleFactor=10f
overviewMinScale=100000f
overviewStatusLayer.class=com.bbn.openmap.layer.OverviewMapAreaLayer
overviewMapHandler.lineColor=FF800000
threshold=200000000

overviewLayer.properties:
overviewLayer.class=com.bbn.openmap.layer.shape.ShapeLayer
overviewLayer.prettyName=world Overview
overviewLayer.shapeFile=mapas/PM_BASE_lin.shp
overviewLayer.lineColor=FFFFFFFF
overviewLayer.threshold=200000000

Maybe the real question is...how do i add a layer to the overview map? I
have some layers loaded in the mapbean, maybe using:
_locator.setLayers(_layerHandler.getLayers());???'

Or the overview map takes the layers directly from the mabbean when you set
the controlledMap??

Any given help is wellcome...

--
[To unsubscribe to this list send an email to "majdart@bbn.com"
with the following text in the BODY of the message "unsubscribe
openmap-users"]
--
[To unsubscribe to this list send an email to "majdart@bbn.com"
with the following text in the BODY of the message "unsubscribe openmap-users"]
Received on Thu Jul 15 08:40:27 2004

This archive was generated by hypermail 2.1.8 : Thu May 12 2005 - 07:18:39 EDT