From d843df76d2fbf6c4dcdcb044d91fc3b94e0341a7 Mon Sep 17 00:00:00 2001 From: slotThe Date: Thu, 2 Jan 2020 22:07:47 +0100 Subject: Add 'WeatherOpts' type and first option to weather plugin The first option applied here is a default value for a field that's not always reported to be there, namely the 'weather' field. It now defaults to saying "normal" instead of displaying an empty string. --- src/Xmobar/Plugins/Monitors.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/Xmobar/Plugins/Monitors.hs') diff --git a/src/Xmobar/Plugins/Monitors.hs b/src/Xmobar/Plugins/Monitors.hs index cac4635..f79b406 100644 --- a/src/Xmobar/Plugins/Monitors.hs +++ b/src/Xmobar/Plugins/Monitors.hs @@ -164,8 +164,8 @@ instance Exec Monitors where start (TopProc a r) = startTop a r start (TopMem a r) = runM a topMemConfig runTopMem r #ifdef WEATHER - start (Weather s a r) = runMD (a ++ [s]) weatherConfig runWeather r weatherReady - start (WeatherX s c a r) = runMD (a ++ [s]) weatherConfig (runWeather' c) r weatherReady + start (Weather s a r) = runMD (s : a) weatherConfig runWeather r weatherReady + start (WeatherX s c a r) = runMD (s : a) weatherConfig (runWeather' c) r weatherReady #endif start (Thermal z a r) = runM (a ++ [z]) thermalConfig runThermal r start (ThermalZone z a r) = -- cgit v1.2.3