Exemplo n.º 1
0
 public PerspectiveView(WorldViewModel worldViewModel)
 {
     InitializeComponent();
     _worldViewModel = worldViewModel;
     Perspective = new PerspectiveViewModel(worldViewModel, renderTarget.IsKeyPressed);
     renderTarget.AutomaticUpdateFPS = 60;
     renderTarget.Render += renderTargetUserControl_Render;
     renderTarget.RenderUI += PerspectiveViewControl_RenderUI;
     renderTarget.MouseEnter += PerspectiveViewControl_MouseEnter;
     renderTarget.MouseDown += PerspectiveViewControl_MouseDown;
     renderTarget.MouseUp += PerspectiveViewControl_MouseUp;
     renderTarget.MouseMove += PerspectiveViewControl_MouseMove;
 }
 public PerspectiveView(WorldViewModel worldViewModel)
 {
     InitializeComponent();
     _worldViewModel = worldViewModel;
     Perspective = new PerspectiveViewModel(worldViewModel, renderTarget.IsKeyPressed);
     renderTarget.AutomaticUpdateFPS = 60;
     renderTarget.Render += renderTargetUserControl_Render;
     renderTarget.RenderUI += PerspectiveViewControl_RenderUI;
     renderTarget.MouseEnter += PerspectiveViewControl_MouseEnter;
     renderTarget.MouseDown += PerspectiveViewControl_MouseDown;
     renderTarget.MouseUp += PerspectiveViewControl_MouseUp;
     renderTarget.MouseMove += PerspectiveViewControl_MouseMove;
     renderTarget.MouseDoubleClick += (s, e) => _worldViewModel.FollowSelected.Execute(null);
 }