From 7350a36597242eeca4c631d10088d22c9487deea Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Tue, 14 Mar 2017 13:10:15 -0700 Subject: [PATCH] [taffybar] Small fixes for ToggleMonitor --- dotfiles/config/taffybar/lib/ToggleMonitor.hs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/dotfiles/config/taffybar/lib/ToggleMonitor.hs b/dotfiles/config/taffybar/lib/ToggleMonitor.hs index 938e06d9..c526f192 100644 --- a/dotfiles/config/taffybar/lib/ToggleMonitor.hs +++ b/dotfiles/config/taffybar/lib/ToggleMonitor.hs @@ -11,10 +11,7 @@ import Control.Monad.Trans import Control.Monad.Trans.Maybe import qualified Data.Map as M import Data.Maybe -import Data.String -import qualified Data.Text.Internal.Lazy as T import qualified Graphics.UI.Gtk as Gtk -import Graphics.UI.Gtk.Gdk.DrawWindow import Graphics.UI.Gtk.Gdk.Screen import System.Taffybar import Text.Read hiding (get, lift) @@ -42,8 +39,7 @@ handleToggleRequests enabledVar refreshTaffyWindows = do refreshTaffyWindows toggleTaffy = do num <- liftIO $ runMaybeT getActiveScreenNumber - let monitorNumber = fromMaybe 0 num - liftIO $ toggleTaffyOnMon not $ monitorNumber + liftIO $ toggleTaffyOnMon not $ fromMaybe 0 num runScotty = scotty 3000 $ do get "/toggle/:monNum" $ do