/// <summary> /// Initializes a new instance of the ChannelViewModel class. /// </summary> public ChannelViewModel() { if (IsInDesignMode) { the_channel = new channel() { introduction = "捍卫真相与细节,一切谣言将在这里被终结", key="fact", name = "谣言粉碎机" }; } else { // Code runs "for real": Connect to service, etc... } Messenger.Default.Register<channel>(this, (action) => { the_channel = action; if (the_channel.MinisiteArticles.ArticleList.Count == 0) the_channel.MinisiteArticles.load_more(); }); }
private void _GoToViewChannel(channel a) { NavigationService.Navigate(new Uri("/ViewChannel.xaml", UriKind.Relative)); }