summaryrefslogtreecommitdiff
path: root/Assistant/Alert.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-08-27 13:52:48 -0400
committerGravatar Joey Hess <joey@kitenet.net>2012-08-27 13:52:48 -0400
commit11c1f32c51707e838dd154afe3d2a1d25e9d18ef (patch)
tree5aff15be697a85622dcfd98cad07b7fcb975fd8a /Assistant/Alert.hs
parent2433f6ca5a602f55986bcd85c20034c88cc44a3b (diff)
improve display of failed transfer alert
Diffstat (limited to 'Assistant/Alert.hs')
-rw-r--r--Assistant/Alert.hs7
1 files changed, 5 insertions, 2 deletions
diff --git a/Assistant/Alert.hs b/Assistant/Alert.hs
index c66621836..4c4906ef5 100644
--- a/Assistant/Alert.hs
+++ b/Assistant/Alert.hs
@@ -260,10 +260,13 @@ addFileAlert :: FilePath -> Alert
addFileAlert = fileAlert (Tensed "Adding" "Added")
{- This is only used as a success alert after a transfer, not during it. -}
-transferFileAlert :: Direction -> FilePath -> Alert
-transferFileAlert direction
+transferFileAlert :: Direction -> Bool -> FilePath -> Alert
+transferFileAlert direction True
| direction == Upload = fileAlert "Uploaded"
| otherwise = fileAlert "Downloaded"
+transferFileAlert direction False
+ | direction == Upload = fileAlert "Upload failed"
+ | otherwise = fileAlert "Download failed"
dataCombiner :: ([TenseChunk] -> [TenseChunk] -> [TenseChunk]) -> AlertCombiner
dataCombiner combiner new old