2009-02-22 22:28:09 +00:00
|
|
|
//
|
|
|
|
// PositionSlider.m
|
|
|
|
// Cog
|
|
|
|
//
|
|
|
|
// Created by Vincent Spader on 2/22/09.
|
|
|
|
// Copyright 2009 __MyCompanyName__. All rights reserved.
|
|
|
|
//
|
|
|
|
|
|
|
|
#import "PositionSlider.h"
|
|
|
|
#import "TimeField.h"
|
|
|
|
|
|
|
|
@implementation PositionSlider
|
|
|
|
|
|
|
|
- (void)setDoubleValue:(double)value
|
|
|
|
{
|
2021-01-25 20:17:57 +00:00
|
|
|
self.positionTextField.currentTime = (long)value;
|
|
|
|
|
|
|
|
[super setDoubleValue:value];
|
2009-02-22 22:28:09 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
- (void)setMaxValue:(double)value
|
|
|
|
{
|
2021-01-25 20:17:57 +00:00
|
|
|
self.positionTextField.duration = (long)value;
|
|
|
|
|
|
|
|
[super setMaxValue:value];
|
2009-02-22 22:28:09 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
- (void)mouseDragged:(NSEvent *)theEvent
|
|
|
|
{
|
2021-01-25 20:17:57 +00:00
|
|
|
self.positionTextField.currentTime = (long)[self doubleValue];
|
|
|
|
|
|
|
|
[super mouseDragged:theEvent];
|
2009-02-22 22:28:09 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
@end
|