searchViz 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,3 +1,3 @@
1
1
  module SearchViz
2
- VERSION = "0.0.4"
2
+ VERSION = "0.0.5"
3
3
  end
@@ -1,35 +1,26 @@
1
1
  // Copyright (c) 2012 Fms-shintomon
2
2
 
3
- var AjaxGet, AjaxPut, searchViz, searchVizHistory, searchVizHash, searchVizCookie, hashUrlParse;
3
+ var AjaxGet, AjaxPut, searchViz, searchVizCookie, hashUrlParse;
4
4
 
5
- searchVizHistory = function(urlReplaceR) {
6
- return history.pushState(null, document.title, urlReplaceR);
7
- };
8
-
9
- searchVizHash = function(urlReplaceH) {
10
- window.location.hash = urlReplaceH;
11
- };
12
5
 
13
6
  searchVizHashRemove = function(urlReplaceH) {
14
- if (window.location.hash) {
15
7
  window.location.hash = '';
16
- }
17
8
  };
18
9
 
19
10
  searchVizCookie = function(urlReplaceR,urlReplaceH,opt) {
20
11
  try {
21
- if (opt='R') {
22
- searchVizHistory(urlReplaceR)
12
+ if (opt=='R') {
13
+ history.pushState(null, document.title, urlReplaceR);
23
14
  }
24
- else if (opt='H'){
25
- searchVizHash(urlReplaceH)
15
+ else if (opt=='H'){
16
+ window.location.hash = urlReplaceH;
26
17
  }
27
- else if (opt='B') {
18
+ else if (opt=='B') {
28
19
  try {
29
- searchVizHistory(urlReplaceR)
20
+ history.pushState(null, document.title, urlReplaceR);
30
21
  }
31
22
  catch(err){
32
- searchVizHash(urlReplaceH)
23
+ window.location.hash = urlReplaceH;
33
24
  }
34
25
  }
35
26
  else {
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: searchViz
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: