示例#1
0
 public void addTask(Task task)
 {
     task.init();
     tasks_.Add(task);
     if (!running_)
     {
         running_ = true;
         time_    = DateTime.UtcNow;
         EditorApplication.update += editorUpdate;
         all_ = 0f;
         editorUpdate();
     }
 }
示例#2
0
        /*
         * protected virtual void  OnDestroy(){
         *      try{
         *              for(int i=0; i< this.tasks_.Count; ++i){
         *                      Task task = this.tasks_[i] as Task;
         *                      task.shutdown();
         *              }
         *              tasks_ = new ArrayList();
         *      }catch(System.Exception e){
         *              Debug.LogWarning(e.Message);
         *      }
         * }*/


        public void addTask(Task task)
        {
            task.init();
            this.tasks_.Add(task);
        }
示例#3
0
		/*
		protected virtual void  OnDestroy(){
			try{
				for(int i=0; i< this.tasks_.Count; ++i){
					Task task = this.tasks_[i] as Task;
					task.shutdown();
				}
				tasks_ = new ArrayList();
			}catch(System.Exception e){ 
				Debug.LogWarning(e.Message);			
			}
		}*/
		

		public void addTask(Task task){
			task.init();
			this.tasks_.Add(task);
		}