예제 #1
0
        void mbtnActiveCalendars_Click(object sender, EventArgs e)
        {
            Application.DoEvents();
            var suv = new SelectUsersView(ModelManager.UserService.GetActiveUsersList(), this.myController.ActiveUsersList, "Kalender der Kollegen");

            if (suv.ShowDialog(this) == DialogResult.OK)
            {
                this.myController.ClearActiveUserList();
                foreach (var user in suv.CheckedUsersList)
                {
                    this.myController.AddUserCalendar(user as User);
                }
                this.mlblActiveUsers.Text = this.myController.ActiveUserNames;

                // Wenn der Kalender des in den CalendarSettings eingestellte TargetUser nicht
                // angezeigt wird ...
                var currentUser = ModelManager.UserService.CurrentUser;
                if (!this.myController.ActiveUsersList.Contains(currentUser.CalendarSettings.TargetUser))
                {
                    var csv = new CalendarSettingsView(currentUser.CalendarSettings);
                    csv.ShowDialog();
                }

                this.DayViewMain.Invalidate();
            }
        }
예제 #2
0
        void ShowCalendarSettings()
        {
            if (this.myCurrentUser == null)
            {
                this.myCurrentUser = ModelManager.UserService.CurrentUser;
            }
            var csv = new CalendarSettingsView(this.myCurrentUser.CalendarSettings);

            csv.ShowDialog();
        }
예제 #3
0
        void ShowCalendarSettings()
        {
            var currentUser = ModelManager.UserService.CurrentUser;
            var csv         = new CalendarSettingsView(currentUser.CalendarSettings);

            csv.ShowDialog();
            if (!this.myController.ActiveUsersList.Contains(currentUser.CalendarSettings.TargetUser))
            {
                this.myController.ActiveUsersList.Add(currentUser.CalendarSettings.TargetUser);
            }
            this.mlblActiveUsers.Text = this.myController.ActiveUserNames;
        }