[Xfce4-commits] <postler:master> Show To instead of From in Sent, Outbox and Drafts
Christian Dywan
noreply at xfce.org
Fri Jun 4 23:28:01 CEST 2010
Updating branch refs/heads/master
to 3f39b90e612ed3c2ef9c3298dc8b4aeea899a5e9 (commit)
from 50922e9a1df6942272796427efb32e3ea57f655a (commit)
commit 3f39b90e612ed3c2ef9c3298dc8b4aeea899a5e9
Author: Christian Dywan <christian at twotoasts.de>
Date: Fri Jun 4 21:56:20 2010 +0200
Show To instead of From in Sent, Outbox and Drafts
postler/postler-messages.vala | 12 ++++++++++--
1 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/postler/postler-messages.vala b/postler/postler-messages.vala
index 7a685c5..3f97c50 100644
--- a/postler/postler-messages.vala
+++ b/postler/postler-messages.vala
@@ -252,6 +252,14 @@ public class Postler.Messages : Gtk.TreeView {
last_filter = filter;
var now = GLib.Date ();
now.set_time_val (GLib.TimeVal ());
+
+ string basename = Path.get_basename (location);
+ string to_or_from;
+ if (basename == "Sent" || basename == "Queue" || basename == "Drafts")
+ to_or_from = "to";
+ else
+ to_or_from = "from";
+
try {
string filter_header = "subject";
string real_filter = "";
@@ -298,7 +306,7 @@ public class Postler.Messages : Gtk.TreeView {
}
string subject = _("(No subject)");
- string from = _("(Uknown)");
+ string from = _("(Unknown)");
string date = _("(No date)");
time_t timestamp = 0;
var contents = folder_dir.resolve_relative_path (name);
@@ -320,7 +328,7 @@ public class Postler.Messages : Gtk.TreeView {
}
if (field == "subject")
subject = parts[1].strip ();
- else if (field == "from") {
+ else if (field == to_or_from) {
string from_charset = null;
from = parse_encoded (parts[1], out from_charset);
}
More information about the Xfce4-commits
mailing list