Преглед на файлове

视频压缩中选择图片

1712772270@qq.com преди 8 години
родител
ревизия
6fbe518bab

+ 13 - 2
display-server/web/biz/js/plugin/videocompress.js

@ -1,7 +1,18 @@
1 1
require(["domReady!","wadeMobile", "util"], function(doc,WadeMobile) {
2
	var iscroll = new iScroll("content");
2
	var iscroll = new iScroll("content");
3
	
4
	/**
5
	 * 选择视频
6
	 */
7
	$("#getVideoPath").tap(function(){
8
		WadeMobile.getVideoPath(function(videoPath){
9
			$("#videoPath").html(videoPath);
10
		});
11
	});
12
	
3 13
	//视频压缩
4 14
	$("#videoCompressor").tap(function() {
5
		WadeMobile.videoCompressor();
15
		var videoPath = $("#videoPath").html();
16
		WadeMobile.videoCompressor(videoPath);
6 17
	});
7 18
});

+ 6 - 1
display-server/web/res/js/mobile/expand-mobile.js

@ -49,7 +49,10 @@ define(["require"],function(require) {
49 49
				}
50 50
				storageCallback("getPicture",callback);
51 51
				execute("getPicture", [type],err);
52
			},transImageToBase64:function(callback,path,err){
52
			},getVideoPath:function(callback,err){//获取视频
53
				storageCallback("getVideoPath", callback);
54
				execute("getVideoPath",[],err);
55
			}transImageToBase64:function(callback,path,err){
53 56
				storageCallback("transImageToBase64",callback);
54 57
				execute("transImageToBase64", [path],err);
55 58
			},compressImage:function(callback,path,fileSize,quality,err){
@ -375,6 +378,8 @@ define(["require"],function(require) {
375 378
                    execute("clearBackStack",[]);
376 379
                }
377 380
            }
381
			
382
			
378 383
		};
379 384
	})();
380 385
	

+ 15 - 0
display-server/web/template/webapp/plugin/VideoCompress.html

@ -39,7 +39,22 @@
39 39
			</li>
40 40
		</ul>
41 41
	</div>
42
	<div class="c_list">
43
			<ul>
44
				<li>
45
					<div class="content">
46
						<div class="main" id="getVideoPath">
47
							<div class="title">选择视频</div>
48
							<div class="info">
49
								视频路径为:<span id="videoPath"></span>
50
							</div>
51
						</div>
52
					</div>
53
				</li>
54
			</ul>
55
		</div>
42 56
</div>
57
43 58
</div>
44 59
45 60
</body>