Exemple #1
0
        public void LoadStateFromIsoStorage()
        {
            if (!MainDataSource.Instance.IsActive)
            {
                UserDataSource        user      = CoreExtensions.LoadFromFile <UserDataSource>("user.xml");
                PinnedItemsCollection pins      = CoreExtensions.LoadFromFile <PinnedItemsCollection>("pins.xml");
                ForumCollection       forums    = CoreExtensions.LoadFromFile <ForumCollection>("forums.xml");
                UserBookmarks         bookmarks = CoreExtensions.LoadFromFile <UserBookmarks>("bookmarks.xml");
                ThreadTable           threads   = CoreExtensions.LoadFromFile <ThreadTable>("threads.xml");

                MainDataSource.Instance.CurrentUser = user;
                MainDataSource.Instance.Pins        = pins;
                MainDataSource.Instance.Forums      = forums;
                MainDataSource.Instance.Bookmarks   = bookmarks;
                MainDataSource.Instance.ThreadTable = threads;
            }
        }
Exemple #2
0
        public static ThreadViewPageState Load()
        {
            var state = CoreExtensions.LoadFromFile <ThreadViewPageState>(SAVE_FILE);

            return(state);
        }