+- (IBAction)goToSpecificTime:(id)sender
+{
+ if( sender == o_specificTime_cancel_btn )
+ {
+ [NSApp endSheet: o_specificTime_win];
+ [o_specificTime_win close];
+ }
+ else if( sender == o_specificTime_ok_btn )
+ {
+ input_thread_t * p_input = (input_thread_t *)vlc_object_find( VLCIntf, \
+ VLC_OBJECT_INPUT, FIND_ANYWHERE );
+ if( p_input )
+ {
+ unsigned int timeInSec = 0;
+ NSString * fieldContent = [o_specificTime_enter_fld stringValue];
+ if( [[fieldContent componentsSeparatedByString: @":"] count] > 1 &&
+ [[fieldContent componentsSeparatedByString: @":"] count] <= 3 )
+ {
+ NSArray * ourTempArray = \
+ [fieldContent componentsSeparatedByString: @":"];
+
+ if( [[fieldContent componentsSeparatedByString: @":"] count] == 3 )
+ {
+ timeInSec += ([[ourTempArray objectAtIndex: 0] intValue] * 3600); //h
+ timeInSec += ([[ourTempArray objectAtIndex: 1] intValue] * 60); //m
+ timeInSec += [[ourTempArray objectAtIndex: 2] intValue]; //s
+ }
+ else
+ {
+ timeInSec += ([[ourTempArray objectAtIndex: 0] intValue] * 60); //m
+ timeInSec += [[ourTempArray objectAtIndex: 1] intValue]; //s
+ }
+ }
+ else
+ timeInSec = [fieldContent intValue];
+
+ input_Control( p_input, INPUT_SET_TIME, (int64_t)(timeInSec * 1000000));
+ vlc_object_release( p_input );
+ }
+
+ [NSApp endSheet: o_specificTime_win];
+ [o_specificTime_win close];
+ }
+ else
+ {
+ input_thread_t * p_input = (input_thread_t *)vlc_object_find( VLCIntf, \
+ VLC_OBJECT_INPUT, FIND_ANYWHERE );
+ if( p_input )
+ {
+ /* we can obviously only do that if an input is available */
+ vlc_value_t pos, length;
+ var_Get( p_input, "time", &pos );
+ [o_specificTime_enter_fld setIntValue: (pos.i_time / 1000000)];
+ var_Get( p_input, "length", &length );
+ [o_specificTime_stepper setMaxValue: (length.i_time / 1000000)];
+
+ [NSApp beginSheet: o_specificTime_win modalForWindow: \
+ [NSApp mainWindow] modalDelegate: self didEndSelector: nil \
+ contextInfo: nil];
+ [o_specificTime_win makeKeyWindow];
+ vlc_object_release( p_input );
+ }
+ }
+}
+
+- (id)getFSPanel
+{
+ if( o_fs_panel )
+ return o_fs_panel;
+ else
+ {
+ msg_Err( VLCIntf, "FSPanel is nil" );
+ return NULL;
+ }
+}
+