summaryrefslogtreecommitdiff
path: root/Bustle.hs
diff options
context:
space:
mode:
authorWill Thompson <will@willthompson.co.uk>2011-08-04 09:59:44 +0100
committerWill Thompson <will@willthompson.co.uk>2011-08-04 09:59:44 +0100
commitbb0efd0a6461c68a6bb3c975e84c0a432e65b928 (patch)
treecdc2abd1f57b17eebae7e61915089d79f3c56a63 /Bustle.hs
parenta76f3ece89e1af86d9491de24ae91ff2dd2d04f6 (diff)
filter dialog: show current ticky state
Diffstat (limited to 'Bustle.hs')
-rw-r--r--Bustle.hs10
1 files changed, 7 insertions, 3 deletions
diff --git a/Bustle.hs b/Bustle.hs
index 9a2e43c..5f2694d 100644
--- a/Bustle.hs
+++ b/Bustle.hs
@@ -398,11 +398,13 @@ updateDisplayedLog wi rr shapesRef widthRef regionSelectionRef = do
writeIORef shapesRef shapes
writeIORef widthRef width
+ -- FIXME: try to preserve the currently-selected message?
modifyRegionSelection regionSelectionRef wi $
const (regionSelectionNew (rrRegions rr))
layoutSetSize layout (floor width) (floor height)
+ -- FIXME: only do this the first time maybe?
-- Shift to make the timestamp column visible
hadj <- layoutGetHAdjustment layout
(windowWidth, _) <- windowGetSize (wiWindow wi)
@@ -447,6 +449,7 @@ displayLog wi@(WindowInfo { wiWindow = window
shapesRef <- newIORef []
widthRef <- newIORef 0
regionSelectionRef <- newIORef $ regionSelectionNew []
+ hiddenRef <- newIORef Set.empty
updateDisplayedLog wi rr shapesRef widthRef regionSelectionRef
@@ -507,9 +510,10 @@ displayLog wi@(WindowInfo { wiWindow = window
widgetSetSensitivity filterNames True
onActivateLeaf filterNames $ do
- -- FIXME: tell it which ones are currently visible
- ret <- runFilterDialog window (sessionParticipants $ rrApplications rr)
- let rr' = processWithFilters (sessionMessages, ret) (systemMessages, Set.empty)
+ hidden <- readIORef hiddenRef
+ hidden' <- runFilterDialog window (sessionParticipants $ rrApplications rr) hidden
+ writeIORef hiddenRef hidden'
+ let rr' = processWithFilters (sessionMessages, hidden') (systemMessages, Set.empty)
updateDisplayedLog wi rr' shapesRef widthRef regionSelectionRef