From 89da62649161571834d3f8df7ce36f9967e6ba04 Mon Sep 17 00:00:00 2001
From: wangzhibo <wangzhibo@shsening.com>
Date: 星期二, 07 九月 2021 14:04:31 +0800
Subject: [PATCH] change cesium version
---
widgets/manageBasemaps/widget.js | 40 ++++++++++++++++++++--------------------
1 files changed, 20 insertions(+), 20 deletions(-)
diff --git a/widgets/manageBasemaps/widget.js b/widgets/manageBasemaps/widget.js
index 11d9aa3..cbc41d9 100644
--- a/widgets/manageBasemaps/widget.js
+++ b/widgets/manageBasemaps/widget.js
@@ -1,56 +1,56 @@
-'use script' //寮�鍙戠幆澧冨缓璁紑鍚弗鏍兼ā寮�
-;(function (window, mars3d) {
+"use script"; //寮�鍙戠幆澧冨缓璁紑鍚弗鏍兼ā寮�
+(function (window, mars3d) {
//鍒涘缓widget绫伙紝闇�瑕佺户鎵緽aseWidget
class MyWidget extends mars3d.widget.BaseWidget {
//寮圭獥閰嶇疆
get view() {
- var index = this.getBasemaps().length
+ var index = this.getBasemaps().length;
- var width, height
+ var width, height;
if (index <= 4) {
- width = 190
- height = Math.ceil(index / 2) * 100 + 70
+ width = 190;
+ height = Math.ceil(index / 2) * 100 + 70;
} else if (index > 4 && index <= 6) {
- width = 270
- height = Math.ceil(index / 3) * 100 + 70
+ width = 270;
+ height = Math.ceil(index / 3) * 100 + 70;
} else {
- width = 360
- height = Math.ceil(index / 4) * 105 + 70
+ width = 360;
+ height = Math.ceil(index / 4) * 105 + 70;
}
return {
- type: 'window',
- url: 'view.html',
+ type: "window",
+ url: "view.html",
windowOptions: {
width: width,
height: height,
},
- }
+ };
}
//鍒濆鍖朳浠呮墽琛�1娆
create() {}
//姣忎釜绐楀彛鍒涘缓瀹屾垚鍚庤皟鐢�
winCreateOK(opt, result) {
- this.viewWindow = result
+ this.viewWindow = result;
}
//鎵撳紑婵�娲�
activate() {}
//鍏抽棴閲婃斁
disable() {
- this.viewWindow = null
+ this.viewWindow = null;
}
getBasemaps() {
- return this.map.getBasemaps(true)
+ return this.map.getBasemaps(true);
}
updateBasemap(item) {
- this.map.basemap = item
- this.disableBase()
+ this.map.basemap = item;
+ this.disableBase();
}
}
//娉ㄥ唽鍒皐idget绠$悊鍣ㄤ腑銆�
- mars3d.widget.bindClass(MyWidget)
+ mars3d.widget.bindClass(MyWidget);
//姣忎釜widet涔嬮棿閮芥槸鐩存帴寮曞叆鍒癷ndex.html涓紝浼氬瓨鍦ㄥ郊姝ゅ懡鍚嶅啿绐侊紝鎵�浠ラ棴鍖呭鐞嗕笅銆�
-})(window, mars3d)
+})(window, mars3d);
--
Gitblit v1.9.1