diff options
-rw-r--r-- | Xamarin.Forms.Platform.Tizen/Renderers/DatePickerRenderer.cs | 19 | ||||
-rw-r--r-- | Xamarin.Forms.Platform.Tizen/Renderers/TimePickerRenderer.cs | 19 |
2 files changed, 24 insertions, 14 deletions
diff --git a/Xamarin.Forms.Platform.Tizen/Renderers/DatePickerRenderer.cs b/Xamarin.Forms.Platform.Tizen/Renderers/DatePickerRenderer.cs index 39a25295..73f8eab3 100644 --- a/Xamarin.Forms.Platform.Tizen/Renderers/DatePickerRenderer.cs +++ b/Xamarin.Forms.Platform.Tizen/Renderers/DatePickerRenderer.cs @@ -51,15 +51,20 @@ namespace Xamarin.Forms.Platform.Tizen void OnEntryClicked(object sender, EventArgs e) { - Native.DateTimePickerDialog dialog = new Native.DateTimePickerDialog(Forms.Context.MainWindow) + // For EFL Entry, the event will occur even if it is currently disabled. + // If the problem is resolved, no conditional statement is required. + if (Element.IsEnabled) { - Title = DialogTitle - }; + Native.DateTimePickerDialog dialog = new Native.DateTimePickerDialog(Forms.Context.MainWindow) + { + Title = DialogTitle + }; - dialog.InitializeDatePicker(Element.Date, Element.MinimumDate, Element.MaximumDate); - dialog.DateTimeChanged += OnDateTimeChanged; - dialog.Dismissed += OnDialogDismissed; - dialog.Show(); + dialog.InitializeDatePicker(Element.Date, Element.MinimumDate, Element.MaximumDate); + dialog.DateTimeChanged += OnDateTimeChanged; + dialog.Dismissed += OnDialogDismissed; + dialog.Show(); + } } void OnDateTimeChanged(object sender, Native.DateChangedEventArgs dcea) diff --git a/Xamarin.Forms.Platform.Tizen/Renderers/TimePickerRenderer.cs b/Xamarin.Forms.Platform.Tizen/Renderers/TimePickerRenderer.cs index 211ccf38..bdad8a9f 100644 --- a/Xamarin.Forms.Platform.Tizen/Renderers/TimePickerRenderer.cs +++ b/Xamarin.Forms.Platform.Tizen/Renderers/TimePickerRenderer.cs @@ -56,15 +56,20 @@ namespace Xamarin.Forms.Platform.Tizen void OnClicked(object o, EventArgs e) { - Native.DateTimePickerDialog dialog = new Native.DateTimePickerDialog(Forms.Context.MainWindow) + // For EFL Entry, the event will occur even if it is currently disabled. + // If the problem is resolved, no conditional statement is required. + if (Element.IsEnabled) { - Title = DialogTitle - }; + Native.DateTimePickerDialog dialog = new Native.DateTimePickerDialog(Forms.Context.MainWindow) + { + Title = DialogTitle + }; - dialog.InitializeTimePicker(_time, null); - dialog.DateTimeChanged += OnDialogTimeChanged; - dialog.Dismissed += OnDialogDismissed; - dialog.Show(); + dialog.InitializeTimePicker(_time, null); + dialog.DateTimeChanged += OnDialogTimeChanged; + dialog.Dismissed += OnDialogDismissed; + dialog.Show(); + } } void OnDialogTimeChanged(object sender, Native.DateChangedEventArgs dcea) |