コード例 #1
0
 internal DispatcherOperation(
     Dispatcher dispatcher,
     Delegate method,
     DispatcherPriority priority,
     object[] args,
     CancellationToken cancellationToken,
     DispatcherOperationTaskSource taskSource)
 {
     Dispatcher             = dispatcher;
     this.method            = method;
     Priority               = priority;
     this.args              = args;
     this.cancellationToken = cancellationToken;
     this.taskSource        = taskSource;
     Status = DispatcherOperationStatus.Pending;
 }
コード例 #2
0
        internal DispatcherOperation(
            Dispatcher dispatcher,
            Delegate method,
            DispatcherPriority priority,
            object args,
            int numArgs,
            DispatcherOperationTaskSource taskSource,
            bool useAsyncSemantics)
        {
            _dispatcher = dispatcher;
            _method     = method;
            _priority   = priority;
            _numArgs    = numArgs;
            _args       = args;

            _executionContext = CulturePreservingExecutionContext.Capture();

            _taskSource = taskSource;
            _taskSource.Initialize(this);

            _useAsyncSemantics = useAsyncSemantics;
        }
コード例 #3
0
ファイル: DispatcherOperation.cs プロジェクト: JianwenSun/cc
        internal DispatcherOperation(
            Dispatcher dispatcher,
            Delegate method,
            DispatcherPriority priority,
            object args,
            int numArgs,
            DispatcherOperationTaskSource taskSource,
            bool useAsyncSemantics)
        {
            _dispatcher = dispatcher;
            _method = method;
            _priority = priority;
            _numArgs = numArgs;
            _args = args;

            _executionContext = ExecutionContext.Capture();

            _taskSource = taskSource;
            _taskSource.Initialize(this);
            
            _useAsyncSemantics = useAsyncSemantics;
        }