示例#1
0
        private void Module3Button_Click(object sender, RoutedEventArgs e)
        {
            AnnouncementsWindow announcementsWindow = new AnnouncementsWindow(currentUser, currentUser.Modules[2]);

            Visibility = Visibility.Hidden;
            announcementsWindow.ShowDialog();
            Visibility = Visibility.Visible;
        }
示例#2
0
        private void Module1Button_Click(object sender, RoutedEventArgs e)
        {
            int moduleID = currentUser.Modules[0].ID;

            //currentUser.Modules[0].addAnnouncement("Title", "Body.");
            //currentUser.Modules[0].addAnnouncement("Title2", "This is the body of the second announcement.");
            //currentUser.Modules[0].addAnnouncement("Title3", "Body of announcement number 3.");
            //currentUser.Modules[0].Announcements[0].addComment("This is a test comment", currentUser);
            //currentUser.Modules[0].Announcements[0].addComment("This is also a test comment", currentUser);
            //currentUser.Modules[0].Announcements[2].addComment("This is also a test commentaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", currentUser);
            //currentUser.Modules[0].Announcements[0].addComment("This is also a test comment", currentUser);
            //currentUser.Modules[0].Announcements[0].addComment("This is also a test comment", currentUser);
            //currentUser.Modules[0].Announcements[1].addComment("This is also a test comment", currentUser);
            //currentUser.Modules[0].Announcements[2].addComment("This is also a test comment", currentUser);
            LoadModulesAnnouncements(currentUser.Modules[0]);
            AnnouncementsWindow announcementsWindow = new AnnouncementsWindow(currentUser, currentUser.Modules[0]);

            Visibility = Visibility.Hidden;
            announcementsWindow.ShowDialog();
            Visibility = Visibility.Visible;
        }