[gnome-calendar] month-view: only update selection if there's a start date
- From: Georges Basile Stavracas Neto <gbsneto src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-calendar] month-view: only update selection if there's a start date
- Date: Sat, 7 Oct 2017 14:41:29 +0000 (UTC)
commit ff9c663c8c647a765c0e29e6cb2b50722fee0cdd
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Sat Oct 7 11:20:23 2017 -0300
month-view: only update selection if there's a start date
We can potentially not have an end date set, but there's always
a start date. If there isn't, it means the user clicked from
outside of month view, or at an invalid cell, in which cases we
shouldn't display the quick add popover anyway.
src/views/gcal-month-view.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/views/gcal-month-view.c b/src/views/gcal-month-view.c
index 8c3027e..8a48989 100644
--- a/src/views/gcal-month-view.c
+++ b/src/views/gcal-month-view.c
@@ -232,7 +232,7 @@ emit_create_event (GcalMonthView *self)
GCAL_ENTRY;
- if (!self->end_mark_cell)
+ if (!self->start_mark_cell || !self->end_mark_cell)
GCAL_RETURN (FALSE);
should_clear_end = FALSE;
@@ -534,7 +534,7 @@ update_month_cells (GcalMonthView *self)
selection_start = self->start_mark_cell;
selection_end = self->end_mark_cell;
- if (selection_start || selection_end)
+ if (selection_start)
{
if (!selection_end)
selection_end = selection_start;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]