ruby-qt6-qtdbus 2.0.0 → 2.1.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
  SHA256:
3
- metadata.gz: 7e9dc5407c193ea060c1980323498c0e9561fd132dc230706ddb6df6e81a94da
4
- data.tar.gz: df2917ac0993e1bc17cdca2546d71019910d046661e9f2d81da4e4cb5193f1b7
3
+ metadata.gz: 3414aa8397d8fbaa8cce955436d681a1d8d8bd21e181f8f240c94634f58a0176
4
+ data.tar.gz: 31e16bafd846d404ca27eb7f62526886db7417f90a14c8b1f6ca22ac67e559a6
5
5
  SHA512:
6
- metadata.gz: c876941d1e18cb93a578f89f411d92052ed58605cd49b885b2778e12e742ca3f7d78fdcd398cb089a51e8cff3904d58cd6599a6733d05d8e91bac29baf416f93
7
- data.tar.gz: f4d412676ab754057a7e15bd86748a4eeb29593b057fcff6041e0b52dde3d6a58d347d48af18dc2c067d62a1e71ca8d1f5431e9ad51d204b4f9418950f50f6e7
6
+ metadata.gz: e1daef53964e33c6f29d3987225cb69f0147ac6c916e6b43562da9df8cc8f08f4b22cd2da3368c8aafff108dd75ec0d0d0a0debdf5afb49233c6cfaf0fc005a7
7
+ data.tar.gz: 6b199a8a13f9dff988f9bbc057da350fa93c08810278aabe46124943324bc4edb390fc1d27b2e1b30f43a7cda4e1efd3bef5c397a5d7d26903c1595cc3117b9f
@@ -26,7 +26,7 @@ module RubyQt6
26
26
 
27
27
  # @!visibility private
28
28
  def call(*args)
29
- mode = args_nth_delete_callmode(args, 0) || QtDBus::QDBus::AutoDetect
29
+ mode = args_nth_delete_callmode(args, 0) || QDBus::AutoDetect
30
30
  method = args.delete_at(0)
31
31
  call_with_argument_list(mode, T.to_qstr(method), T.to_qvariantlist(args))
32
32
  end
@@ -34,7 +34,7 @@ module RubyQt6
34
34
  private
35
35
 
36
36
  def args_nth_delete_callmode(args, index)
37
- return unless args[index].is_a?(QtDBus::QDBus::CallMode)
37
+ return unless args[index].is_a?(QDBus::CallMode)
38
38
  args.delete_at(index)
39
39
  end
40
40
  end
@@ -28,7 +28,7 @@ module RubyQt6
28
28
 
29
29
  # @!visibility private
30
30
  def register_object(*args)
31
- options = args_nth_delete_registeroptions(args, -1) || QtDBus::QDBusConnection::ExportAdaptors
31
+ options = args_nth_delete_registeroptions(args, -1) || QDBusConnection::ExportAdaptors
32
32
  case args.size
33
33
  when 2 then _register_object(T.to_qstr(args[-2]), args[-1], T.to_qflags(options))
34
34
  when 3 then _register_object(T.to_qstr(args[-3]), T.to_qstr(args[-2]), args[-1], T.to_qflags(options))
@@ -44,7 +44,7 @@ module RubyQt6
44
44
  private
45
45
 
46
46
  def args_nth_delete_registeroptions(args, index)
47
- return unless args[index].is_a?(QtDBus::QDBusConnection::RegisterOption) || args[index].is_a?(QtDBus::QDBusConnection::RegisterOptions)
47
+ return unless args[index].is_a?(QDBusConnection::RegisterOption) || args[index].is_a?(QDBusConnection::RegisterOptions)
48
48
  args.delete_at(index)
49
49
  end
50
50
  end
@@ -18,7 +18,7 @@ module RubyQt6
18
18
  # @param parent [QObject]
19
19
  # @return [QDBusInterface]
20
20
  def initialize(service, path, interface = "", connection = nil, parent = nil)
21
- connection ||= QtDBus::QDBusConnection.session_bus
21
+ connection ||= QDBusConnection.session_bus
22
22
  _initialize(T.to_qstr(service), T.to_qstr(path), T.to_qstr(interface), connection, parent)
23
23
  _take_ownership_from_ruby(self)
24
24
  end
@@ -13,15 +13,15 @@ module RubyQt6
13
13
  # @param message [QDBusMessage]
14
14
  # @return [QDBusReply]
15
15
  def initialize(message)
16
- @error = QtDBus::QDBusError.new(message)
16
+ @error = QDBusError.new(message)
17
17
  if @error.valid?
18
- @data = QtCore::QVariant.new("")
18
+ @data = QVariant.new("")
19
19
  return
20
20
  end
21
21
 
22
22
  if message.arguments.size < 1
23
- @error = QtDBus::QDBusError.new(QtDBus::QDBusError::ErrorType::InvalidSignature, "Unexpected reply signature")
24
- @data = QtCore::QVariant.new("")
23
+ @error = QDBusError.new(QDBusError::ErrorType::InvalidSignature, "Unexpected reply signature")
24
+ @data = QVariant.new("")
25
25
  return
26
26
  end
27
27
 
@@ -5,7 +5,12 @@ module RubyQt6
5
5
  # @see https://doc.qt.io/qt-6/qdbusvariant.html
6
6
  class QDBusVariant
7
7
  # @!parse
8
- QtCore::QVariant.register(_qvariant_register_metatype, method(:_qvariant_from_value), method(:_qvariant_to_value), from: self)
8
+ QVariant.register(
9
+ _qvariant_register_metatype,
10
+ method(:_qvariant_from_value),
11
+ method(:_qvariant_to_value),
12
+ from: self
13
+ )
9
14
 
10
15
  # @!visibility private
11
16
  alias_method :_initialize, :initialize
@@ -13,7 +18,7 @@ module RubyQt6
13
18
  # @param variant [QVariant]
14
19
  # @return [QDBusVariant]
15
20
  def initialize(variant)
16
- variant = variant.is_a?(QtCore::QVariant) ? variant : QtCore::QVariant.new(variant)
21
+ variant = variant.is_a?(QVariant) ? variant : QVariant.new(variant)
17
22
  _initialize(variant)
18
23
  end
19
24
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module RubyQt6
4
4
  module QtDBus
5
- QTDBUS_RUBYGEM_VERSION = "2.0.0"
5
+ QTDBUS_RUBYGEM_VERSION = "2.1.0"
6
6
  end
7
7
  end
data/lib/qt6/qtdbus.rb CHANGED
@@ -21,3 +21,5 @@ require_relative "qtdbus/qdbusservicewatcher"
21
21
 
22
22
  require_relative "bando/qdbusabstractadaptor"
23
23
  require_relative "bando/qdbusabstractinterface"
24
+
25
+ RubyQt6.initialize!(RubyQt6::QtDBus)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-qt6-qtdbus
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - John Doe
@@ -15,28 +15,28 @@ dependencies:
15
15
  requirements:
16
16
  - - '='
17
17
  - !ruby/object:Gem::Version
18
- version: 2.0.0
18
+ version: 2.1.0
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
23
  - - '='
24
24
  - !ruby/object:Gem::Version
25
- version: 2.0.0
25
+ version: 2.1.0
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: ruby-qt6-qtcore
28
28
  requirement: !ruby/object:Gem::Requirement
29
29
  requirements:
30
30
  - - "~>"
31
31
  - !ruby/object:Gem::Version
32
- version: 2.0.0
32
+ version: 2.1.0
33
33
  type: :runtime
34
34
  prerelease: false
35
35
  version_requirements: !ruby/object:Gem::Requirement
36
36
  requirements:
37
37
  - - "~>"
38
38
  - !ruby/object:Gem::Version
39
- version: 2.0.0
39
+ version: 2.1.0
40
40
  description: Ruby Bindings for Qt D-Bus.
41
41
  email:
42
42
  - johndoe@example.com