aboutsummaryrefslogtreecommitdiff
path: root/Assistant/Types
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2013-11-23 00:54:08 -0400
committerGravatar Joey Hess <joey@kitenet.net>2013-11-23 00:54:08 -0400
commitec8edd25c6917ad10dc129bbaebffdd50afe0d51 (patch)
treedb756010017cc771c0045db8dab988cef49b6295 /Assistant/Types
parent6b770f7797588e687ef5b4e567d86a0fd08809ea (diff)
restart on upgrade is working, including automatic restart
Made alerts be able to have multiple buttons, so the alerts about upgrading can have a button that enables automatic upgrades. Implemented automatic upgrading when the program file has changed. Note that when an automatic upgrade happens, the webapp displays an alert about it for a few minutes, and then closes. This still needs work.
Diffstat (limited to 'Assistant/Types')
-rw-r--r--Assistant/Types/Alert.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/Assistant/Types/Alert.hs b/Assistant/Types/Alert.hs
index c601c60db..4079802ec 100644
--- a/Assistant/Types/Alert.hs
+++ b/Assistant/Types/Alert.hs
@@ -51,7 +51,7 @@ data Alert = Alert
, alertIcon :: Maybe AlertIcon
, alertCombiner :: Maybe AlertCombiner
, alertName :: Maybe AlertName
- , alertButton :: Maybe AlertButton
+ , alertButtons :: [AlertButton]
}
data AlertIcon = ActivityIcon | SyncIcon | SuccessIcon | ErrorIcon | InfoIcon | UpgradeIcon | TheCloud
@@ -75,4 +75,5 @@ data AlertButton = AlertButton
{ buttonLabel :: Text
, buttonUrl :: Text
, buttonAction :: Maybe (AlertId -> IO ())
+ , buttonPrimary :: Bool
}