更新 infowindow-view.js

This commit is contained in:
钟进 2020-06-16 05:56:12 +00:00
parent 33e58f10ec
commit 25d896e213

View File

@ -118,6 +118,10 @@ var Infowindow = View.extend({
this._loadVideo();
}
if (this._containsH5url()) {
this._loadH5url();
}
this._setupClasses();
this._renderScroll();
this._renderShadows();
@ -128,6 +132,17 @@ var Infowindow = View.extend({
},
// video add
_containsH5url: function () {
return !!this.$('.js-infowindow').attr('data-h5url');
},
_loadH5url: function () {
var url = this._getCoverURL();
var $urlsrc = this.$('#mainContent');
$urlsrc.attr('src', url);
},
_containsVideo: function () {
return !!this.$('.js-infowindow').attr('data-video');
@ -138,6 +153,8 @@ var Infowindow = View.extend({
//this._startCoverLoader();
var url = this._getCoverURL();
var $urlsrc = this.$('#target');
$urlsrc.attr('src', url);
/*
if (this._isLoadingFields()) {