metamaps.debug function, and move VERSION into a rails constant initializer.

from this commit on, we would need to modify config/initializers/version.rb to increment the version number.
This commit is contained in:
Devin Howard 2016-04-06 10:27:31 +08:00
parent 8a6d434fc3
commit 2e6f04d0be
4 changed files with 11 additions and 2 deletions

View file

@ -0,0 +1,7 @@
Metamaps.Debug = function() {
console.debug(Metamaps)
console.debug(`Metamaps Version: ${Metamaps.VERSION}`)
}
Metamaps.debug = function() {
Metamaps.Debug()
}

View file

@ -16,11 +16,12 @@ var labelType, useGradients, nativeTextSupport, animate;
animate = !(iStuff || !nativeCanvasSupport); animate = !(iStuff || !nativeCanvasSupport);
})(); })();
// TODO eliminate these 4 top-level variables // TODO eliminate these 5 top-level variables
Metamaps.panningInt = null; Metamaps.panningInt = null;
Metamaps.tempNode = null; Metamaps.tempNode = null;
Metamaps.tempInit = false; Metamaps.tempInit = false;
Metamaps.tempNode2 = null; Metamaps.tempNode2 = null;
Metamaps.VERSION = '<%= VERSION %>'
Metamaps.Settings = { Metamaps.Settings = {
embed: false, // indicates that the app is on a page that is optimized for embedding in iFrames on other web pages embed: false, // indicates that the app is on a page that is optimized for embedding in iFrames on other web pages

View file

@ -18,7 +18,7 @@
<div id="rightAboutParms"> <div id="rightAboutParms">
<p>PRIVATE BETA</p> <p>PRIVATE BETA</p>
<p>2.8</p> <p><%= VERSION %></p>
<p>Mar 26, 2016</p> <p>Mar 26, 2016</p>
</div> </div>
<div class="clearfloat"> <div class="clearfloat">

View file

@ -0,0 +1 @@
VERSION = '2.8.3'