コード例 #1
0
 public static Tuple<int, int> GetJumpPosition(Tuple<int,int[]>[] threads)
 {
     var window=new JumpToWindow(threads);
     window.Owner=App.Current.MainWindow;
     if(window.ShowDialog().Value) return Tuple.Create(window.viewModel.SelectedThread.Item1,window.viewModel.SelectedResNumber);
     else return null;
 }
コード例 #2
0
        public static Tuple <int, int> GetJumpPosition(Tuple <int, int[]>[] threads)
        {
            var window = new JumpToWindow(threads);

            window.Owner = App.Current.MainWindow;
            if (window.ShowDialog().Value)
            {
                return(Tuple.Create(window.viewModel.SelectedThread.Item1, window.viewModel.SelectedResNumber));
            }
            else
            {
                return(null);
            }
        }
コード例 #3
0
        private void JumpTo()
        {
            var jumpPosition = JumpToWindow.GetJumpPosition(threadIndices);

            if (jumpPosition == null)
            {
                return;
            }
            for (int i = 0; i < responses.Length; ++i)
            {
                if (responses[i].PartNumber == jumpPosition.Item1 && responses[i].ResNumber == jumpPosition.Item2)
                {
                    CurrentPosition = i;
                    CurrentResponse = responses[CurrentPosition];
                    System.Windows.Input.CommandManager.InvalidateRequerySuggested();
                }
            }
        }