コード例 #1
0
 public void ExecuteSVNAction(IEnumerable <ICommandLineOperation> operations)
 {
     if (!EditorApplication.isPlaying)
     {
         if (!IsBusy())
         {
             var commandQueue = new Queue <ICommandLineOperation>();
             foreach (var operationIt in operations)
             {
                 commandQueue.Enqueue(operationIt);
             }
             var commandQueueOperation = new QueuedCommandLineOperation(commandQueue);
             mSVNCurrentAssetsOperation = commandQueueOperation;
             OnDatabaseHandlerEvent(new SVNDatabaseBusyArgs(mSVNCurrentAssetsOperation));
             mSVNCurrentAssetsOperation.Execute();
         }
         else
         {
             string request = operations.Aggregate("", (current, operationIt) => current + (operationIt + "\n"));
             Debug.Log("Busy with: \n" + mSVNCurrentAssetsOperation + "\n\nOperation canceled: \n" + request);
         }
     }
     else
     {
         Debug.Log("SVN Action ignored during play");
     }
 }
コード例 #2
0
ファイル: CommandLine.cs プロジェクト: weimingtom/job_mobile
 public void Execute()
 {
     currentCommand.command.ExecutionFinished += (source, e) =>
     {
         if (commandQueue.Count > 0)
         {
             currentCommand = commandQueue.Dequeue();
             Execute();
         }
     };
     currentCommand.Execute();
 }
コード例 #3
0
 public void ExecuteSVNAction(ICommandLineOperation operation)
 {
     ExecuteSVNAction(new[] { operation });
 }
コード例 #4
0
 public SVNDatabaseBusyArgs(ICommandLineOperation commandlineOperation)
 {
     this.commandlineOperation = commandlineOperation;
 }