Ejemplo n.º 1
0
 public void de_highlight()
 {
     if (p_highlight != "")
     {
         IKmlPlacemark p_s_point = getStart(getByName(p_highlight));
         IKmlPlacemark p_f_point = getFinish(getByName(p_highlight));
         p_s_point.setStyleUrl(_style);
         p_f_point.setStyleUrl(_style);
         p_highlight = "";
     }
 }
Ejemplo n.º 2
0
        public void highlight(String name)
        {
            if (p_highlight != "")
            {
                de_highlight();
            }
            IKmlFolder    trip    = getByName(name);
            IKmlPlacemark s_point = getStart(trip);
            IKmlPlacemark f_point = getFinish(trip);

            _style = s_point.getStyleUrl();
            s_point.setStyleUrl("");
            f_point.setStyleUrl("");
            p_highlight = name;
        }
Ejemplo n.º 3
0
        public String insert(String name, IKmlFolder trip, String[] att)
        {
            de_highlight();
            int    index  = int.Parse(name.Split('_')[1]);
            String style  = "";
            String _style = "";

            IKmlFolder temp1 = getByName("Trip_" + index);
            IKmlFolder temp2 = getByName("Trip_" + (index + 1));

            IKmlObjectList points = temp1.getFeatures().getChildNodes();

            for (int ii = 0; ii != points.getLength(); ii++)
            {
                IKmlPlacemark point = (IKmlPlacemark)points.item(ii);
                trip.getFeatures().appendChild(point);
                if (ii == 1)
                {
                    style = point.getStyleUrl();
                }
            }

            points = temp2.getFeatures().getChildNodes();
            for (int ii = 0; ii != points.getLength(); ii++)
            {
                IKmlPlacemark point = (IKmlPlacemark)points.item(ii);
                if (ii == 1)
                {
                    _style = point.getStyleUrl();
                }
                point.setStyleUrl(style);
                trip.getFeatures().appendChild(point);
            }

            _core.RemoveAt(index - 1);
            _attr.RemoveAt(index - 1);

            _core.RemoveAt(index - 1);
            _attr.RemoveAt(index - 1);

            _core.Insert(index - 1, trip);
            _attr.Insert(index - 1, att);

            return(_style);
        }
Ejemplo n.º 4
0
 public void highlight(IKmlPlacemark point)
 {
     de_highlight();
     sel_style = point.getStyleUrl();
     point.setStyleUrl("");
     sel_point = point;
 }