Comunidad de diseño web y desarrollo en internet online

como resumir este codigo que gasta mucha memoria?? AYUDAA

Citar            
MensajeEscrito el 29 Oct 2010 03:08 pm
package clasesMapaSalon{

//lala
import flash.display.MovieClip;

import flash.events.Event;
import flash.events.MouseEvent;
import flash.events.TimerEvent;
import flash.geom.Point;
import clasesMapaSalon.Info;


//importaciones del google map

import com.google.maps.LatLng;
import com.google.maps.Map;
import com.google.maps.MapEvent;
import com.google.maps.MapMouseEvent;
import com.google.maps.MapType;
import com.google.maps.controls.ControlPosition;
import com.google.maps.controls.ZoomControl;
import com.google.maps.overlays.Marker;
import com.google.maps.overlays.MarkerOptions;
import com.google.maps.services.ClientGeocoder;
import com.google.maps.services.ClientGeocoderOptions;
import com.google.maps.services.GeocodingEvent;


//para el marcador
import com.google.maps.controls.*;
import com.google.maps.overlays.*;
//clases para trabajar con rellenos y filetes
import com.google.maps.styles.FillStyle;
import com.google.maps.styles.StrokeStyle;










public class Main extends MovieClip {

private var map:Map;
private var mixml:XML;


private var marker:Marker;
private var marker2:Marker;
private var marker3:Marker;
private var marker4:Marker;
private var marker5:Marker;




private var marcoInfo:Info;

public function Main() {

super();
map = new Map();
//url.method="GET"
map.key="EDITADA";//KEY SEDALTEST
//map.setSize(new Point(350, 270));
map.addEventListener(MapEvent.MAP_READY, onMapReady);
map.setSize(new Point(350, 270));
//map.setCenter(new LatLng(-31.409619,-64.184532));
this.addChild(map);
map.x=241;
map.y=50;

//var opciones:MarkerOptions=new MarkerOptions({icon:new Icono()});
/*marker=new Marker(new LatLng(-34.734841,-59.150391));
map.addOverlay(marker);*/




}


private function onMapReady(event:Event):void {
//map.setCenter(new LatLng(-31.409619,-64.184532), 12, MapType.NORMAL_MAP_TYPE);
map.setCenter(new LatLng(-34.6098976135,-58.3917350769), 4, MapType.NORMAL_MAP_TYPE);
map.addControl(new ZoomControl());
//map.addControl(new PositionControl());
//map.addControl(new MapTypeControl());


marker=new Marker(new LatLng(-31.409619,-64.184532),new MarkerOptions({icon:new Logo()}));

marker2=new Marker(new LatLng(-34.603471,-58.383579),new MarkerOptions({icon:new Logo()}));
marker3=new Marker(new LatLng(-32.952936,-60.664272),new MarkerOptions({icon:new Logo()}));
marker4=new Marker(new LatLng(-37.984934,-57.586727),new MarkerOptions({icon:new Logo()}));
marker5=new Marker(new LatLng(-37.104668,-56.867788),new MarkerOptions({icon:new Logo()}));

map.addOverlay(marker);
map.addOverlay(marker2);
map.addOverlay(marker3);
map.addOverlay(marker4);
map.addOverlay(marker5);




marker.addEventListener(MapMouseEvent.CLICK, click1);
marker2.addEventListener(MapMouseEvent.CLICK, click2);
marker3.addEventListener(MapMouseEvent.CLICK, click3);
marker4.addEventListener(MapMouseEvent.CLICK, click4);
marker5.addEventListener(MapMouseEvent.CLICK, click5);


}



private function click1(e:MapMouseEvent):void {
trace("se apreto");
marcoInfo = new Info();

marcoInfo.x=241;
marcoInfo.y=330;

addChild(marcoInfo);
}



private function click2(e:MapMouseEvent):void {
trace("se apreto");
marcoInfo = new Info();

marcoInfo.x=241;
marcoInfo.y=330;

addChild(marcoInfo);
}


private function click3(e:MapMouseEvent):void {
trace("se apreto");
marcoInfo = new Info();

marcoInfo.x=241;
marcoInfo.y=330;

addChild(marcoInfo);
}

private function click4(e:MapMouseEvent):void {
trace("se apreto");
marcoInfo = new Info();

marcoInfo.x=241;
marcoInfo.y=330;

addChild(marcoInfo);
}


private function click5(e:MapMouseEvent):void {
trace("se apreto");
marcoInfo = new Info();
marcoInfo.x=241;
marcoInfo.y=330;

addChild(marcoInfo);
}









}
}

Por eze_ps

30 de clabLevel



 

chrome
Citar            
MensajeEscrito el 29 Oct 2010 04:18 pm
Tip 1: No pongas la clave de Google maps, habrá muchagente tentada de usártela
Tip 2: Quizás en vez de pegar 150 líneas de código sin formato, puedas darle formato y aunque sea tirar alguna hipótesis que anime a la gente a leerlo

Jorge

Por solisarg

BOFH

13669 de clabLevel

4 tutoriales
5 articulos

Genero:Masculino   Bastard Operators From Hell Premio_Secretos

Argentina

firefox
Citar            
MensajeEscrito el 29 Oct 2010 05:14 pm
se saco sola la clave, ayudame man

Por eze_ps

30 de clabLevel



 

chrome
Citar            
MensajeEscrito el 29 Oct 2010 05:45 pm
La quité yo para evitar que mi amigo hacker haga desastres con ella en Google Maps y encima te culpen a ti

Jorge

Por solisarg

BOFH

13669 de clabLevel

4 tutoriales
5 articulos

Genero:Masculino   Bastard Operators From Hell Premio_Secretos

Argentina

firefox
Citar            
MensajeEscrito el 29 Oct 2010 05:53 pm
gracias

Por eze_ps

30 de clabLevel



 

chrome
Citar            
MensajeEscrito el 29 Oct 2010 08:00 pm
eze_ps espero que ya hallas cambiado tus contraseñas de google, has lo a la brevedad (ahora)


y no vuelvas a poner tus contraseñas en publico.

por otro lado resume tu duda y solo pon el trozo de código el cual creas tiene el problema

Por Inyaka

Claber

3176 de clabLevel

9 tutoriales
2 articulos

Genero:Masculino   Desarrollador de GAIA

Programador y fotógrafo

firefox
Citar            
MensajeEscrito el 29 Oct 2010 08:03 pm
Ok, un amigo me ha comentado que han empezado a aparecer mapas raros en su sitio, y que el condominio que se supone muestra en la costa argentina ha mutado a un barrio del Bronx con marcadores de pizzerías. No digo que tenga que ver, pero estamos estudiando el caso a ver si está relacionado.

Jorge

Por solisarg

BOFH

13669 de clabLevel

4 tutoriales
5 articulos

Genero:Masculino   Bastard Operators From Hell Premio_Secretos

Argentina

firefox

 

Cristalab BabyBlue v4 + V4 © 2011 Cristalab
Powered by ClabEngines v4, HTML5, love and ponies.