summaryrefslogtreecommitdiffhomepage
path: root/gui
diff options
context:
space:
mode:
authorAlbin <albin@mullvad.net>2024-04-05 13:56:21 +0200
committerAlbin <albin@mullvad.net>2024-04-05 13:56:21 +0200
commit5d942939d93f2a5624291fadb206d8429f57c1c8 (patch)
tree33fe1e9fbda0721f296fb9f739f3aa2e4c254e34 /gui
parent848a1a2bcb967369c26afa212be7c9751ddaa4d3 (diff)
parentb000c35f46254517c967fe4f89d41cc6d6a4b4d5 (diff)
downloadmullvadvpn-5d942939d93f2a5624291fadb206d8429f57c1c8.tar.xz
mullvadvpn-5d942939d93f2a5624291fadb206d8429f57c1c8.zip
Merge branch 'move-and-rename-map-gl-data'
Diffstat (limited to 'gui')
-rw-r--r--gui/assets/geo/land_contour_indices.binbin392804 -> 0 bytes
-rw-r--r--gui/assets/geo/land_positions.binbin1057116 -> 0 bytes
-rw-r--r--gui/assets/geo/land_triangle_indices.binbin1214460 -> 0 bytes
-rw-r--r--gui/assets/geo/ocean_indices.binbin61440 -> 0 bytes
-rw-r--r--gui/assets/geo/ocean_positions.binbin30744 -> 0 bytes
-rw-r--r--gui/src/main/index.ts12
-rw-r--r--gui/tasks/assets.js8
-rw-r--r--gui/tasks/watch.js5
8 files changed, 16 insertions, 9 deletions
diff --git a/gui/assets/geo/land_contour_indices.bin b/gui/assets/geo/land_contour_indices.bin
deleted file mode 100644
index 37d0460ebe..0000000000
--- a/gui/assets/geo/land_contour_indices.bin
+++ /dev/null
Binary files differ
diff --git a/gui/assets/geo/land_positions.bin b/gui/assets/geo/land_positions.bin
deleted file mode 100644
index 1e048d6234..0000000000
--- a/gui/assets/geo/land_positions.bin
+++ /dev/null
Binary files differ
diff --git a/gui/assets/geo/land_triangle_indices.bin b/gui/assets/geo/land_triangle_indices.bin
deleted file mode 100644
index 7fef5d9de2..0000000000
--- a/gui/assets/geo/land_triangle_indices.bin
+++ /dev/null
Binary files differ
diff --git a/gui/assets/geo/ocean_indices.bin b/gui/assets/geo/ocean_indices.bin
deleted file mode 100644
index f60ba3b3d3..0000000000
--- a/gui/assets/geo/ocean_indices.bin
+++ /dev/null
Binary files differ
diff --git a/gui/assets/geo/ocean_positions.bin b/gui/assets/geo/ocean_positions.bin
deleted file mode 100644
index cca8aa7d95..0000000000
--- a/gui/assets/geo/ocean_positions.bin
+++ /dev/null
Binary files differ
diff --git a/gui/src/main/index.ts b/gui/src/main/index.ts
index a844655388..4cdb9f5727 100644
--- a/gui/src/main/index.ts
+++ b/gui/src/main/index.ts
@@ -767,15 +767,13 @@ class ApplicationMain
}));
IpcMainEventChannel.map.handleGetData(async () => ({
- landContourIndices: await fs.promises.readFile(
- path.join(GEO_DIR, 'land_contour_indices.bin'),
- ),
- landPositions: await fs.promises.readFile(path.join(GEO_DIR, 'land_positions.bin')),
+ landContourIndices: await fs.promises.readFile(path.join(GEO_DIR, 'land_contour_indices.gl')),
+ landPositions: await fs.promises.readFile(path.join(GEO_DIR, 'land_positions.gl')),
landTriangleIndices: await fs.promises.readFile(
- path.join(GEO_DIR, 'land_triangle_indices.bin'),
+ path.join(GEO_DIR, 'land_triangle_indices.gl'),
),
- oceanIndices: await fs.promises.readFile(path.join(GEO_DIR, 'ocean_indices.bin')),
- oceanPositions: await fs.promises.readFile(path.join(GEO_DIR, 'ocean_positions.bin')),
+ oceanIndices: await fs.promises.readFile(path.join(GEO_DIR, 'ocean_indices.gl')),
+ oceanPositions: await fs.promises.readFile(path.join(GEO_DIR, 'ocean_positions.gl')),
}));
IpcMainEventChannel.tunnel.handleConnect(this.connectTunnel);
diff --git a/gui/tasks/assets.js b/gui/tasks/assets.js
index ee53363a6a..56b0c7a8ad 100644
--- a/gui/tasks/assets.js
+++ b/gui/tasks/assets.js
@@ -20,14 +20,20 @@ function copyLocales() {
return src('locales/**/*.po').pipe(dest('build/locales'));
}
+function copyGeoData() {
+ return src('../dist-assets/geo/*.gl').pipe(dest('build/assets/geo'));
+}
+
copyStaticAssets.displayName = 'copy-static-assets';
copyConfig.displayName = 'copy-config';
copyCss.displayName = 'copy-css';
copyHtml.displayName = 'copy-html';
copyLocales.displayName = 'copy-locales';
+copyGeoData.displayName = 'copy-geo-data';
-exports.copyAll = parallel(copyStaticAssets, copyConfig, copyCss, copyHtml, copyLocales);
+exports.copyAll = parallel(copyStaticAssets, copyConfig, copyCss, copyHtml, copyLocales, copyGeoData);
exports.copyStaticAssets = copyStaticAssets;
exports.copyCss = copyCss;
exports.copyHtml = copyHtml;
exports.copyConfig = copyConfig;
+exports.copyGeoData = copyGeoData;
diff --git a/gui/tasks/watch.js b/gui/tasks/watch.js
index 7badef949e..c64c4d48d3 100644
--- a/gui/tasks/watch.js
+++ b/gui/tasks/watch.js
@@ -20,7 +20,10 @@ function watchHtml() {
}
function watchStaticAssets() {
- return watch(['assets/**'], series(assets.copyStaticAssets, electron.reloadRenderer));
+ return watch(
+ ['assets/**', '../dist-assets/geo/*.gl'],
+ series(assets.copyStaticAssets, assets.copyGeoData, electron.reloadRenderer),
+ );
}
watchMainScripts.displayName = 'watch-main-scripts';