aboutsummaryrefslogtreecommitdiff
path: root/Handlers.hs
diff options
context:
space:
mode:
authorRaúl Benencia <rul@kalgan.cc>2013-08-30 09:49:01 -0300
committerRaúl Benencia <rul@kalgan.cc>2013-08-30 09:49:01 -0300
commit4010acf611b862be18e4a5fc8964f38c7767e5f2 (patch)
treef59ede857631c63a59d54fa7b2089ca795c0c8e5 /Handlers.hs
parent96be972c18b9ff389cf713d9cd025fb31bea503f (diff)
Removed the workaround, as Rfc2822 is now fixed
Diffstat (limited to 'Handlers.hs')
-rw-r--r--Handlers.hs14
1 files changed, 14 insertions, 0 deletions
diff --git a/Handlers.hs b/Handlers.hs
index 0fc1bd7..72f09dc 100644
--- a/Handlers.hs
+++ b/Handlers.hs
@@ -129,6 +129,17 @@ decSelectedRow MaildirMode = do
else
put $ decrementSelectedRow st
+decSelectedRow EmailMode = do
+ st <- get
+ let est = emailState st
+ let cur = scrollRowEm est
+ let scrRows = screenRows st
+ let totalRows = length $ emailLines est
+ let est' = est { scrollRowEm = (cur - 1) }
+
+ when ((totalRows - (scrRows + cur)) > 0) $
+ put $ st { emailState = est' }
+
decSelectedRow _ = (=<<) put $ get >>= \st -> return $ decrementSelectedRow st
{- Given a list, it returns the elements that will be in the next screen refresh
@@ -158,3 +169,6 @@ formatMaildirModeRows st = mapM formatRow where
pad = " "
numPads = (length $ filter (== '/') str) + (length $ filter (`elem` imapSep) str)
imapSep = ['.'] -- IMAP usually separates its directories with dots
+
+-- TODO: Improve this rancidness
+mailHeaderLength = 4 \ No newline at end of file
nihil fit ex nihilo