Exemplo n.º 1
0
        public void CloseDialog()
        {
            if (_availablityChanged)
            {
                // Save the availabilities.
                App.WriteFilmFanAvailabilities();

                // Trigger a local notification.
                string title = "Availabilities saved";
                string text  = $"Film fan availabilites have been saved in {AppDelegate.DocumentsFolder}.";
                AlertRaiser.RaiseNotification(title, text);
            }

            // Close the dialog.
            Presentor.DismissViewController(this);
        }
Exemplo n.º 2
0
        private void SaveFestivalData()
        {
            // Write film fan availability.
            WriteFilmFanAvailabilities(DocumentsFolder);

            // Write film ratings.
            WriteFilmFanFilmRatings(DocumentsFolder);

            // Write screening info.
            string screeningInfoFileName = Path.GetFileName(ScreeningInfoFile);
            string screeningInfosPath    = Path.Combine(DocumentsFolder, screeningInfoFileName);

            new ScreeningInfo().WriteListToFile(screeningInfosPath, ScreeningsPlan.ScreeningInfos);

            // Display where the files have been stored.
            string title = "Festival Data Saved";
            string text  = $"Files of {Festival}{FestivalYear} are saved in {DocumentsFolder}";

            AlertRaiser.RaiseNotification(title, text);
        }