diff options
author | Gregor Kleen <gkleen@yggdrasil.li> | 2016-02-25 02:16:07 +0000 |
---|---|---|
committer | Gregor Kleen <gkleen@yggdrasil.li> | 2016-02-25 02:16:07 +0000 |
commit | f4c9fe7ceb7ad29e9bf0b875ec75e00487f90eeb (patch) | |
tree | a381ecde8b2cff1219cf18111770602ef2c3f1a4 | |
parent | ed1df9173bdddbcaa677f8cc05134bca5d117a35 (diff) | |
download | thermoprint-f4c9fe7ceb7ad29e9bf0b875ec75e00487f90eeb.tar thermoprint-f4c9fe7ceb7ad29e9bf0b875ec75e00487f90eeb.tar.gz thermoprint-f4c9fe7ceb7ad29e9bf0b875ec75e00487f90eeb.tar.bz2 thermoprint-f4c9fe7ceb7ad29e9bf0b875ec75e00487f90eeb.tar.xz thermoprint-f4c9fe7ceb7ad29e9bf0b875ec75e00487f90eeb.zip |
switch to error tab when emitting one
-rw-r--r-- | webgui/src/Main.hs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/webgui/src/Main.hs b/webgui/src/Main.hs index 4f2c83c..141b0ea 100644 --- a/webgui/src/Main.hs +++ b/webgui/src/Main.hs | |||
@@ -115,6 +115,7 @@ setup Config{..} window (split -> (socketErr, dataUpdate)) = void $ do | |||
115 | errorsTab = maybe (fatal "Could not make nonfatal errors visible") return =<< getElementById window "errors-tab" | 115 | errorsTab = maybe (fatal "Could not make nonfatal errors visible") return =<< getElementById window "errors-tab" |
116 | errors #+ [UI.li # set TP.text str] | 116 | errors #+ [UI.li # set TP.text str] |
117 | errorsTab # set style [("display", "inline-block")] | 117 | errorsTab # set style [("display", "inline-block")] |
118 | switchTab "errors" | ||
118 | fatal :: String -> UI a | 119 | fatal :: String -> UI a |
119 | fatal str = do | 120 | fatal str = do |
120 | (getBody window #) . set children =<< sequence [UI.p # set TP.text str # set UI.class_ "fatal"] | 121 | (getBody window #) . set children =<< sequence [UI.p # set TP.text str # set UI.class_ "fatal"] |