clamp markedTime to stay visible in TimeScale
This commit is contained in:
parent
bd8b982238
commit
c81b37a65e
@ -247,9 +247,15 @@ updateModel msg model =
|
||||
_ -> model
|
||||
|
||||
TimeScale factor ->
|
||||
{ model |
|
||||
startTime = model.startTime + factor / 2
|
||||
, duration = model.duration - factor
|
||||
let startTime = model.startTime + factor / 2
|
||||
duration = model.duration - factor
|
||||
in { model |
|
||||
startTime = startTime
|
||||
, duration = duration
|
||||
, markedTime =
|
||||
let (s, d) = model.markedTime
|
||||
in ( max s startTime
|
||||
, (min (s + d) (startTime + duration)) - s)
|
||||
}
|
||||
|
||||
Loaded result ->
|
||||
|
Loading…
Reference in New Issue
Block a user