Skip to content

Commit b6bec65

Browse files
committed
Release 4.8.2
1 parent 709f3ee commit b6bec65

File tree

9 files changed

+39
-22
lines changed

9 files changed

+39
-22
lines changed

core/Constants.vala

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,5 @@ namespace Constants {
2121
public const string KOFI_URL = "https://ko-fi.com/alainm23";
2222
public const string MATRIX_URL = "https://matrix.to/#/#useplanify:matrix.org";
2323
public const bool SHOW_WHATSNEW = false;
24+
public const bool BLOCK_PAST_DAYS = false;
2425
}

core/Widgets/Calendar/Calendar.vala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ public class Widgets.Calendar.Calendar : Gtk.Box {
5252

5353
public signal void day_selected ();
5454

55-
public Calendar (bool block_past_days = false) {
55+
public Calendar (bool block_past_days = Constants.BLOCK_PAST_DAYS) {
5656
Object (
5757
block_past_days: block_past_days,
5858
orientation: Gtk.Orientation.VERTICAL

core/Widgets/DateTimePicker/DateTimePicker.vala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ public class Widgets.DateTimePicker.DateTimePicker : Gtk.Popover {
143143
content_box.append (action_revealer);
144144

145145
var back_item = new Widgets.ContextMenu.MenuItem (_("Back"), "go-previous-symbolic");
146-
calendar_view = new Widgets.Calendar.Calendar (false);
146+
calendar_view = new Widgets.Calendar.Calendar ();
147147

148148
var calendar_box = new Gtk.Box (Gtk.Orientation.VERTICAL, 0) {
149149
hexpand = true

core/Widgets/DateTimePicker/ScheduleButton.vala

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121

2222
public class Widgets.ScheduleButton : Gtk.Grid {
2323
public bool is_board { get; construct; }
24+
public string label { get; construct; }
2425

2526
private Gtk.Label due_label;
2627

@@ -61,18 +62,20 @@ public class Widgets.ScheduleButton : Gtk.Grid {
6162

6263
public signal void date_changed (GLib.DateTime? date);
6364

64-
public ScheduleButton () {
65+
public ScheduleButton (string label = _("Schedule")) {
6566
Object (
6667
is_board: false,
6768
valign: Gtk.Align.CENTER,
68-
tooltip_text: _("Schedule")
69+
tooltip_text: label,
70+
label: label
6971
);
7072
}
7173

72-
public ScheduleButton.for_board () {
74+
public ScheduleButton.for_board (string label = _("Schedule")) {
7375
Object (
7476
is_board: true,
75-
tooltip_text: _("Schedule")
77+
tooltip_text: label,
78+
label: label
7679
);
7780
}
7881

@@ -90,7 +93,7 @@ public class Widgets.ScheduleButton : Gtk.Grid {
9093
due_image = new Gtk.Image ();
9194
due_image.icon_name = "month-symbolic";
9295

93-
due_label = new Gtk.Label (_("Schedule")) {
96+
due_label = new Gtk.Label (label) {
9497
xalign = 0,
9598
use_markup = true,
9699
ellipsize = Pango.EllipsizeMode.END
@@ -146,7 +149,7 @@ public class Widgets.ScheduleButton : Gtk.Grid {
146149
private void build_card_ui () {
147150
due_image = new Gtk.Image.from_icon_name ("month-symbolic");
148151

149-
var title_label = new Gtk.Label (_("Schedule")) {
152+
var title_label = new Gtk.Label (label) {
150153
halign = START,
151154
css_classes = { "title-4", "caption" }
152155
};
@@ -198,11 +201,11 @@ public class Widgets.ScheduleButton : Gtk.Grid {
198201
public void update_from_item (Objects.Item item) {
199202
if (is_board) {
200203
due_label.label = _("Set a Due Date");
201-
tooltip_text = _("Schedule");
204+
tooltip_text = label;
202205
due_image.icon_name = "month-symbolic";
203206
} else {
204-
due_label.label = _("Schedule");
205-
tooltip_text = _("Schedule");
207+
due_label.label = label;
208+
tooltip_text = label;
206209
due_image.icon_name = "month-symbolic";
207210
}
208211

@@ -261,8 +264,8 @@ public class Widgets.ScheduleButton : Gtk.Grid {
261264
}
262265

263266
public void reset () {
264-
due_label.label = _("Schedule");
265-
tooltip_text = _("Schedule");
267+
due_label.label = label;
268+
tooltip_text = label;
266269
due_image.icon_name = "month-symbolic";
267270
datetime = null;
268271
datetime_picker.reset ();

core/Widgets/ReminderPicker/ReminderPicker.vala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ public class Widgets.ReminderPicker._ReminderPicker : Gtk.Popover {
125125
}
126126

127127
private Gtk.Widget get_picker () {
128-
calendar = new Widgets.Calendar.Calendar (true) {
128+
calendar = new Widgets.Calendar.Calendar () {
129129
vexpand = true,
130130
hexpand = true
131131
};

data/io.github.alainm23.planify.appdata.xml.in.in

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,14 @@
6767
<url type="donation">https://www.patreon.com/alainm23</url>
6868
<launchable type="desktop-id">@[email protected]</launchable>
6969
<releases>
70+
<release version="4.8.2" date="2024-06-03">
71+
<description translate="no">
72+
<ul>
73+
<li>Fixed bug not showing overdue tasks.</li>
74+
</ul>
75+
</description>
76+
</release>
77+
7078
<release version="4.8" date="2024-05-31">
7179
<description translate="no">
7280
<ul>

meson.build

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
project(
22
'io.github.alainm23.planify',
33
'vala', 'c',
4-
version: '4.8'
4+
version: '4.8.2'
55
)
66

77
gnome = import('gnome')

src/Dialogs/DatePicker.vala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ public class Dialogs.DatePicker : Adw.Dialog {
8585
items_card.append (no_date_item);
8686
items_card.add_css_class ("card");
8787

88-
calendar_view = new Widgets.Calendar.Calendar (false) {
88+
calendar_view = new Widgets.Calendar.Calendar () {
8989
margin_top = 6,
9090
margin_bottom = 6
9191
};

src/Views/Today.vala

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -118,18 +118,17 @@ public class Views.Today : Adw.Bin {
118118
};
119119

120120
overdue_label.add_css_class ("font-bold");
121-
122-
var reschedule_button = new Gtk.Button.with_label (_("Reschedule")) {
123-
hexpand = true,
124-
halign = Gtk.Align.END
125-
};
126121

127-
reschedule_button.add_css_class ("flat");
122+
var reschedule_button = new Widgets.ScheduleButton (_("Reschedule")) {
123+
visible_clear_button = false,
124+
visible_no_date = true
125+
};
128126

129127
var overdue_header_box = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 0) {
130128
margin_start = 26,
131129
};
132130
overdue_header_box.append (overdue_label);
131+
overdue_header_box.append (reschedule_button);
133132

134133
overdue_listbox = new Gtk.ListBox () {
135134
valign = Gtk.Align.START,
@@ -373,6 +372,12 @@ public class Views.Today : Adw.Bin {
373372
listbox.invalidate_filter ();
374373
overdue_listbox.invalidate_filter ();
375374
});
375+
376+
reschedule_button.date_changed.connect ((datetime) => {
377+
foreach (unowned Gtk.Widget child in Util.get_default ().get_children (overdue_listbox) ) {
378+
((Layouts.ItemRow) child).update_due (datetime);
379+
}
380+
});
376381
}
377382

378383
private void check_placeholder () {

0 commit comments

Comments
 (0)