gtk-sni-tray 0.1.7.0 → 0.1.8.0
raw patch · 3 files changed
+24/−16 lines, 3 files
Files
- app/Main.hs +2/−4
- gtk-sni-tray.cabal +1/−1
- src/StatusNotifier/Tray.hs +21/−11
app/Main.hs view
@@ -205,11 +205,9 @@ BottomPos -> Gtk.OrientationHorizontal _ -> Gtk.OrientationVertical tray <-- buildTray+ buildTray host client TrayParams- { trayClient = client- , trayOrientation = orientation- , trayHost = host+ { trayOrientation = orientation , trayImageSize = Expand , trayIconExpand = expand , trayAlignment = align
gtk-sni-tray.cabal view
@@ -5,7 +5,7 @@ -- see: https://github.com/sol/hpack name: gtk-sni-tray-version: 0.1.7.0+version: 0.1.8.0 synopsis: A standalone StatusNotifierItem/AppIndicator tray description: Please see the README on Github at <https://github.com/IvanMalison/gtk-sni-tray#readme> category: System
src/StatusNotifier/Tray.hs view
@@ -18,6 +18,7 @@ import qualified Data.Map.Strict as Map import Data.Maybe import Data.Ord+import Data.Ratio import qualified Data.Text as T import qualified GI.DbusmenuGtk3.Objects.Menu as DM import qualified GI.GLib as GLib@@ -168,9 +169,7 @@ data TrayClickAction = Activate | SecondaryActivate | PopupMenu data TrayParams = TrayParams- { trayHost :: Host- , trayClient :: Client- , trayOrientation :: Gtk.Orientation+ { trayOrientation :: Gtk.Orientation , trayImageSize :: TrayImageSize , trayIconExpand :: Bool , trayAlignment :: StrutAlignment@@ -180,14 +179,25 @@ , trayRightClickAction :: TrayClickAction } -buildTray :: TrayParams -> IO Gtk.Box-buildTray TrayParams { trayHost = Host- { itemInfoMap = getInfoMap- , addUpdateHandler = addUHandler- , removeUpdateHandler = removeUHandler- }- , trayClient = client- , trayOrientation = orientation+defaultTrayParams = TrayParams+ { trayOrientation = Gtk.OrientationHorizontal+ , trayImageSize = Expand+ , trayIconExpand = False+ , trayAlignment = End+ , trayOverlayScale = 3 % 5+ , trayLeftClickAction = Activate+ , trayMiddleClickAction = SecondaryActivate+ , trayRightClickAction = PopupMenu+ }++buildTray :: Host -> Client -> TrayParams -> IO Gtk.Box+buildTray Host+ { itemInfoMap = getInfoMap+ , addUpdateHandler = addUHandler+ , removeUpdateHandler = removeUHandler+ }+ client+ TrayParams { trayOrientation = orientation , trayImageSize = imageSize , trayIconExpand = shouldExpand , trayAlignment = alignment