Index: branches/new-upload/phase3/js2/mwEmbed/example_usage/sample_themable_player.html |
— | — | @@ -13,13 +13,12 @@ |
14 | 14 | } else{ |
15 | 15 | loadExternalJs('http://jqueryui.com/themeroller/developertool/developertool.js.php'); |
16 | 16 | } |
17 | | - }).html('<span class="ui-icon ui-icon-newwin"/>Run Theme Roller'); |
| 17 | + }).html('<span class="ui-icon ui-icon-newwin"/>Run Theme Roller</span>'); |
18 | 18 | }); |
19 | 19 | </script> |
20 | 20 | <body bgcolor="#FFF"> |
21 | 21 | <h3> Sample Themed Player:</h3> |
22 | | -<a id="doThemeRoller" class="ui-icon_link ui-state-default ui-corner-all" href="#"> |
23 | | - <span class="ui-icon ui-icon-newwin"/>loading theme editor<blink>...</blink></a><p><p> |
| 22 | +<a id="doThemeRoller" class="ui-icon_link ui-state-default ui-corner-all" href="#">loading theme editor<blink>...</blink></a><p><p> |
24 | 23 | <video roe="http://metavid.org/w/index.php?title=Special:MvExportStream&stream_name=House_proceeding_07-18-06_00&t=1:23:16/1:23:44&feed_format=roe" ></video> |
25 | 24 | </table> |
26 | 25 | |
Index: branches/new-upload/phase3/js2/mwEmbed/example_usage/Make_Ogg_Simple.html |
— | — | @@ -34,9 +34,6 @@ |
35 | 35 | <span id="loadFogg">Loading firefogg <blink>...</blink></span> |
36 | 36 | <div style="float:left;height:400px" id="control_container"></div> |
37 | 37 | <br><br> |
38 | | - <!-- <span style="font:size:80%">Built using <a href="http://firefogg.org">firefogg</a> & <a href="http://jqueryui.com/">jquery.ui</a> Supports |
39 | | - <a href="javascript:(function(){if%20(!/Firefox[\/\s](\d+\.\d+)/.test(navigator.userAgent)){alert('Sorry,%20due%20to%20security%20restrictions,%20this%20tool%20only%20works%20in%20Firefox');%20return%20false;%20};%20if(window.jquitr){%20jquitr.addThemeRoller();%20}%20else{%20jquitr%20=%20{};%20jquitr.s%20=%20document.createElement('script');%20jquitr.s.src%20=%20'http://jqueryui.com/themeroller/developertool/developertool.js.php';%20document.getElementsByTagName('head')[0].appendChild(jquitr.s);}%20})();">custom themes</a>, <b>remix me</b> |
40 | | - </span> --> |
41 | 38 | </div> |
42 | 39 | </center> |
43 | 40 | </body></html> |
Index: branches/new-upload/phase3/js2/mwEmbed/libAddMedia/remoteSearchDriver.js |
— | — | @@ -329,13 +329,19 @@ |
330 | 330 | }); |
331 | 331 | } |
332 | 332 | }, |
333 | | - doInitDisplay:function(){ |
| 333 | + doInitDisplay:function(){ |
| 334 | + var _this = this; |
334 | 335 | //setup the parent container: |
335 | 336 | this.init_modal(); |
336 | 337 | //fill in the html: |
337 | 338 | this.init_interface_html(); |
338 | 339 | //bind actions: |
339 | 340 | this.add_interface_bindings(); |
| 341 | + |
| 342 | + //update the target bining to just unhide the dialog: |
| 343 | + $j(this.target_invocation).unbind().click(function(){ |
| 344 | + $j(_this.target_container).dialog('open'); |
| 345 | + }) |
340 | 346 | }, |
341 | 347 | //gets the in and out points for insert position or grabs the selected text for search |
342 | 348 | getTexboxSelection:function(){ |
— | — | @@ -381,7 +387,7 @@ |
382 | 388 | var _this = this; |
383 | 389 | //add the parent target_container if not provided or missing |
384 | 390 | if(!_this.target_container || $j(_this.target_container).length==0){ |
385 | | - $j('body').append('<div id="rsd_modal_target" title="' + gM('add_media_wizard') + '" ></div>'); |
| 391 | + $j('body').append('<div id="rsd_modal_target" style="position:relative" title="' + gM('add_media_wizard') + '" ></div>'); |
386 | 392 | _this.target_container = '#rsd_modal_target'; |
387 | 393 | js_log('appended: #rsd_modal_target' + $j(_this.target_container).attr('id')); |
388 | 394 | js_log('added target id:' + $j(_this.target_container).attr('id')); |
— | — | @@ -415,7 +421,7 @@ |
416 | 422 | if (resizeTimer) clearTimeout(resizeTimer); |
417 | 423 | var resizeTimer = setTimeout(adjustModal, 100); |
418 | 424 | });*/ |
419 | | - } |
| 425 | + } |
420 | 426 | }, |
421 | 427 | getMaxModalLayout:function(border){ |
422 | 428 | if(!border) |
— | — | @@ -436,9 +442,9 @@ |
437 | 443 | |
438 | 444 | var out = '<div class="rsd_control_container" style="width:100%">' + |
439 | 445 | '<form id="rsd_form" action="javascript:return false;" method="GET">'+ |
440 | | - '<input type="text" tabindex="1" value="' + dq + '" maxlength="512" id="rsd_q" name="rsd_q" '+ |
441 | | - 'size="20" autocomplete="off"/>'+ |
442 | | - '<a href="#" id="rms_search_button" class="ui-state-default ui-corner-all ui-icon_link"><span class="ui-icon ui-icon-search"></span>'+ gM('mv_media_search') +'</a>'+ |
| 446 | + '<input class="ui-widget-content ui-corner-all" type="text" tabindex="1" value="' + dq + '" maxlength="512" id="rsd_q" name="rsd_q" '+ |
| 447 | + 'size="20" autocomplete="off"/> '+ |
| 448 | + $j.btnHtml( gM('mv_media_search'), 'rms_search_button', 'search') + |
443 | 449 | '</form>'; |
444 | 450 | |
445 | 451 | /*out+='<div id="rsd_options_bar" style="display:none;width:100%;height:0px;background:#BBB">'; |
— | — | @@ -465,14 +471,9 @@ |
466 | 472 | |
467 | 473 | $j(this.target_container).html( out ); |
468 | 474 | //add simple styles: |
469 | | - $j('#rms_search_button').hover( |
470 | | - function(){ |
471 | | - $j(this).addClass('ui-state-hover'); |
472 | | - }, |
473 | | - function(){ |
474 | | - $j(this).removeClass('ui-state-hover'); |
475 | | - } |
476 | | - ); |
| 475 | + $j(this.target_container + ' .rms_search_button').btnBind().click(function(){ |
| 476 | + _this.runSearch(); |
| 477 | + }); |
477 | 478 | |
478 | 479 | //draw the tabs: |
479 | 480 | this.drawTabs(); |
— | — | @@ -919,18 +920,18 @@ |
920 | 921 | var overflow_style = ( mediaType =='video' )?'':'overflow:auto;'; |
921 | 922 | //append to the top level of model window: |
922 | 923 | $j( _this.target_container ).append('<div id="rsd_resource_edit" '+ |
923 | | - 'style="position:absolute;top:0px;left:0px;width:100%;height:100%;background-color:#FFF;">' + |
924 | | - '<h3 id="rsd_resource_title" style="margin:4px;">' + gM('rsd_resource_edit', rObj.title ) +'</h3>'+ |
925 | | - '<div id="clip_edit_disp" style="position:absolute;'+overflow_style+'top:35px;left:5px;bottom:0px;'+ |
926 | | - 'width:' + (maxWidth + 25) + 'px;" >' + |
| 924 | + 'style="position:absolute;top:0px;left:0px;width:100%;height:100%;background-color:#FFF;">' + |
| 925 | + '<div id="clip_edit_disp" style="position:absolute;' + overflow_style + 'width:100%;height:100%;padding:5px;'+ |
| 926 | + 'width:' + (maxWidth + 10) + 'px;" >' + |
927 | 927 | mv_get_loading_img('position:absolute;top:30px;left:30px') + |
928 | 928 | '</div>'+ |
929 | 929 | '<div id="clip_edit_ctrl" style="position:absolute;border:solid thin blue;'+ |
930 | | - 'top:35px;left:' + ( maxWidth + 30 ) +'px;bottom:0px;right:0px;padding:5px;overflow:auto;">'+ |
| 930 | + 'left:' + ( maxWidth + 10 ) +'px;top:5px;bottom:0px;right:0px;overflow:auto;padding:5px;">'+ |
931 | 931 | mv_get_loading_img() + |
932 | 932 | '</div>'+ |
933 | 933 | '</div>'); |
934 | | - |
| 934 | + //update add media wizard title: |
| 935 | + $j( _this.target_container ).dialog( 'option', 'title', gM('add_media_wizard')+': '+ gM('rsd_resource_edit', rObj.title ) ); |
935 | 936 | js_log('did append to: '+ _this.target_container ); |
936 | 937 | |
937 | 938 | $j('#rsd_resource_edit').css('opacity',0); |
— | — | @@ -1017,7 +1018,7 @@ |
1018 | 1019 | var _this = this; |
1019 | 1020 | var mvClipInit = { |
1020 | 1021 | 'rObj':rObj, //the resource object |
1021 | | - 'parent_ct':'rsd_resource_edit', |
| 1022 | + 'parent_ct':'rsd_modal_target', |
1022 | 1023 | 'clip_disp_ct':'clip_edit_disp', |
1023 | 1024 | 'control_ct': 'clip_edit_ctrl', |
1024 | 1025 | 'media_type': mediaType, |
— | — | @@ -1052,9 +1053,9 @@ |
1053 | 1054 | //add the re-sizable to the doLoad request: |
1054 | 1055 | clibs['$j.ui.resizable'] ='jquery/' + jQueryUiVN + '/ui/ui.resizable.js'; |
1055 | 1056 | clibs['$j.fn.hoverIntent'] ='jquery/plugins/jquery.hoverIntent.js'; |
1056 | | - mvJsLoader.doLoad(clibs, function(){ |
| 1057 | + mvJsLoader.doLoad(clibs, function(){ |
1057 | 1058 | //make sure the rsd_edit_img is hidden: |
1058 | | - $j('#rsd_edit_img').hide(); |
| 1059 | + $j('#rsd_edit_img').remove(); |
1059 | 1060 | //run the image clip tools |
1060 | 1061 | _this.cEdit = new mvClipEdit( mvClipInit ); |
1061 | 1062 | }); |
— | — | @@ -1159,15 +1160,19 @@ |
1160 | 1161 | 'bottom:0px;top:30px;right:0px;overflow:auto;">'+ |
1161 | 1162 | '<strong>Local Resource Title:</strong><br>'+ |
1162 | 1163 | '<input type="text" size="30" value="' + rObj.target_resource_title + '" readonly="true"><br>'+ |
1163 | | - '<strong>Edit WikiText Resource Description:</strong>(will be replaced by forms soon)'+ |
1164 | | - '<textarea id="rsd_import_ta" id="mv_img_desc" style="width:90%;" rows="8" cols="50">'+ |
| 1164 | + '<strong>Edit WikiText Resource Description:</strong>(will be replaced by forms soon)' + |
| 1165 | + '<textarea id="rsd_import_ta" id="mv_img_desc" style="width:90%;" rows="8" cols="50">' + |
1165 | 1166 | wt + |
1166 | | - '</textarea><br>'+ |
1167 | | - '<input type="checkbox" value="true" id="wpWatchthis" name="wpWatchthis" tabindex="7"/>'+ |
1168 | | - '<label for="wpWatchthis">Watch this page</label><br>'+ |
1169 | | - '<input id="rsd_import_apreview" type="button" value="Update Preview"> ' + |
1170 | | - '<input style="font-weight: bold" id="rsd_import_doimport" type="button" value="Do Import Resource"> '+ |
1171 | | - '<a id="rsd_import_acancel" href="#">Cancel Import</a>'+ |
| 1167 | + '</textarea><br>' + |
| 1168 | + '<input type="checkbox" value="true" id="wpWatchthis" name="wpWatchthis" tabindex="7"/>' + |
| 1169 | + '<label for="wpWatchthis">Watch this page</label><br><br><br>' + |
| 1170 | + |
| 1171 | + $j.btnHtml('Do Import Resource', 'rsd_import_doimport', 'check' ) + ' ' + |
| 1172 | + |
| 1173 | + $j.btnHtml('Update Preview', 'rsd_import_apreview', 'refresh' ) + ' ' + |
| 1174 | + |
| 1175 | + $j.btnHtml('Cancel Import', 'rsd_import_acancel', 'close' ) + ' ' + |
| 1176 | + |
1172 | 1177 | '</div>'+ |
1173 | 1178 | //output the rendered and non-renderd version of description for easy swiching: |
1174 | 1179 | '</div>'); |
— | — | @@ -1176,7 +1181,7 @@ |
1177 | 1182 | $j('#rsd_import_desc').html(o); |
1178 | 1183 | }); |
1179 | 1184 | //add bidings: |
1180 | | - $j('#rsd_import_apreview').click(function(){ |
| 1185 | + $j( _this.target_container + ' .rsd_import_apreview').btnBind().click(function(){ |
1181 | 1186 | /*$j('#rsd_import_desc').show().html( |
1182 | 1187 | mv_get_loading_img() |
1183 | 1188 | );*/ |
— | — | @@ -1186,7 +1191,7 @@ |
1187 | 1192 | $j('#rsd_import_desc').html(o); |
1188 | 1193 | }); |
1189 | 1194 | }); |
1190 | | - $j('#rsd_import_doimport').click(function(){ |
| 1195 | + $j(_this.target_container + ' .rsd_import_doimport').click(function(){ |
1191 | 1196 | |
1192 | 1197 | //get an edittoken: |
1193 | 1198 | do_api_req( { |
— | — | @@ -1271,7 +1276,7 @@ |
1272 | 1277 | } |
1273 | 1278 | ); |
1274 | 1279 | }); |
1275 | | - $j('#rsd_import_acancel').click(function(){ |
| 1280 | + $j( _this.target_container + ' .rsd_import_acancel').click(function(){ |
1276 | 1281 | $j('#rsd_resource_import').fadeOut("fast",function(){ |
1277 | 1282 | $j(this).remove(); |
1278 | 1283 | }); |
Index: branches/new-upload/phase3/js2/mwEmbed/libClipEdit/mvClipEdit.js |
— | — | @@ -27,7 +27,10 @@ |
28 | 28 | "mv_other_properties":"Other Properties", |
29 | 29 | "mv_resource_page":"Resource Page", |
30 | 30 | |
31 | | - "mv_set_in_out_points": "Set in-out points" |
| 31 | + "mv_set_in_out_points": "Set in-out points", |
| 32 | + "mv_start_time": "Start Time", |
| 33 | + "mv_end_time": "End Time", |
| 34 | + "mv_preview_inout": "Preview/Play In-out points" |
32 | 35 | }); |
33 | 36 | |
34 | 37 | var default_clipedit_values = { |
— | — | @@ -112,8 +115,9 @@ |
113 | 116 | var start_ntp = (_this.rObj.embed.start_ntp) ? _this.rObj.embed.start_ntp : seconds2npt( 0 ); |
114 | 117 | if(!start_ntp) |
115 | 118 | seconds2npt( 0 ); |
| 119 | + |
116 | 120 | $j('#sub_cliplib_ic').html( |
117 | | - _this.getSetInOut({ |
| 121 | + _this.getSetInOutHtml({ |
118 | 122 | 'start_ntp' : start_ntp, |
119 | 123 | 'end_ntp' : end_ntp |
120 | 124 | }) |
— | — | @@ -320,17 +324,16 @@ |
321 | 325 | $j('#'+this.control_ct).html('<h3>Edit Video Tools:</h3>'); |
322 | 326 | if( eb.supportsURLTimeEncoding() ){ |
323 | 327 | $j('#'+this.control_ct).append( |
324 | | - _this.getSetInOut({ |
| 328 | + _this.getSetInOutHtml({ |
325 | 329 | 'start_ntp' : eb.start_ntp, |
326 | | - 'end_ntp' : eb.end_ntp |
| 330 | + 'end_ntp' : eb.end_ntp |
327 | 331 | }) |
328 | 332 | ); |
329 | 333 | _this.setInOutBindings(); |
330 | 334 | } |
331 | 335 | $j('#'+this.control_ct).append( _this.getInsertDescHtml() ); |
332 | 336 | |
333 | | - if( _this.p_rsdObj && _this.p_rsdObj.import_url_mode == 'none'){ |
334 | | - // in theory this code should never run since we should nto get past the repository checks |
| 337 | + if( _this.p_rsdObj && _this.p_rsdObj.import_url_mode == 'none'){ |
335 | 338 | $j('#'+this.control_ct).append( gM('no_import_by_url') + '<br>' + |
336 | 339 | '<a href="#" class="mv_cancel_img_edit" title="' + gM('mv_cancel_image_insert')+'">' + gM('mv_cancel_image_insert') + '</a> ' ); |
337 | 340 | }else{ |
— | — | @@ -340,56 +343,70 @@ |
341 | 344 | }, |
342 | 345 | setInOutBindings:function(){ |
343 | 346 | var _this = this; |
344 | | - //setup bindings for adjust / preview: |
345 | | - add_adjust_hooks( 'rsd', function(){ |
346 | | - //update the resource |
347 | | - _this.applyVideoAdj(); |
348 | | - }); |
349 | | - $j('#mv_preview_clip').click(function(){ |
| 347 | + |
| 348 | + var start_sec = npt2seconds($j('#'+this.control_ct + ' .startInOut').val() ); |
| 349 | + var end_sec = npt2seconds($j('#'+this.control_ct + ' .endInOut').val() ); |
| 350 | + |
| 351 | + //if we don't have 0 as start then assume we are in a range request and give some buffer area: |
| 352 | + var min_slider = (start_sec - 60 < 0 ) ? 0 : start_sec - 60; |
| 353 | + if(min_slider!=0){ |
| 354 | + var max_slider = end_sec+60; |
| 355 | + }else{ |
| 356 | + max_slider = end_sec; |
| 357 | + } |
| 358 | + |
| 359 | + $j('#'+this.control_ct + ' .inOutSlider').slider({ |
| 360 | + range: true, |
| 361 | + min: min_slider, |
| 362 | + max: max_slider, |
| 363 | + values: [start_sec, end_sec], |
| 364 | + slide: function(event, ui) { |
| 365 | + js_log(" vals:"+ seconds2npt( ui.values[0] ) + ' : ' + seconds2npt( ui.values[1]) ); |
| 366 | + $j('#'+_this.control_ct + ' .startInOut').val( seconds2npt( ui.values[0] ) ); |
| 367 | + $j('#'+_this.control_ct + ' .endInOut').val( seconds2npt( ui.values[1] ) ); |
| 368 | + }, |
| 369 | + change:function(event, ui){ |
| 370 | + do_video_time_update( seconds2npt( ui.values[0]), seconds2npt( ui.values[1] ) ); |
| 371 | + } |
| 372 | + }); |
| 373 | + |
| 374 | + //preview button: |
| 375 | + $j('#'+this.control_ct + ' .inOutPreviewClip').hover( |
| 376 | + function(){ |
| 377 | + $j(this).addClass('ui-state-hover'); |
| 378 | + }, |
| 379 | + function(){ |
| 380 | + $j(this).removeClass('ui-state-hover'); |
| 381 | + } |
| 382 | + ).click(function(){ |
350 | 383 | $j('#embed_vid').get(0).stop(); |
351 | 384 | $j('#embed_vid').get(0).play(); |
352 | | - }); |
| 385 | + }); |
| 386 | + //simple hover: |
| 387 | + |
353 | 388 | }, |
354 | | - getSetInOut:function( setInt ){ |
| 389 | + getSetInOutHtml:function( setInt ){ |
355 | 390 | return '<strong>' + gM('mv_set_in_out_points') + '</strong>'+ |
356 | 391 | '<table border="0" style="background: transparent; width:94%;height:50px;">'+ |
357 | 392 | '<tr>' + |
358 | 393 | '<td style="width:50px">'+ |
359 | | - '<span style="font-size: small;" id="track_time_start_rsd">' + setInt.start_ntp +'</span>'+ |
| 394 | + gM('mv_start_time') + |
| 395 | + '<input class="ui-widget-content ui-corner-all startInOut" size="9" value="' + setInt.start_ntp +'">'+ |
360 | 396 | '</td>' + |
361 | 397 | '<td>' + |
362 | | - '<div style="border: 1px solid black; width: 100%; height: 5px; background-color: #888;" '+ |
363 | | - 'id="container_track_rsd">'+ |
364 | | - '<div id="resize_rsd" class="ui-resizable ui-draggable">'+ |
365 | | - '<div class="ui-resizable-w ui-resizable-handle"'+ |
366 | | - ' id="handle1_rsd" unselectable="on"/>'+ |
367 | | - |
368 | | - '<div class="ui-resizable-e ui-resizable-handle" '+ |
369 | | - ' id="handle2_rsd" unselectable="on"/>'+ |
370 | | - |
371 | | - '<div class="ui-dragSpan" id="dragSpan_rsd" style="cursor: move;"/>'+ |
372 | | - '</div>'+ |
373 | | - '</div>'+ |
| 398 | + '<div class="inOutSlider"></div>'+ |
374 | 399 | '</td>' + |
375 | 400 | '<td style="width:50px">'+ |
376 | | - '<span style="font-size: small;" id="track_time_end_rsd">'+ setInt.end_ntp +'</span>'+ |
| 401 | + gM('mv_end_time') + |
| 402 | + '<input class="ui-widget-content ui-corner-all endInOut" size="9" value="'+ setInt.end_ntp +'">'+ |
377 | 403 | '</td>' + |
378 | 404 | '</tr>' + |
379 | 405 | '</table>'+ |
380 | | - '<span style="float: left;">'+ |
381 | | - '<label class="mv_css_form" for="mv_start_hr_rsd"><i>Start time:</i></label>'+ |
382 | | - '<input id="mv_start_hr_rsd" class="mv_adj_hr" name="mv_start_hr_rsd" value="' + setInt.start_ntp + '" maxlength="8" size="8"/>'+ |
383 | | - '</span>'+ |
384 | | - '<span style="float: left;">'+ |
385 | | - '<label for="mv_end_hr_rsd" class="mv_css_form"><i>End time:</i></label>'+ |
386 | | - '<input name="mv_end_hr_rsd" id="mv_end_hr_rsd" value="' + setInt.end_ntp + '" maxlength="8" size="8" class="mv_adj_hr"/>'+ |
387 | | - '</span>'+ |
388 | | - '<div style="clear: both;"/>'+ |
389 | | - '<input id="mv_preview_clip" type="button" value="Preview/Play In-out points">'; |
| 406 | + '<a href="#" class="ui-state-default ui-corner-all ui-icon_link inOutPreviewClip"><span class="ui-icon ui-icon-video"></span>'+ gM('mv_preview_inout') +'</a>'; |
390 | 407 | }, |
391 | 408 | getInsertDescHtml:function(){ |
392 | 409 | var o= '<h3>Inline Description</h3>'+ |
393 | | - '<textarea style="width:375px;" id="mv_inline_img_desc" rows="5" cols="30">'; |
| 410 | + '<textarea style="width:95%" id="mv_inline_img_desc" rows="5" cols="30">'; |
394 | 411 | if( this.p_rsdObj ){ |
395 | 412 | //if we have a parent remote search driver let it parse the inline description |
396 | 413 | o+= this.rObj.pSobj.getInlineDescWiki( this.rObj ); |
— | — | @@ -398,11 +415,11 @@ |
399 | 416 | //js_log('getInsertDescHtml: ' + o ); |
400 | 417 | return o; |
401 | 418 | }, |
402 | | - getInsertAction:function(){ |
| 419 | + getInsertAction:function(){ |
403 | 420 | return '<h3>Actions</h3>'+ |
404 | | - '<input type="button" class="mv_insert_image_page" value="' + gM('mv_insert_image_page') + '"> '+ |
405 | | - '<input type="button" style="font-weight:bold" class="mv_preview_insert" value="' + gM('mv_preview_insert')+ '"> '+ |
406 | | - '<a href="#" class="mv_cancel_img_edit" title="' + gM('mv_cancel_image_insert')+'">' + gM('mv_cancel_image_insert') + '</a> '; |
| 421 | + $j.btnHtml( gM('mv_insert_image_page'), 'mv_insert_image_page', 'check' ) + ' ' + |
| 422 | + $j.btnHtml( gM('mv_preview_insert'), 'mv_preview_insert', 'refresh') + ' ' + |
| 423 | + $j.btnHtml( gM('mv_cancel_image_insert'), 'mv_cancel_img_edit', 'close'); |
407 | 424 | }, |
408 | 425 | applyEdit:function(){ |
409 | 426 | js_log('applyEdit::' + this.media_type); |
— | — | @@ -414,21 +431,23 @@ |
415 | 432 | }, |
416 | 433 | applyInsertControlBindings:function(){ |
417 | 434 | var _this = this; |
418 | | - $j('.mv_insert_image_page').click(function(){ |
| 435 | + $j('.mv_insert_image_page').btnBind().click(function(){ |
419 | 436 | _this.applyEdit(); |
420 | 437 | //copy over the desc text to the resource object |
421 | 438 | _this.rObj['inlineDesc']= $j('#mv_inline_img_desc').val(); |
422 | 439 | _this.p_rsdObj.insertResource( _this.rObj ); |
423 | 440 | }); |
424 | | - $j('.mv_preview_insert').click(function(){ |
| 441 | + $j('.mv_preview_insert').btnBind().click(function(){ |
425 | 442 | _this.applyEdit(); |
426 | 443 | //copy over the desc text to the resource object |
427 | 444 | _this.rObj['inlineDesc']= $j('#mv_inline_img_desc').val(); |
428 | 445 | js_log('going to call previewResource on rObj'); |
429 | 446 | _this.p_rsdObj.previewResource( _this.rObj ); |
430 | 447 | }); |
431 | | - $j('.mv_cancel_img_edit').click( function(){ |
432 | | - $j('#' + _this.parent_ct).fadeOut("fast"); |
| 448 | + $j('.mv_cancel_img_edit').btnBind().click( function(){ |
| 449 | + $j('#rsd_resource_edit').fadeOut("fast"); |
| 450 | + //restore the title: |
| 451 | + $j( _this.p_rsdObj.target_container ).dialog( 'option', 'title', gM('add_media_wizard')); |
433 | 452 | }); |
434 | 453 | }, |
435 | 454 | setUpImageCtrl:function(){ |
— | — | @@ -502,8 +521,9 @@ |
503 | 522 | $j('#embed_vid').get(0).stop(); |
504 | 523 | |
505 | 524 | //update video related keys: |
506 | | - this.rObj['start_time'] = $j('#mv_start_hr_rsd').val(); |
507 | | - this.rObj['end_time'] = $j('#mv_end_hr_rsd').val(); |
| 525 | + ; |
| 526 | + this.rObj['start_time'] = $j('#'+this.control_ct + ' .startInOut').val(); |
| 527 | + this.rObj['end_time'] = $j('#'+this.control_ct + ' .endInOut').val() ; |
508 | 528 | |
509 | 529 | //do the local video adjust |
510 | 530 | if(typeof this.rObj.pSobj['applyVideoAdj'] != 'undefined'){ |
Index: branches/new-upload/phase3/js2/mwEmbed/skins/mvpcf/styles.css |
— | — | @@ -217,6 +217,12 @@ |
218 | 218 | margin-left:-5px; |
219 | 219 | margin-top:1px; |
220 | 220 | } |
| 221 | + |
| 222 | +.inOutSlider .ui-slider-handle{ |
| 223 | + width:8px; |
| 224 | + cusror: move; |
| 225 | +} |
| 226 | + |
221 | 227 | /* |
222 | 228 | .videoPlayer .seeker { |
223 | 229 | float: right; |
— | — | @@ -309,7 +315,7 @@ |
310 | 316 | width: 183px; |
311 | 317 | overflow: hidden; |
312 | 318 | position: absolute; |
313 | | - z-index: 100; |
| 319 | + z-index: 9999; |
314 | 320 | /* margin: 0 0 0 230px;*/ |
315 | 321 | } |
316 | 322 | *:first-child+html .videoOptions {margin-top: -20px;} |
Index: branches/new-upload/phase3/js2/mwEmbed/mv_embed.js |
— | — | @@ -666,7 +666,26 @@ |
667 | 667 | myUp.setupForm(); |
668 | 668 | }); |
669 | 669 | } |
670 | | - |
| 670 | + |
| 671 | + //shortcut to a themed button: |
| 672 | + $.btnHtml = function(msg, className, iconId){ |
| 673 | + return '<a href="#" class="ui-state-default ui-corner-all ui-icon_link ' + |
| 674 | + className + '"><span class="ui-icon ui-icon-' + iconId + '" />' + |
| 675 | + msg + '</a>'; |
| 676 | + } |
| 677 | + //shortcut to bind hover state: |
| 678 | + $.fn.btnBind = function(){ |
| 679 | + $j(this.selector).hover( |
| 680 | + function(){ |
| 681 | + $j(this).addClass('ui-state-hover'); |
| 682 | + }, |
| 683 | + function(){ |
| 684 | + $j(this).removeClass('ui-state-hover'); |
| 685 | + } |
| 686 | + ) |
| 687 | + return this; |
| 688 | + } |
| 689 | + |
671 | 690 | })(jQuery); |
672 | 691 | } |
673 | 692 | |