function update_input_disc()
{
    var mrl     = document.getElementById( 'input_mrl' );
    var type    = radio_value( "input_disc_type" );
    var device  = value( "input_disc_dev" );

    var title   = check_and_replace_int( 'input_disc_title', 0 );
    var chapter = check_and_replace_int( 'input_disc_chapter', 0 );
    var subs    = check_and_replace_int( 'input_disc_subtrack', '' );
    var audio   = check_and_replace_int( 'input_disc_audiotrack', 0 );

    mrl.value = "";

    if( type == "dvd" )
    {
        mrl.value += "dvd://";
    }
    else if( type == "dvdsimple" )
    {
        mrl.value += "dvdsimple://";
    }
    else if( type == "vcd" )
    {
        mrl.value += "vcd://";
    }
    else if( type == "cdda" )
    {
        mrl.value += "cdda://";
    }

    mrl.value += device;

    if( title )
    {
        mrl.value += "@"+title;
        if( chapter && type != "cdda" )
            mrl.value += ":"+chapter;
    }

    remove_input_options( ':sub-track' );
    remove_input_options( ':audio-track' );

    if( type != "cdda" )
    {
        if( subs != '' )
            add_input_option( ":sub-track="+subs );
        if( audio != '' )
            add_input_option( ":audio-track="+audio );
    }

}
/* update the input MRL using data from the input disc helper */
update the input MRL using data from the input disc helper
update the input MRL using data from the input disc helper
function update_input_disc()
{
    var mrl     = document.getElementById( 'input_mrl' );
    var type    = radio_value( "input_disc_type" );
    var device  = value( "input_disc_dev" );
    var title   = check_and_replace_int( 'input_disc_title', 0 );
    var chapter = check_and_replace_int( 'input_disc_chapter', 0 );
    var subs    = check_and_replace_int( 'input_disc_subtrack', '' );
    var audio   = check_and_replace_int( 'input_disc_audiotrack', 0 );
    mrl.value = "";
    if( type == "dvd" )
    {
        mrl.value += "dvd://";
    }
    else if( type == "dvdsimple" )
    {
        mrl.value += "dvdsimple://";
    }
    else if( type == "vcd" )
    {
        mrl.value += "vcd://";
    }
    else if( type == "cdda" )
    {
        mrl.value += "cdda://";
    }
    mrl.value += device;
    if( title )
    {
        mrl.value += "@"+title;
        if( chapter && type != "cdda" )
            mrl.value += ":"+chapter;
    }
    remove_input_options( ':sub-track' );
    remove_input_options( ':audio-track' );
    if( type != "cdda" )
    {
        if( subs != '' )
            add_input_option( ":sub-track="+subs );
        if( audio != '' )
            add_input_option( ":audio-track="+audio );
    }
}
function update_input_disc ( ) { var mrl = document . getElementById ( 'input_mrl' ) ; var type = radio_value ( "input_disc_type" ) ; var device = value ( "input_disc_dev" ) ; var title = check_and_replace_int ( 'input_disc_title' , 0 ) ; var chapter = check_and_replace_int ( 'input_disc_chapter' , 0 ) ; var subs = check_and_replace_int ( 'input_disc_subtrack' , '' ) ; var audio = check_and_replace_int ( 'input_disc_audiotrack' , 0 ) ; mrl . value = "" ; if ( type == "dvd" ) { mrl . value += "dvd://" ; } else if ( type == "dvdsimple" ) { mrl . value += "dvdsimple://" ; } else if ( type == "vcd" ) { mrl . value += "vcd://" ; } else if ( type == "cdda" ) { mrl . value += "cdda://" ; } mrl . value += device ; if ( title ) { mrl . value += "@" + title ; if ( chapter && type != "cdda" ) mrl . value += ":" + chapter ; } remove_input_options ( ':sub-track' ) ; remove_input_options ( ':audio-track' ) ; if ( type != "cdda" ) { if ( subs != '' ) add_input_option ( ":sub-track=" + subs ) ; if ( audio != '' ) add_input_option ( ":audio-track=" + audio ) ; } }
update the input MRL using data from the input disc helper
update the input MRL using data from the input disc helper