Update changes in menu values
This commit is contained in:
@@ -7,11 +7,9 @@ import LensHelp
|
||||
setShownSelectionItems :: SelectionList -> SelectionList
|
||||
setShownSelectionItems sl = case sl ^? slSizeRestriction of
|
||||
Just (SelectionSizeRestriction maxlines _ botit _)
|
||||
| length allitems <= maxlines -> sl & slShownItems .~ allitems
|
||||
-- | offset > length allitems + 3 - maxlines -> sl
|
||||
| otherwise ->
|
||||
| length allitems > maxlines ->
|
||||
sl & slShownItems .~ take (maxlines - 2) (drop offset allitems) -- ++ repeat dummyitem))
|
||||
++ [(botit,ScrollDownSelectionItem)]
|
||||
++ [(botit,ScrollSelectionItem)]
|
||||
_ -> sl & slShownItems .~ allitems
|
||||
where
|
||||
-- dummyitem = (SelectionItem [] 1 False 0 white 0, DummySelectionItem)
|
||||
|
||||
Reference in New Issue
Block a user