Mailbox helper functions. More...
#include "config.h"#include <string.h>#include <sys/stat.h>#include <sys/types.h>#include <utime.h>#include "mutt/lib.h"#include "config/lib.h"#include "core/lib.h"#include "mutt_mailbox.h"#include "postpone/lib.h"#include "muttlib.h"#include "mx.h"
Include dependency graph for mutt_mailbox.c:Go to the source code of this file.
Functions | |
| static bool | is_same_mailbox (struct Mailbox *m1, struct Mailbox *m2, struct stat *st1, struct stat *st2) |
| Compare two Mailboxes to see if they're equal. | |
| static void | mailbox_check (struct Mailbox *m_cur, struct Mailbox *m_check, struct stat *st_cur, CheckStatsFlags flags) |
| Check a mailbox for new mail. | |
| int | mutt_mailbox_check (struct Mailbox *m_cur, CheckStatsFlags flags) |
| Check all all Mailboxes for new mail. | |
| bool | mutt_mailbox_notify (struct Mailbox *m_cur) |
| Notify the user if there's new mail. | |
| bool | mutt_mailbox_list (void) |
| Show a message with the list of mailboxes with new mail. | |
| void | mutt_mailbox_set_notified (struct Mailbox *m) |
| Note when the user was last notified of new mail. | |
| static struct Mailbox * | find_next_mailbox (struct Buffer *s, bool find_new) |
| Find the next mailbox with new or unread mail. | |
| struct Mailbox * | mutt_mailbox_next (struct Mailbox *m_cur, struct Buffer *s) |
| Incoming folders completion routine. | |
| struct Mailbox * | mutt_mailbox_next_unread (struct Mailbox *m_cur, struct Buffer *s) |
| Find next mailbox with unread mail. | |
| void | mailbox_restore_timestamp (const char *path, struct stat *st) |
| Restore the timestamp of a mailbox. | |
Variables | |
| static time_t | MailboxTime = 0 |
| last time we started checking for mail | |
| static time_t | MailboxStatsTime = 0 |
| last time we check performed mail_check_stats | |
| static short | MailboxCount = 0 |
| how many boxes with new mail | |
| static short | MailboxNotify = 0 |
Mailbox helper functions.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Definition in file mutt_mailbox.c.
|
static |
Compare two Mailboxes to see if they're equal.
| m1 | First mailbox |
| m2 | Second mailbox |
| st1 | stat() info for first mailbox |
| st2 | stat() info for second mailbox |
| true | Mailboxes are the same |
| false | Mailboxes are different |
Definition at line 58 of file mutt_mailbox.c.
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Check a mailbox for new mail.
| m_cur | Current Mailbox |
| m_check | Mailbox to check |
| st_cur | stat() info for the current Mailbox |
| flags | Flags, e.g. MUTT_MAILBOX_CHECK_POSTPONED |
Definition at line 83 of file mutt_mailbox.c.
Here is the call graph for this function:
Here is the caller graph for this function:| int mutt_mailbox_check | ( | struct Mailbox * | m_cur, |
| CheckStatsFlags | flags ) |
Check all all Mailboxes for new mail.
| m_cur | Current Mailbox |
| flags | Flags, e.g. MUTT_MAILBOX_CHECK_STATS |
| num | Number of mailboxes with new mail |
Check all all Mailboxes for new mail and total/new/flagged messages
Definition at line 169 of file mutt_mailbox.c.
Here is the call graph for this function:
Here is the caller graph for this function:| bool mutt_mailbox_notify | ( | struct Mailbox * | m_cur | ) |
Notify the user if there's new mail.
| m_cur | Current Mailbox |
| true | There is new mail |
Definition at line 235 of file mutt_mailbox.c.
Here is the call graph for this function:
Here is the caller graph for this function:| bool mutt_mailbox_list | ( | void | ) |
Show a message with the list of mailboxes with new mail.
| true | There is new mail |
Definition at line 248 of file mutt_mailbox.c.
Here is the call graph for this function:
Here is the caller graph for this function:| void mutt_mailbox_set_notified | ( | struct Mailbox * | m | ) |
Note when the user was last notified of new mail.
| m | Mailbox |
Definition at line 304 of file mutt_mailbox.c.
Here is the call graph for this function:
Here is the caller graph for this function:Find the next mailbox with new or unread mail.
| s | Buffer containing name of current mailbox |
| find_new | Boolean controlling new or unread check |
| ptr | Mailbox |
Given a folder name, find the next incoming folder with new or unread mail. The Mailbox will be returned and a pretty version of the path put into s.
Definition at line 322 of file mutt_mailbox.c.
Here is the call graph for this function:
Here is the caller graph for this function:Incoming folders completion routine.
| ptr | Mailbox |
Given a folder name, find the next incoming folder with new mail. The Mailbox will be returned and a pretty version of the path put into s.
Definition at line 361 of file mutt_mailbox.c.
Here is the call graph for this function:
Here is the caller graph for this function:Find next mailbox with unread mail.
| ptr | Mailbox |
Given a folder name, find the next mailbox with unread mail. The Mailbox will be returned and a pretty version of the path put into s.
Definition at line 387 of file mutt_mailbox.c.
Here is the call graph for this function:
Here is the caller graph for this function:| void mailbox_restore_timestamp | ( | const char * | path, |
| struct stat * | st ) |
Restore the timestamp of a mailbox.
| path | Path to the mailbox |
| st | Timestamp info from stat() |
Fix up the atime and mtime after mbox/mmdf mailbox was modified according to stat() info taken before a modification.
Definition at line 407 of file mutt_mailbox.c.
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
last time we started checking for mail
Definition at line 44 of file mutt_mailbox.c.
|
static |
last time we check performed mail_check_stats
Definition at line 45 of file mutt_mailbox.c.
|
static |
how many boxes with new mail
Definition at line 46 of file mutt_mailbox.c.
|
static |
Definition at line 47 of file mutt_mailbox.c.