Carsten,
I've recently made such changes to the InformationDelegator.
This delegator has two default information line holders. One is the
coordinate information line and the other is a default "map object"
information line.
I found that I needed three information lines to display secondary
information like you are describing. But I also needed to keep information
in the "coordinate" and "map object" information lines.
So, I overrode the "initWidgets" method in the InformationDelegator class as
I could not figure out how to add such a component otherwise.
In the initwidgets, I simply rebuilt the panel using the default information
line holders. Then I added my own. You have to add it to the panel
(obviously) and then all so to the array list of line holders using the
addInfoLine() method. I also created a constant to reference the "index" of
the new line holder. Then I fired an "InfoDisplayEvent" from my mouse mode
when appropriate. Like this...
InfoDisplayEvent event = new InfoDisplayEvent(this,
infoline,
MyInformationDelegator.MY_INFO_LINE);
infoDelegator.requestInfoLine(event);
I hope this helps.
-Adam
-- W. Adam Brightwell Software Engineer, MTCSC Certified Scrum Master Email: wbrightwell@mtcsc.com Office: 843-856-1935/1985 x51632 Cell: 843-810-8701 > From: "Carsten Ø. Madsen" <com@navicon.dk> > Organization: NAVICON A/S > Date: Thu, 13 Jan 2011 13:59:57 +0100 > To: <openmap-users@bbn.com> > Subject: [OpenMap Users] Extend statusbar information (info delegator) when > drawing polygons? > > Hello > > I would like to extend the status bar information to behave like the > distance tool when polygons are drawn/created so that the distance > between the current location of the mouse and the last node added to the > polygon (if any) is printed in the statusbar. > > I guess I have to do something with EditorLayerMouseMode but I have no > clue on how to proceed. Any hints will be appreciated. > > BR > Carsten > > -- > [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 Jan 13 09:13:01 2011
This archive was generated by hypermail 2.1.8 : Thu Jan 13 2011 - 09:13:02 EST