Index: branches/MwEmbedStandAlone/mwEmbed.js |
— | — | @@ -1088,7 +1088,7 @@ |
1089 | 1089 | var buttonMsg = options.buttons; |
1090 | 1090 | buttons = { }; |
1091 | 1091 | options.buttons[ buttonMsg ] = function() { |
1092 | | - $j( '#mwTempLoaderDialog' ).dialog( 'close' ); |
| 1092 | + $j( this ).dialog( 'close' ); |
1093 | 1093 | } |
1094 | 1094 | } |
1095 | 1095 | |
Index: branches/MwEmbedStandAlone/modules/Sequencer/Sequencer.i18n.php |
— | — | @@ -54,6 +54,7 @@ |
55 | 55 | 'mwe-sequencer-url-or-search' => 'URL or search term', |
56 | 56 | 'mwe-sequencer-get-media' => 'Get media', |
57 | 57 | 'mwe-sequencer-insert-resource' => 'Insert resource into sequence', |
| 58 | + 'mwe-sequencer-insert'=> 'Insert into sequence', |
58 | 59 | |
59 | 60 | 'mwe-sequencer-transition_in' => 'Transition in', |
60 | 61 | 'mwe-sequencer-transition_out' => 'Transition out', |
Index: branches/MwEmbedStandAlone/modules/Sequencer/mw.SequencerAddMedia.js |
— | — | @@ -56,7 +56,12 @@ |
57 | 57 | 'icon_id' : 'plus' |
58 | 58 | }) |
59 | 59 | .click(function(){ |
60 | | - _this.proccessRequest(); |
| 60 | + // only do the search if the user has given the search input focus |
| 61 | + if( widgetFocus ){ |
| 62 | + _this.proccessRequest(); |
| 63 | + } |
| 64 | + // don't follow the button link |
| 65 | + return false; |
61 | 66 | }) |
62 | 67 | ) |
63 | 68 | }, |
— | — | @@ -96,13 +101,28 @@ |
97 | 102 | * buttons include insert at end or insert after current |
98 | 103 | */ |
99 | 104 | insertResourceDialog: function( resource ){ |
| 105 | + var buttons = {}; |
| 106 | + // insert after last selected clip ( or at end ) |
| 107 | + buttons[ gM('mwe-sequencer-insert') ] = function() { |
| 108 | + mw.log("insert resource into sequence"); |
| 109 | + var cat = resource; |
| 110 | + debugger; |
| 111 | + } |
| 112 | + // cancel |
| 113 | + buttons[ gM('mwe-cancel') ] = function(){ |
| 114 | + $j( this ).dialog( 'close' ); |
| 115 | + }; |
| 116 | + |
100 | 117 | mw.addDialog({ |
101 | 118 | 'title' : gM('mwe-sequencer-insert-resource'), |
102 | 119 | 'dragable' : true, |
103 | 120 | 'height' : 480, |
104 | 121 | 'width' : 640, |
105 | 122 | 'resizable' : true, |
106 | | - 'content' : $j('<div />').text('import interface here') |
| 123 | + 'content' : function(){ |
| 124 | + // add the resource on-top and trim |
| 125 | + }, |
| 126 | + 'buttons' : buttons |
107 | 127 | }); |
108 | 128 | } |
109 | 129 | } |
Index: branches/MwEmbedStandAlone/modules/Sequencer/mw.SequencerTools.js |
— | — | @@ -185,12 +185,13 @@ |
186 | 186 | change: function( event, ui ) { |
187 | 187 | if( sliderValues[0] != ui.values[0] ){ |
188 | 188 | var attributeChanged = 'clipBegin'; |
189 | | - sliderIndex = 0; |
| 189 | + sliderIndex = 0; |
| 190 | + var attributeValue = sliderToTime( ui.values[ 0 ] ) |
190 | 191 | } else { |
191 | 192 | var attributeChanged = 'dur'; |
192 | 193 | sliderIndex = 1; |
193 | | - } |
194 | | - var attributeValue = sliderToTime( ui.values[ sliderIndex ] ) |
| 194 | + var attributeValue = sliderToTime( ui.values[ 1 ]- ui.values[0] ) |
| 195 | + } |
195 | 196 | sliderValues[ sliderIndex ] = ui.values[ sliderIndex ]; |
196 | 197 | |
197 | 198 | // update start and end time: |