public RgMapControl() { mScreenDisplay = new RGeos.Display.ScreenDisplay(Handle); mScreenDisplay.DisplayTransformation.Zoom = 1.0f; InitializeComponent(); mMap = new RGeos.Carto.Map(); this.SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.UserPaint, true); this.SetStyle(ControlStyles.OptimizedDoubleBuffer, true); this.MouseDown += new MouseEventHandler(mPanel_MouseDown); this.MouseMove += new MouseEventHandler(mPanel_MouseMove); this.MouseUp += new MouseEventHandler(mPanel_MouseUp); this.Resize += new System.EventHandler(this.UcMapControl_Resize); }
public RgMapControl() { mScreenDisplay = new RGeos.Display.ScreenDisplay(Handle); mScreenDisplay.DisplayTransformation.Zoom = 1.0f; InitializeComponent(); mMap = new RGeos.Carto.Map(); this.SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.UserPaint, true); this.SetStyle(ControlStyles.OptimizedDoubleBuffer, true); this.MouseDown += new MouseEventHandler(mPanel_MouseDown); this.MouseMove += new MouseEventHandler(mPanel_MouseMove); this.MouseUp += new MouseEventHandler(mPanel_MouseUp); this.Resize += new System.EventHandler(this.UcMapControl_Resize); HookHelper mHook = HookHelper.Instance(); mHook.MapControl = this as IMapControl; timeTick.Interval = 500; timeTick.Tick += new EventHandler(timeTick_Tick); }