foreign_office 0.8.1 → 0.9.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/javascripts/foreign_office.js +12 -2
- data/lib/foreign_office/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 88e525eb1dd7b9ee59824698a2c6aa06980dffe1
|
4
|
+
data.tar.gz: 195f460725ec0a9b54fb1e7e516f223d1934e4be
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 35b1d5a2eef2737e7a73096c32b14160b1c4cee6c4e9a0703cda8c39e44a8c172dd32887cc86d70f6dd4c9e140fdff833adc9f784a9da6001452f90fdbad34a0
|
7
|
+
data.tar.gz: 468f227c9c097def3806a8efb5e01e6d5e20dcda1c5a66d5b165953272c9b7649ae66cb28b73ea5929b3e3724431918f306e1df4bed9d700f287ff56d6626a89
|
@@ -17,6 +17,16 @@ var ForeignOffice = Class.extend({
|
|
17
17
|
bus_class = TestBus
|
18
18
|
}
|
19
19
|
this.bus = new bus_class(config);
|
20
|
+
if(typeof config.disconnect_alert != 'undefined'){
|
21
|
+
this.disconnect_alert = config.disconnect_alert
|
22
|
+
} else {
|
23
|
+
this.disconnect_alert = 'We lost the connection to the server. No refresh data will be available. Thanks, -the Foreign Office.'
|
24
|
+
}
|
25
|
+
if(typeof config.reconnect_alert != 'undefined'){
|
26
|
+
this.reconnect_alert = config.reconnect_alert
|
27
|
+
} else {
|
28
|
+
this.reconnect_alert = "We're connected to the server again. Refresh data will now be available. Thanks, -the Foreign Office."
|
29
|
+
}
|
20
30
|
},
|
21
31
|
addListener: function($listener){
|
22
32
|
var listener_class = eval(getSubClass($listener.data('listener'),'ForeignOfficeListener'));
|
@@ -41,13 +51,13 @@ var ForeignOffice = Class.extend({
|
|
41
51
|
disconnection: function(){
|
42
52
|
if('connected' == this.connection_status){
|
43
53
|
this.connection_status = 'disconnected'
|
44
|
-
alert(
|
54
|
+
alert(this.disconnect_alert)
|
45
55
|
}
|
46
56
|
},
|
47
57
|
reconnection: function(){
|
48
58
|
if('disconnected' == this.connection_status){
|
49
59
|
this.connection_status = 'connected'
|
50
|
-
alert(
|
60
|
+
alert(this.reconnect_alert)
|
51
61
|
}
|
52
62
|
}
|
53
63
|
});
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: foreign_office
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.9.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Eric Draut
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-
|
12
|
+
date: 2015-07-02 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
@@ -150,7 +150,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
150
150
|
version: '0'
|
151
151
|
requirements: []
|
152
152
|
rubyforge_project:
|
153
|
-
rubygems_version: 2.4.
|
153
|
+
rubygems_version: 2.4.6
|
154
154
|
signing_key:
|
155
155
|
specification_version: 4
|
156
156
|
summary: A light framework that provides functionality for listeners on web clients
|