From febcd4b225f160a4fcbff407df197b7d931eaf2a Mon Sep 17 00:00:00 2001
From: Thomas Bruederli <thomas@roundcube.net>
Date: Wed, 22 Jan 2014 03:29:35 -0500
Subject: [PATCH] Improve wording: don't pretend that mailbox is empty if search/filter doesn't find any messages

---
 program/localization/en_US/messages.inc |    5 +++--
 program/steps/mail/func.inc             |    2 +-
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/program/localization/en_US/messages.inc b/program/localization/en_US/messages.inc
index a36d9ab..ce87228 100644
--- a/program/localization/en_US/messages.inc
+++ b/program/localization/en_US/messages.inc
@@ -5,7 +5,7 @@
  | localization/<lang>/messages.inc                                      |
  |                                                                       |
  | Localization file of the Roundcube Webmail client                     |
- | Copyright (C) 2005-2013, The Roundcube Dev Team                       |
+ | Copyright (C) 2005-2014, The Roundcube Dev Team                       |
  |                                                                       |
  | Licensed under the GNU General Public License version 3 or            |
  | any later version with exceptions for skins & plugins.                |
@@ -34,7 +34,8 @@
 $messages['invalidhost'] = 'Invalid server name.';
 $messages['nomessagesfound'] = 'No messages found in this mailbox.';
 $messages['loggedout'] = 'You have successfully terminated the session. Good bye!';
-$messages['mailboxempty'] = 'Mailbox is empty.';
+$messages['mailboxempty'] = 'Mailbox is empty';
+$messages['nomessages'] = 'No messages';
 $messages['refreshing'] = 'Refreshing...';
 $messages['loading'] = 'Loading...';
 $messages['uploading'] = 'Uploading file...';
diff --git a/program/steps/mail/func.inc b/program/steps/mail/func.inc
index 0211fab..e1cdbc2 100644
--- a/program/steps/mail/func.inc
+++ b/program/steps/mail/func.inc
@@ -583,7 +583,7 @@
         $max = $RCMAIL->storage->count(NULL, $RCMAIL->storage->get_threading() ? 'THREADS' : 'ALL');
 
     if ($max == 0)
-        $out = $RCMAIL->gettext('mailboxempty');
+        $out = $RCMAIL->storage->get_search_set() ? $RCMAIL->gettext('nomessages') : $RCMAIL->gettext('mailboxempty');
     else
         $out = $RCMAIL->gettext(array('name' => $RCMAIL->storage->get_threading() ? 'threadsfromto' : 'messagesfromto',
             'vars' => array('from'  => $start_msg,

--
Gitblit v1.9.1