コード例 #1
0
ファイル: EntitySelector.cs プロジェクト: whztt07/DeltaEngine
		private void StartNewEditorIfEntityFound(Vector2D position)
		{
			foreach (
				Entity2D entity in entities.Where(entity => entity.RotatedDrawAreaContains(position)))
				if (EditorMode == EditorMode.Read)
					ActiveEditor = new EntityReader(entity);
				else
					// Can't test this with ncrunch as pausing time can mess up other tests at random
					ActiveEditor = new EntityWriter(entity); // ncrunch: no coverage
		}
コード例 #2
0
 private void StartNewEditorIfEntityFound(Vector2D position)
 {
     foreach (
         Entity2D entity in entities.Where(entity => entity.RotatedDrawAreaContains(position)))
     {
         if (EditorMode == EditorMode.Read)
         {
             ActiveEditor = new EntityReader(entity);
         }
         else
         {
             // Can't test this with ncrunch as pausing time can mess up other tests at random
             ActiveEditor = new EntityWriter(entity);                     // ncrunch: no coverage
         }
     }
 }
コード例 #3
0
		public void SetUp()
		{
			logo = new BouncingLogo();
			logo.Color = Color.White;
			reader = new EntityReader(logo);
		}