Esempio n. 1
0
        private void DownloadDetailContextMenu_Click(object sender, RoutedEventArgs e)
        {
            MenuItem cmi      = sender as MenuItem;
            dynamic  item     = cmi.DataContext;
            int      siteId   = Constants.SITE_DEF[item.SiteId].id;
            long     threadId = long.Parse(item.ThreadId);

            ScriptDialog dialog = new ScriptDialog(ScriptDialog.ScriptId.DOWNLOAD_ONE_DETAIL, threadId, siteId);

            if (dialog.ShowDialog() ?? false)
            {
                ReloadArticles();
            }
        }
Esempio n. 2
0
        private void DownloadButton_Click(object sender, RoutedEventArgs e)
        {
            ScriptDialog dialog = new ScriptDialog(ScriptDialog.ScriptId.UPDATE_ALL);

            if (dialog.ShowDialog() ?? false)
            {
                this.metaData    = MetaDataLoader.Load();
                currentId        = -1;
                searchingKeyword = null;
                currentState     = AppState.TOPICS;
                ReloadTopics();
                UpdateView();
            }
        }