eyeballs 0.5.7 → 0.5.7.1

Sign up to get free protection for your applications and to get access to all the features.
data/CHANGELOG CHANGED
@@ -2,6 +2,7 @@ Fri Aug 6
2
2
  - - - - -
3
3
  - Add support for passing params from the URL to the controller
4
4
  - Add proper callbacks and reading a response to .find
5
+ - Fire the routing if the hash isn't blank on page load
5
6
 
6
7
  Sun Aug 1
7
8
  - - - - -
data/Rakefile CHANGED
@@ -27,7 +27,7 @@ begin
27
27
  require 'jeweler'
28
28
  Jeweler::Tasks.new do |s|
29
29
  s.name = "eyeballs"
30
- s.version = "0.5.7"
30
+ s.version = "0.5.7.1"
31
31
  s.author = "Paul Campbell"
32
32
  s.email = "paul@rslw.com"
33
33
  s.homepage = "http://www.github.com/paulca/eyeballs.js"
data/eyeballs.gemspec CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{eyeballs}
8
- s.version = "0.5.7"
8
+ s.version = "0.5.7.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Paul Campbell"]
@@ -60,9 +60,10 @@ o_O.routes = {
60
60
  {
61
61
  o_O.routes.rules['root'].action();
62
62
  }
63
+
63
64
  }
64
65
 
65
- $(window).bind( 'hashchange', function(){
66
+ var route_on_hash = function(){
66
67
  var hash = location.hash.replace(/^(#)/, '').o_O_trim('/');
67
68
  if(o_O.routes.urls.indexOf(hash) >= 0)
68
69
  {
@@ -93,7 +94,9 @@ o_O.routes = {
93
94
  }
94
95
  }
95
96
  }
96
- });
97
+ }
98
+
99
+ $(window).bind( 'hashchange', route_on_hash);
97
100
 
98
101
  $('a').live('click', function(){
99
102
  if($(this).is('a[data-ajax-history=true]'))
@@ -102,6 +105,11 @@ o_O.routes = {
102
105
  return false;
103
106
  }
104
107
  });
105
- })
108
+
109
+ if(location.hash != '')
110
+ {
111
+ route_on_hash();
112
+ }
113
+ })
106
114
  }
107
115
  }
metadata CHANGED
@@ -1,13 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: eyeballs
3
3
  version: !ruby/object:Gem::Version
4
- hash: 5
4
+ hash: 121
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 5
9
9
  - 7
10
- version: 0.5.7
10
+ - 1
11
+ version: 0.5.7.1
11
12
  platform: ruby
12
13
  authors:
13
14
  - Paul Campbell