@@ -954,6 +954,17 @@ define('app/utils',[],function() {
954
954
return JSON.parse(JSON.stringify(obj));
955
955
}
956
956
957
+ // http://stackoverflow.com/questions/105034/create-guid-uuid-in-javascript
958
+ Utils.prototype.guid = function() {
959
+ function s4() {
960
+ return Math.floor((1 + Math.random()) * 0x10000)
961
+ .toString(16)
962
+ .substring(1);
963
+ }
964
+
965
+ return s4() + s4() + '-' + s4() + '-' + s4() + '-' + s4() + '-' + s4() + s4() + s4();
966
+ }
967
+
957
968
return new Utils();
958
969
});
959
970
/**
@@ -1129,7 +1140,7 @@ define('app/tabs',[
1129
1140
*/
1130
1141
1131
1142
define('app/config',{
1132
- version: "1.1.0 ",
1143
+ version: "1.1.1 ",
1133
1144
website: "http://pocket.gl",
1134
1145
1135
1146
brightAceTheme: "crimson_editor",
@@ -72851,18 +72862,22 @@ define('app/pocket.gl',[
72851
72862
PocketGL.prototype.addCopyright = function(domElement) {
72852
72863
if(this.params.copyright == "") return;
72853
72864
72865
+ var className = "pocketgl-copyright-";
72866
+ if(this.domContainer.id != "") className += this.domContainer.id;
72867
+ else className += Utils.guid();
72868
+
72854
72869
var copyright = document.createElement("div");
72855
72870
copyright.innerHTML = this.params.copyright;
72856
- copyright.className = " pocketgl-copyright pocketgl";
72871
+ copyright.className = className + " pocketgl-copyright pocketgl";
72857
72872
copyright.style.color = this.params.copyrightColor;
72858
72873
72859
72874
var style = document.createElement("style");
72860
72875
style.innerHTML = [
72861
- ".pocketgl-copyright a,",
72862
- ".pocketgl-copyright a:hover,",
72863
- ".pocketgl-copyright a:active,",
72864
- ".pocketgl-copyright a:visited,",
72865
- ".pocketgl-copyright a:focus { color: " + this.params.copyrightLinkColor + "; }"].join("\n");
72876
+ "." + className + " a,",
72877
+ "." + className + " a:hover,",
72878
+ "." + className + " a:active,",
72879
+ "." + className + " a:visited,",
72880
+ "." + className + " a:focus { color: " + this.params.copyrightLinkColor + "; }"].join("\n");
72866
72881
72867
72882
domElement.appendChild(copyright);
72868
72883
domElement.appendChild(style);
0 commit comments