예제 #1
0
            public static string GetLocalizedWeek(Schedule.Week week)
            {
                switch (week)
                {
                case Schedule.Week.BothWeeks:
                    return(LocalizedResources.GetString("String_BothWeeks"));

                case Schedule.Week.WeekOne:
                    return(LocalizedResources.Common.GetStringWeekA());

                case Schedule.Week.WeekTwo:
                    return(LocalizedResources.Common.GetStringWeekB());

                default:
                    throw new NotImplementedException();
                }
            }
예제 #2
0
        internal static async Task <bool> ConfirmDelete(string message, string title)
        {
            MessageDialog dialog = new MessageDialog(message, title);

            var commandDelete = new UICommand(LocalizedResources.GetString("MenuItemDelete"));
            var commandCancel = new UICommand(LocalizedResources.GetString("MenuItemCancel"));

            dialog.Commands.Add(commandDelete);
            dialog.Commands.Add(commandCancel);

            var response = await dialog.ShowAsync();

            if (response == commandDelete)
            {
                return(true);
            }

            return(false);
        }