示例#1
0
        private void LoadSavedDraft()
        {
            var draftModel = DraftService.GetDraftModel();

            if (draftModel == null)
            {
                return;
            }
            if (draftModel.StartDateTime > DateTime.MinValue)
            {
                StaticAssets.StartDateTime = draftModel.StartDateTime;
                SetLabelStartFromText();
            }
            if (draftModel.StopDateTime > DateTime.MinValue)
            {
                StaticAssets.StopDateTime = draftModel.StopDateTime;
            }
            if (draftModel.Duration > TimeSpan.MinValue)
            {
                StaticAssets.Duration = draftModel.Duration;
                SetLabelDurationText();
            }
            ChangeButtonStatus();
        }