Exemplo n.º 1
0
        public Form1()
        {
            InitializeComponent();
            var a = App.Configuration.WorkSpaces;

            this.Closing += OnClosing;

            TopLevel              = true;
            this.Text             = "PBSC Analyzer";
            _solutionTree         = new SolutionTree();
            _openedDocumentsPanel = new OpenedDocumentsPanel();
            _solutionTree.Show(MainDockPanel, DockState.DockLeft);
            _solutionTree.treeView1.NodeMouseClick         += treeView1_NodeMouseClick;
            _openedDocumentsPanel.treeView1.NodeMouseClick += treeView1_NodeMouseClick;

            _workspaceListPanel = new WorkspaceListPanel();
            //_workspaceListPanel.Show(_solutionTree.FloatPane, DockAlignment.Bottom,20);
            _workspaceListPanel.Show(MainDockPanel, DockState.DockLeftAutoHide);
            _openedDocumentsPanel.Show(MainDockPanel, DockState.DockLeftAutoHide);
            _workspaceListPanel.SetWorkspaceList();

            MainEngine.Instance.SolutionTree         = _solutionTree;
            MainEngine.Instance.OpenedDocumentsPanel = _openedDocumentsPanel;
            MainEngine.Instance.MainDockPanel        = MainDockPanel;
            MainEngine.Instance.MainForm             = this;
            MainEngine.Instance.LoadWorkSpace(App.Configuration.CurrentWorkSpaceName);
        }
Exemplo n.º 2
0
 public void LoadWorkSpace(string currentWorkSpaceName, bool reloadOpenedDocumetns = false)
 {
     IsLoadingWorkspase = true;
     if (reloadOpenedDocumetns == false)
     {
         CloseAllDocuments();
     }
     App.Configuration.CurrentWorkSpaceName = currentWorkSpaceName;
     //ShowWaitPanel(true);
     //Action a = () =>
     {
         ClearSolutionTree();
         var workSpaceItem = GetWorkspace(currentWorkSpaceName);
         foreach (var item in workSpaceItem.SourceFloders)
         {
             LoadSourceFolder(item);
         }
     };
     //a.BeginInvoke(ar => {/* ShowWaitPanel(false); */}, null);
     SolutionTree.SetSearchHistoryListBox();
     LoadDocumentsListFromWorkspace(reloadOpenedDocumetns);
     SetMainFormCaption();
     IsLoadingWorkspase = false;
     OpenedDocumentsPanel.RefreshOpenedDocumentsList();
     RefershOpenedDocumentsPanelCaption();
 }
Exemplo n.º 3
0
 public void SelectedTextFindInAllFiles(string selectedText)
 {
     if (!string.IsNullOrEmpty(selectedText))
     {
         MyDockHelper.MakePanelVisible(SolutionTree);
         SolutionTree.SetAndFindInAllFiles(selectedText);
     }
 }
Exemplo n.º 4
0
        private void SetSearchProgress(int value)
        {
            return;

            if (value > 100)
            {
                value = 100;
            }
            SolutionTree.SetSearchProgress(value);
        }
Exemplo n.º 5
0
        public void FindFileName(string selectedText)
        {
//            SourceContainerDocument sourceDocument = MainForm.ActiveMdiChild as SourceContainerDocument;
//            if (sourceDocument != null) {
//                string selectedText = sourceDocument.SourceEditorPanel.fastColoredTextBox1.SelectedText;
            MyDockHelper.MakePanelVisible(SolutionTree);
            if (!string.IsNullOrEmpty(selectedText))
            {
                SolutionTree.SetAndFindFile(selectedText);
            }
//            }
        }
Exemplo n.º 6
0
 private void SetSolutionTreeStatusText(string s)
 {
     SolutionTree.SetStatusText(s);
 }