コード例 #1
0
        public void Show(string title)
        {
            _item.DisableDelete(true);
            _item.DisableRename(true);

            if (_view != null)
            {
                if (!string.IsNullOrEmpty(title))
                {
                    _view.Title = title;
                }

                // show work list button clicked > we're already on UI thread
                _view.Activate();
                return;
            }

            ViewUtils.RunOnUIThread(() =>
            {
                _view = WorkListViewFactory.CreateView(_worklist);

                _view.Owner = System.Windows.Application.Current.MainWindow;

                if (!string.IsNullOrEmpty(title))
                {
                    _view.Title = title;
                }

                _view.Closed += _view_Closed;

                _view.Show();
            });
        }