<commit_before>var pendingPlayerActions = {}

    function setPlaylistAndSeek(playerName, playlist, offset) {
	// Example: setPlaylistAndSeek("ROV", 1, 120)
	var p = jwplayer(playerName);
	var actionObj = new Object();
	actionObj.action = p.seek;
	actionObj.arg = offset;
	pendingPlayerActions[playerName] = [actionObj];
	p.playlistItem(playlist);
    }

/**
 * ensures that only one onTime event is enabled
 */
function onTimeController(thisObj) {
    if (!xgds_video.playFlag) {
        return;
    }

    var switchPlayer = false;            
    if (thisObj.id == xgds_video.onTimePlayer) {
        var state = jwplayer(thisObj.id).getState();
        if (state != 'PLAYING') { 
            switchPlayer = true;
        }<commit_msg>Updated seek function in recordedVideoPlayer.js so it will work in both HTML5 and flash players.<commit_after>var pendingPlayerActions = {}

    function setPlaylistAndSeek(playerName, playlist, offset) {
	// Example: setPlaylistAndSeek("ROV", 1, 120)
	var p = jwplayer(playerName);
	var actionObj = new Object();
	actionObj.action = p.seek;
	actionObj.arg = offset;
	// Calling immediately seems to work better for HTML5,
	// Queuing in list for handling in onPlay(), below, works better for Flash. Yuck!
	if (p.getRenderingMode() == "html5") {
	    p.playlistItem(playlist).seek(offset);
	}
	else {
	    pendingPlayerActions[playerName] = [actionObj];
	    p.playlistItem(playlist);
	}
    }

/**
 * ensures that only one onTime event is enabled
 */
function onTimeController(thisObj) {
    if (!xgds_video.playFlag) {
        return;
    }

    var switchPlayer = false;            
    if (thisObj.id == xgds_video.onTimePlayer) {
        var state = jwplayer(thisObj.id).getState();
        if (state != 'PLAYING') { 
            switchPlayer = true;
        }
{'fraction_non_alphanumeric': 0.11709211986681466, 'fraction_numerical': 0.006104328523862375, 'mean_word_length': 3.125858123569794, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6537061', 'n_tokens_mistral': 585, 'n_tokens_neox': 567, 'n_words': 142}