コード例 #1
0
#pragma warning disable VSTHRD100 // Avoid async void methods
        private async void OnContextChanged(ContextChangeKind kind)
#pragma warning restore VSTHRD100 // Avoid async void methods
        {
            await _joinableTaskContext.Factory.SwitchToMainThreadAsync();

            ContextChanged?.Invoke(this, new ContextChangeEventArgs(kind));
        }
コード例 #2
0
        private void OnContextChanged(ContextChangeKind kind)
        {
            _foregroundDispatcher.AssertForegroundThread();

            var handler = ContextChanged;

            if (handler != null)
            {
                handler(this, new ContextChangeEventArgs(kind));
            }
        }
コード例 #3
0
        private void OnContextChanged(ProjectSnapshot project, ContextChangeKind kind)
        {
            _project = project;

            var handler = ContextChanged;

            if (handler != null)
            {
                handler(this, new ContextChangeEventArgs(kind));
            }
        }
コード例 #4
0
 public ContextChangeEventArgs(ContextChangeKind kind)
 {
     Kind = kind;
 }
        private void OnContextChanged(ContextChangeKind kind)
        {
            _foregroundDispatcher.AssertForegroundThread();

            ContextChanged?.Invoke(this, new ContextChangeEventArgs(kind));
        }
コード例 #6
0
 public DockableContent()
 {
     ContextChangeKind = AvalonDock.ContextChangeKind.PreviewMouseDown;
 }
コード例 #7
0
        private async Task OnContextChangedAsync(ContextChangeKind kind)
        {
            await _joinableTaskContext.Factory.SwitchToMainThreadAsync();

            ContextChanged?.Invoke(this, new ContextChangeEventArgs(kind));
        }