[geary/wip/765516-gtk-widget-conversation-viewer: 112/142] Always allow last messages in a convo to be expanded.
- From: Michael Gratton <mjog src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [geary/wip/765516-gtk-widget-conversation-viewer: 112/142] Always allow last messages in a convo to be expanded.
- Date: Fri, 2 Sep 2016 04:35:02 +0000 (UTC)
commit bc57913f957850dfe167d51a34a3f603f0b9ee44
Author: Michael James Gratton <mike vee net>
Date: Thu Aug 11 18:03:16 2016 +1000
Always allow last messages in a convo to be expanded.
Sent messages will be appended last to a convo when they get synced, so
they should be able to be expanded.
.../conversation-viewer/conversation-listbox.vala | 12 ++++++++----
1 files changed, 8 insertions(+), 4 deletions(-)
---
diff --git a/src/client/conversation-viewer/conversation-listbox.vala
b/src/client/conversation-viewer/conversation-listbox.vala
index ff01094..2a1e2bb 100644
--- a/src/client/conversation-viewer/conversation-listbox.vala
+++ b/src/client/conversation-viewer/conversation-listbox.vala
@@ -718,12 +718,16 @@ public class ConversationListBox : Gtk.ListBox {
private void on_row_activated(Gtk.ListBoxRow widget) {
EmailRow row = (EmailRow) widget;
- if (!row.is_last) {
- if (row.is_expanded && row.view.composer == null) {
+ // Allow non-last rows to be expanded/collapsed, but also let
+ // the last row to be expanded since appended sent emails will
+ // be appended last. Finally, don't let rows with active
+ // composers be collapsed.
+ if (row.is_expanded) {
+ if (!row.is_last && row.view.composer == null) {
row.collapse();
- } else {
- row.expand();
}
+ } else {
+ row.expand();
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]