/// <summary> /// Constructeur par défaut. /// </summary> public EnVoiturePanel() { this.Enabled = true; DoubleBuffered = true; this._usagers = new List <UsagerWidget>(); this._usagers.Add(new VoitureWidget(0, 0, 10, 20, 80)); this._usagers.Add(new VoitureWidget(150, 150, 10, 20, 80)); this._usagers.Add(new VoitureWidget(240, 240, 10, 20, 80)); this.voiture = (_usagers[0] as VoitureWidget).Voiture; BoiteAOutils = new BoiteAOutils(); this.Routes = new List <RouteWidget>(); foreach (Route route in Route.Generer(6, 5)) { Routes.Add(new RouteWidget(route)); } foreach (Route route in Route.Generer(6, 6)) { Routes.Add(new RouteWidget(route)); } this.Paint += new PaintEventHandler(EnVoiture_Paint); InitializeComponent(); }
/// <summary> /// Constructeur par défaut. /// </summary> public EnVoiturePanel() { this.Enabled = true; DoubleBuffered = true; this._usagers = new List <UsagerWidget>(); this._usagers.Add(new VoitureWidget(0, 0, 10, 20, 80)); this._usagers.Add(new VoitureWidget(150, 150, 10, 20, 80)); this._usagers.Add(new VoitureWidget(240, 240, 10, 20, 80)); this.voiture = (_usagers[0] as VoitureWidget).Voiture; BoiteAOutils = new BoiteAOutils(); this.Routes = new List <RouteWidget>(); foreach (Route route in Route.Generer(6, 5)) { Routes.Add(new RouteWidget(route)); } foreach (Route route in Route.Generer(6, 6)) { Routes.Add(new RouteWidget(route)); } this.Paint += new PaintEventHandler(EnVoiture_Paint); InitializeComponent(); RunningPath = AppDomain.CurrentDomain.BaseDirectory; resourcePath = string.Format("{0}Resources", Path.GetFullPath(Path.Combine(RunningPath, @"..\..\"))); }