ruby-dbus 0.13.0 → 0.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: be28e1bcc3ffa7c25f729d8915cd90344d565644
4
- data.tar.gz: 94eaa6d210ee9fed21c764c7d24d521ca98bf60f
3
+ metadata.gz: 95dfa24c76e4ed5aeb5997bd160a4efd69a8c146
4
+ data.tar.gz: 244e215c35cff67f53c7f7ac51a699c2fec22b2d
5
5
  SHA512:
6
- metadata.gz: 89bad1fc379f3e77d8758007e5d88664faa765bd6e1ef7d9638490e67b33a5411da8d90c151c9e8d263951d40d43520076f2c6d18aa27423eb92d7409c275667
7
- data.tar.gz: 9c24257d8db08279aeed560e050179d674397c0cdb93bba805f637afee70611edaa7373034aae2b8f69bf7466ea1936ea85a72dd1fe0182bfa02486bf57702a4
6
+ metadata.gz: f020e993e5a6777c7ea540cf1197200aa6f1c3c7003f331b42b73cea3d5937925243bf46d2668488e8854bb7ac34d88a20934a18e90a2bb46d9fca7bcb8de764
7
+ data.tar.gz: 160ebb98a13e02b982c7b634a02aa271b5899d54be289c9f5d71c0a2f8b9fcfc1190e4e19854a1a236a237f875cd108bad280a6bdbe571e68cb38afaad10b6b4
data/NEWS.md CHANGED
@@ -2,6 +2,16 @@
2
2
 
3
3
  ## Unreleased
4
4
 
5
+ ## Ruby D-Bus 0.14.0 - 2017-10-13
6
+
7
+ Bug fixes:
8
+ * Sending 16-bit signed integers ("n") did not work at all ([#68][]).
9
+
10
+ Requirements:
11
+ * Stopped supporting ruby 2.0.0, because of Nokogiri.
12
+
13
+ [#68]: https://github.com/mvidner/ruby-dbus/issues/68
14
+
5
15
  ## Ruby D-Bus 0.13.0 - 2016-09-21
6
16
 
7
17
  Bug fixes:
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.13.0
1
+ 0.14.0
@@ -133,8 +133,8 @@ module DBus
133
133
  align(2)
134
134
  packet = read(2).unpack(@uint16)[0]
135
135
  when Type::INT16
136
- align(4)
137
- packet = read(4).unpack(@uint16)[0]
136
+ align(2)
137
+ packet = read(2).unpack(@uint16)[0]
138
138
  if (packet & 0x8000) != 0
139
139
  packet -= 0x10000
140
140
  end
@@ -296,7 +296,7 @@ module DBus
296
296
  def append(type, val)
297
297
  raise TypeException, "Cannot send nil" if val.nil?
298
298
 
299
- type = type.chr if type.is_a?(Fixnum)
299
+ type = type.chr if type.is_a?(Integer)
300
300
  type = Type::Parser.new(type).parse[0] if type.is_a?(String)
301
301
  case type.sigtype
302
302
  when Type::BYTE
@@ -126,7 +126,7 @@ module DBus
126
126
 
127
127
  # Add a parameter _val_ of type _type_ to the message.
128
128
  def add_param(type, val)
129
- type = type.chr if type.is_a?(Fixnum)
129
+ type = type.chr if type.is_a?(Integer)
130
130
  @signature += type.to_s
131
131
  @params << [type, val]
132
132
  end
@@ -67,6 +67,10 @@ class Test < DBus::Object
67
67
  "あいうえお"
68
68
  end
69
69
 
70
+ dbus_method :i16_plus, "in a:n, in b:n, out result:n" do |a, b|
71
+ a + b
72
+ end
73
+
70
74
  dbus_signal :SomethingJustHappened, "toto:s, tutu:u"
71
75
  end
72
76
 
@@ -87,4 +87,8 @@ describe "ValueTest" do
87
87
  str = @obj.multibyte_string[0]
88
88
  expect(str).to eq("あいうえお")
89
89
  end
90
+
91
+ it "aligns short integers correctly" do
92
+ expect(@obj.i16_plus(10, -30)[0]).to eq(-20)
93
+ end
90
94
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-dbus
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.13.0
4
+ version: 0.14.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ruby DBus Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-09-21 00:00:00.000000000 Z
11
+ date: 2017-10-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: coveralls
@@ -192,9 +192,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
192
192
  version: '0'
193
193
  requirements: []
194
194
  rubyforge_project:
195
- rubygems_version: 2.2.2
195
+ rubygems_version: 2.2.5
196
196
  signing_key:
197
197
  specification_version: 4
198
198
  summary: Ruby module for interaction with D-Bus
199
199
  test_files: []
200
- has_rdoc: