Cleanup
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
module Dodge.ListDisplayParams (
|
||||
invDisplayParams,
|
||||
invDP,
|
||||
invCursorParams,
|
||||
secondColumnParams,
|
||||
subInvX,
|
||||
@@ -29,11 +29,11 @@ defaultListDisplayParams =
|
||||
, _ldpWidth = UseItemWidth
|
||||
}
|
||||
|
||||
invDisplayParams :: World -> ListDisplayParams
|
||||
invDisplayParams w =
|
||||
invDP :: ListDisplayParams
|
||||
invDP =
|
||||
defaultListDisplayParams
|
||||
-- & ldpWidth .~ FixedSelectionWidth (determineInvSelCursorWidth w)
|
||||
& ldpPos . spPixelOff .~ V2 6 (-1)
|
||||
-- & ldpPos . spPixelOff .~ V2 6 (-1)
|
||||
& ldpPos . spPixelOff .~ V2 6 0
|
||||
|
||||
invCursorParams :: World -> CursorDisplay
|
||||
invCursorParams w = BoundaryCursor $ case w ^? hud . hudElement . subInventory of
|
||||
@@ -53,19 +53,6 @@ subInvX = 10 * fromIntegral topInvW + 70
|
||||
topInvW :: Int
|
||||
topInvW = 15
|
||||
|
||||
determineInvSelCursorWidth :: World -> Int
|
||||
determineInvSelCursorWidth w = case _rbOptions w of
|
||||
NoRightButtonOptions -> topInvW
|
||||
EquipOptions{}
|
||||
| ButtonRight `M.member` _mouseButtons (_input w)
|
||||
&& hasnosubinv ->
|
||||
47
|
||||
| otherwise -> topInvW
|
||||
where
|
||||
hasnosubinv = case w ^? hud . hudElement . subInventory of
|
||||
Just NoSubInventory{} -> True
|
||||
_ -> False
|
||||
|
||||
optionListDisplayParams :: ListDisplayParams
|
||||
optionListDisplayParams =
|
||||
defaultListDisplayParams
|
||||
|
||||
Reference in New Issue
Block a user