Bug 3954 - Knob does not work with INPUT.Time
: Knob does not work with INPUT.Time
Status: RESOLVED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Player UI
: 6.5b1
: All All
: P2 normal (vote)
: ---
Assigned To: Chris Owens
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-08-17 11:03 UTC by Dan Sully
Modified: 2009-09-08 09:25 UTC (History)
1 user (show)

See Also:
Category: ---


Attachments
reset knob params for each cursor position (2.23 KB, patch)
2006-08-17 22:42 UTC, KDF
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dan Sully 2006-08-17 11:03:56 UTC
Per the Todo item in Slim/Buttons/Input/Time.pm

# todo: make work with knob!
Comment 1 KDF 2006-08-17 13:57:26 UTC
try:
	,'knob' => sub {
			my ($client,$funct,$functarg) = @_;
			my @timedigits = timeDigits($client,$client->param('valueRef'));
			scroll($client, $client->knobPos() - $timedigits[$client->param('cursorPos')]);
		}

can't test myself as I am not near the hardware and softsqueeze only fakes knob with up/down
Comment 2 Dan Sully 2006-08-17 14:02:58 UTC
Almost, but not quite. The knob only goes 0 -> 5 for the minutes, and 9, 1, 2, 3, 4, 5 for hour when the hour is not double digits.
Comment 3 Dan Sully 2006-08-17 14:03:22 UTC
Kevin, added comment before I added you to Cc
Comment 4 KDF 2006-08-17 14:26:27 UTC
ok thanks.  I'll do some testing when I can get to hardware. Lots of abstraction in time handling, so may have to come up with a way to grab range limits for each cursorpos as well.
Comment 5 KDF 2006-08-17 22:42:30 UTC
Created attachment 1441 [details]
reset knob params for each cursor position

the trick here is that the list size changes for each digit, and depends on the current state of the digits.  the prepKnob checks the state and updates the knob params to suit. seems to work for me, but it may need a bit more hardening to handle all cases.
Comment 6 Dan Sully 2006-08-18 17:33:56 UTC
This looks good to me. Commited as change 9049

Thanks kdf