|
@@ -85,7 +85,7 @@ export default {
|
|
|
state.isOpen3d = data;
|
|
|
},
|
|
|
toggle3dStatus(state) {
|
|
|
- var element = document.getElementById('house-player');
|
|
|
+ var element = document.getElementById('house-player').parentNode;
|
|
|
state.isOpen3d = !state.isOpen3d;
|
|
|
|
|
|
if (state.isOpen3d) {
|
|
@@ -94,14 +94,15 @@ export default {
|
|
|
window.sdkInstance.changeMode('panorama');
|
|
|
let player = document.getElementById('player')
|
|
|
player.appendChild(element)
|
|
|
- element.style.width = window.innderWidth+'px';
|
|
|
- element.style.height = window.innderHeight+'px';
|
|
|
+ var elementChild = document.getElementById('house-player');
|
|
|
+ elementChild.style.width = window.innderWidth+'px';
|
|
|
+ elementChild.style.height = window.innderHeight+'px';
|
|
|
window.renderWidth = window.innderWidth;
|
|
|
window.renderHeight = window.innderHeight;
|
|
|
- element.width = (window.innderWidth * 2);
|
|
|
- element.height = (window.innderHeight * 2);
|
|
|
- element.style.marginLeft = '0px';
|
|
|
- element.style.marginTop = '0px';
|
|
|
+ elementChild.width = (window.innderWidth * 2);
|
|
|
+ elementChild.height = (window.innderHeight * 2);
|
|
|
+ elementChild.style.marginLeft = '0px';
|
|
|
+ elementChild.style.marginTop = '0px';
|
|
|
})
|
|
|
sessionStorage.setItem('3dMode', 1)
|
|
|
} else {
|