wsd: support embedded video - relative link
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com> Change-Id: I4351bc801914583ab589b424059748858d7937d4
This commit is contained in:
parent
b4ee1a49f0
commit
353e269c55
2 changed files with 3 additions and 4 deletions
|
@ -2086,13 +2086,15 @@ L.CanvasTileLayer = L.Layer.extend({
|
|||
videoDesc.height = bottomRightPoint.y - topLeftPoint.y;
|
||||
}
|
||||
|
||||
var serverPrefix = window.makeHttpUrl('');
|
||||
|
||||
var videoToInsert = '<?xml version="1.0" encoding="UTF-8"?>\
|
||||
<foreignObject xmlns="http://www.w3.org/2000/svg" overflow="visible" width="'
|
||||
+ videoDesc.width + '" height="' + videoDesc.height + '">\
|
||||
<body xmlns="http://www.w3.org/1999/xhtml">\
|
||||
<video controls="controls" width="' + videoDesc.width + '" height="'
|
||||
+ videoDesc.height + '">\
|
||||
<source src="' + videoDesc.url + '" type="' + videoDesc.mimeType + '"/>\
|
||||
<source src="' + serverPrefix + videoDesc.url + '" type="' + videoDesc.mimeType + '"/>\
|
||||
</video>\
|
||||
</body>\
|
||||
</foreignObject>';
|
||||
|
|
|
@ -3831,9 +3831,6 @@ std::string DocumentBroker::generatePublicMediaUrl(const std::string& mediaId) c
|
|||
Poco::URI::encode(Util::split(_uriPublic.toString(), '?').first, ":?#/=&", wopiSrc);
|
||||
|
||||
Poco::URI uri("/cool/media");
|
||||
uri.setScheme(_uriPublic.getScheme());
|
||||
uri.setHost(_uriPublic.getHost());
|
||||
uri.setPort(COOLWSD::getClientPortNumber());
|
||||
uri.addQueryParameter("ServerId", Util::getProcessIdentifier());
|
||||
uri.addQueryParameter("Tag", mediaId);
|
||||
uri.addQueryParameter("WOPISrc", wopiSrc);
|
||||
|
|
Loading…
Reference in a new issue