Ejemplo n.º 1
0
        public void LoadFile(string path)
        {
            if (path == null)
            {
                throw new ArgumentNullException(nameof(path));
            }

            if (!File.Exists(path))
            {
                return;
            }

            LoadMEPackage(path);

            CodexMapControl?.Open(Pcc);

            QuestMapControl?.Open(Pcc);

            StateEventMapControl?.Open(Pcc);

            AddRecent(path, false);
            SaveRecentList();
            RefreshRecent(true, RFiles);
            Title = $"Plot Editor - {path}";
            OnPropertyChanged(nameof(CurrentFile));

            //Hiding "Recents" panel
            if (MainTabControl.SelectedIndex == 0)
            {
                MainTabControl.SelectedIndex = 1;
            }
        }
Ejemplo n.º 2
0
        public void OpenPccFile(string path)
        {
            if (path == null)
            {
                throw new ArgumentNullException(nameof(path));
            }

            if (!File.Exists(path))
            {
                return;
            }

            FileName = path;
            LoadME3Package(path);

            if (CodexMapControl != null)
            {
                CodexMapControl.Open(pcc);
            }

            if (QuestMapControl != null)
            {
                QuestMapControl.Open(pcc);
            }

            if (StateEventMapControl != null)
            {
                StateEventMapControl.Open(pcc);
            }
        }