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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f4714feeee40d31e051838d0941a30f052614916
4
- data.tar.gz: 5c10b83f7d8e424cfdb959f1dd528463c03e197b
3
+ metadata.gz: 88e525eb1dd7b9ee59824698a2c6aa06980dffe1
4
+ data.tar.gz: 195f460725ec0a9b54fb1e7e516f223d1934e4be
5
5
  SHA512:
6
- metadata.gz: 1f7ef7f8559ccadd538410036241a1619408c05474d84682e0cee775ca1b8b4597596df17540fb5bd8266246942ed9e4c84a232cc09d9c3b52931915c9b448df
7
- data.tar.gz: fcf250dbd5e2eedce5d37adf32719fe1b42f7527f92a2a7eaff8ccfe58bd45064c68695163a6c0b646a57e29c1f514814a7dd845a012d55b52d0e9363b6ddbc2
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('We lost the connection to the server. No refresh data will be available. Thanks, -the Foreign Office.')
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("We're connected to the server again. Refresh data will now be available. Thanks, -the Foreign Office.")
60
+ alert(this.reconnect_alert)
51
61
  }
52
62
  }
53
63
  });
@@ -1,3 +1,3 @@
1
1
  module ForeignOffice
2
- VERSION = "0.8.1"
2
+ VERSION = "0.9.0"
3
3
  end
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.8.1
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-06-10 00:00:00.000000000 Z
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.3
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