コード例 #1
0
        internal void SelectInSourceControlExplorer(dynamic serverPath, dynamic workspace, dynamic sourceControlExplorer)
        {
            var poller = new DispatchedPoller(10, TimeSpan.FromSeconds(0.5), () =>
            {
                return(!sourceControlExplorer.IsDisconnected);
            },
                                              () =>
            {
                SelectOneTimeInSourceControlExplorer(serverPath, workspace);
            });

            poller.Go();
        }
コード例 #2
0
        virtual public void DispatchScrollToSccExplorerSelection(TimeSpan interval, dynamic explorer)
        {
            dynamic listView = explorer.listViewExplorer;

            if (listView == null)
            {
                return;
            }

            Func <bool> condition = () => listView.SelectedIndices.Count > 0;
            Action      todo      = () =>
            {
                int selectedIndex = listView.SelectedIndices[0];
                listView.EnsureVisible(selectedIndex);
            };

            var poller = new DispatchedPoller(10, TimeSpan.FromSeconds(0.25), condition, todo);

            poller.Go();
        }