Commit e9406d6d authored by Piotr Gawron's avatar Piotr Gawron
Browse files

GoogleMap implementation moved to separate folder

parent 551b5bb6
......@@ -45,30 +45,38 @@
"litemol": "github:dsehnal/LiteMol#67556b0de0d2428f9494136758cbf8a662f66412"
},
"dependencies": {
"ProtVista": {
"version": "git://github.com/davidhoksza/protvista.git#4e4bb737ba1e183291505bd25f8bae2e651ce21e",
"dev": true,
"requires": {
"d3": "3.5.17",
"file-saver": "1.3.3",
"jquery": "2.2.4",
"jszip": "3.1.4",
"underscore": "1.8.3"
},
"dependencies": {
"jquery": {
"version": "2.2.4",
"resolved": "https://registry.npmjs.org/jquery/-/jquery-2.2.4.tgz",
"integrity": "sha1-LInWiJterFIqfuoywUUhVZxsvwI=",
"dev": true
}
}
},
"jquery": {
"version": "3.3.1",
"resolved": "https://registry.npmjs.org/jquery/-/jquery-3.3.1.tgz",
"integrity": "sha512-Ubldcmxp5np52/ENotGxlLe6aGMvmF4R8S6tZjsP6Knsaxd/xp3Zrh50cG93lR6nPXyUFwzN3ZSOQI0wRJNdGg==",
"dev": true
}
}
},
"ProtVista": {
"version": "git://github.com/davidhoksza/protvista.git#4e4bb737ba1e183291505bd25f8bae2e651ce21e",
"dev": true,
"requires": {
"d3": "3.5.17",
"file-saver": "1.3.3",
"jquery": "2.2.4",
"jszip": "3.1.4",
"underscore": "1.8.3"
},
"dependencies": {
"jquery": {
"version": "2.2.4",
"resolved": "https://registry.npmjs.org/jquery/-/jquery-2.2.4.tgz",
"integrity": "sha1-LInWiJterFIqfuoywUUhVZxsvwI=",
"dev": true
},
"litemol": {
"version": "github:dsehnal/LiteMol#67556b0de0d2428f9494136758cbf8a662f66412",
"dev": true,
"requires": {
"@types/react": "15.6.15",
"@types/react-dom": "15.5.7"
}
}
}
},
......@@ -2050,14 +2058,6 @@
"immediate": "3.0.6"
}
},
"litemol": {
"version": "github:dsehnal/LiteMol#67556b0de0d2428f9494136758cbf8a662f66412",
"dev": true,
"requires": {
"@types/react": "15.6.15",
"@types/react-dom": "15.5.7"
}
},
"lodash": {
"version": "4.17.4",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz",
......
......@@ -55,5 +55,13 @@
"spectrum-colorpicker": "^1.8.0",
"text-encoding": "^0.6.4",
"xss": "^0.3.7"
},
"license": "AGPL-3.0",
"bugs": {
"url": "https://git-r3lab.uni.lu/piotr.gawron/minerva/issues"
},
"repository": {
"type": "git",
"url": "git+https://git-r3lab.uni.lu/piotr.gawron/minerva.git"
}
}
......@@ -19,7 +19,7 @@ var ReferenceGenome = require('./data/ReferenceGenome');
var SecurityError = require('../SecurityError');
var Submap = require('./Submap');
var GoogleMapsApiCanvas = require('./canvas/GoogleMapsApiCanvas');
var GoogleMapsApiCanvas = require('./canvas/GoogleMaps/GoogleMapsApiCanvas');
var Bounds = require('./canvas/Bounds');
var Point = require('./canvas/Point');
......
......@@ -7,7 +7,7 @@ var logger = require('../logger');
var AbstractCustomMap = require('./AbstractCustomMap');
var CustomMapOptions = require('./CustomMapOptions');
var GoogleMapsApiCanvas = require('./canvas/GoogleMapsApiCanvas');
var GoogleMapsApiCanvas = require('./canvas/GoogleMaps/GoogleMapsApiCanvas');
/**
* Constructor of a submap. Submaps are created on application start. But dialog
......
"use strict";
// noinspection JSUnusedLocalSymbols
var logger = require('../../logger');
var logger = require('../../../logger');
var Bounds = require('./Bounds');
var Functions = require('../../Functions');
var MapCanvas = require('./MapCanvas');
var Point = require('./Point');
var ObjectWithListeners = require('../../ObjectWithListeners');
var Bounds = require('../Bounds');
var Functions = require('../../../Functions');
var MapCanvas = require('../MapCanvas');
var Point = require('../Point');
var ObjectWithListeners = require('../../../ObjectWithListeners');
var GoogleMapsApiInfoWindow = require('./GoogleMapsApiInfoWindow');
var GoogleMapsApiMarker = require('./GoogleMapsApiMarker');
......@@ -301,7 +301,7 @@ GoogleMapsApiCanvas.prototype.setCenter = function (point) {
if (!(point instanceof Point)) {
throw new Error("Expected bounds but found: " + bounds);
}
this.getGoogleMap().setCenter(this.fromPointToLatLng(point));
return this.getGoogleMap().setCenter(this.fromPointToLatLng(point));
};
GoogleMapsApiCanvas.prototype.getCenter = function () {
......
"use strict";
var InfoWindow = require('./InfoWindow');
var InfoWindow = require('../InfoWindow');
var GoogleMapsApiMarker = require('./GoogleMapsApiMarker');
var logger = require('../../logger');
var logger = require('../../../logger');
// noinspection JSUnusedLocalSymbols
var Functions = require('../../Functions');
var Functions = require('../../../Functions');
function GoogleMapsApiInfoWindow(options) {
InfoWindow.call(this, options);
......
"use strict";
var Bounds = require('./Bounds');
var Marker = require('./Marker');
var Bounds = require('../Bounds');
var Marker = require('../Marker');
// noinspection JSUnusedLocalSymbols
var logger = require('../../logger');
var logger = require('../../../logger');
function GoogleMapsApiMarker(options) {
Marker.call(this, options);
......
"use strict";
var Polyline = require('./Polyline');
var Bounds = require('./Bounds');
var Polyline = require('../Polyline');
var Bounds = require('../Bounds');
// noinspection JSUnusedLocalSymbols
var logger = require('../../logger');
var logger = require('../../../logger');
function GoogleMapsApiPolyline(options) {
Polyline.call(this, options);
......
"use strict";
var Rectangle = require('./Rectangle');
var Bounds = require('./Bounds');
var Rectangle = require('../Rectangle');
var Bounds = require('../Bounds');
// noinspection JSUnusedLocalSymbols
var logger = require('../../logger');
var logger = require('../../../logger');
function GoogleMapsApiRectangle(options) {
Rectangle.call(this, options);
......
......@@ -13,7 +13,7 @@ var CommentDbOverlay = require("../../main/js/map/overlay/CommentDbOverlay");
var CustomMap = require("../../main/js/map/CustomMap");
var CustomMapOptions = require("../../main/js/map/CustomMapOptions");
var DrugDbOverlay = require("../../main/js/map/overlay/DrugDbOverlay");
var GoogleMapsApiCanvas = require('../../main/js/map/canvas/GoogleMapsApiCanvas');
var GoogleMapsApiCanvas = require('../../main/js/map/canvas/GoogleMaps/GoogleMapsApiCanvas');
var IdentifiedElement = require("../../main/js/map/data/IdentifiedElement");
var KineticLaw = require("../../main/js/map/data/KineticLaw");
var LayoutAlias = require("../../main/js/map/data/LayoutAlias");
......
......@@ -8,7 +8,7 @@ var AliasSurface = require('../../../main/js/map/surface/AliasSurface');
var AbstractCustomMap = require('../../../main/js/map/AbstractCustomMap');
var IdentifiedElement = require('../../../main/js/map/data/IdentifiedElement');
var Point = require('../../../main/js/map/canvas/Point');
var GoogleMapsApiCanvas = require('../../../main/js/map/canvas/GoogleMapsApiCanvas');
var GoogleMapsApiCanvas = require('../../../main/js/map/canvas/GoogleMaps/GoogleMapsApiCanvas');
var chai = require('chai');
......
......@@ -810,7 +810,8 @@ describe('CustomMap', function () {
var map = new CustomMap(options);
map.openSubmap(submodel.getId());
map.setCenter(new Point(10, 20));
var submap = map.getSubmapById(submodel.getId());
submap.setCenter(new Point(10, 20));
assert.ok(ServerConnector.getSessionData().getCenter(submodel));
map.destroy();
});
......
"use strict";
require("../../mocha-config");
require("../../../mocha-config");
// noinspection JSUnusedLocalSymbols
var logger = require('../../logger');
var logger = require('../../../logger');
var GoogleMapsApiCanvas = require('../../../../main/js/map/canvas/GoogleMapsApiCanvas');
var Point = require('../../../../main/js/map/canvas/Point');
var GoogleMapsApiCanvas = require('../../../../../main/js/map/canvas/GoogleMaps/GoogleMapsApiCanvas');
var Point = require('../../../../../main/js/map/canvas/Point');
var SelectionContextMenu = require('../../../../main/js/gui/SelectionContextMenu');
var SelectionContextMenu = require('../../../../../main/js/gui/SelectionContextMenu');
var chai = require('chai');
var assert = chai.assert;
......
"use strict";
require("../../mocha-config");
require("../../../mocha-config");
var logger = require('../../logger');
var logger = require('../../../logger');
var GoogleMapsApiInfoWindow = require('../../../../main/js/map/canvas/GoogleMapsApiInfoWindow');
var Point = require('../../../../main/js/map/canvas/Point');
var GoogleMapsApiInfoWindow = require('../../../../../main/js/map/canvas/GoogleMaps/GoogleMapsApiInfoWindow');
var Point = require('../../../../../main/js/map/canvas/Point');
var chai = require('chai');
var assert = chai.assert;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment