gio2 3.1.3-x86-mingw32 → 3.1.4-x86-mingw32

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: d39d33c0bbef2a10b0c757ffbc229a5b85842124
4
- data.tar.gz: cbf8361d72e5b8f42262a9c21ff5c54bf479ae45
3
+ metadata.gz: a0153f01187a2b36bd6605112ff98b8de3e5c64e
4
+ data.tar.gz: 792078ecf2439ac49a981d54d5ec7a9ef4bf325e
5
5
  SHA512:
6
- metadata.gz: e98bf895fb0e0caf3391b94119ed37ffce5d6dc78cedc4289ae48d73c8da3dab3d833f7bc4a9570077fcba3672e87579c159ce8a95dd6d60cf21c7dd56e692d9
7
- data.tar.gz: 02257d4341f66a696cbfe629773e5a6f69f84909891394c9e120209876abee2c3e90637b3c7b329a134cfdbd9a1caf20b33cef08caead9dfc59108ea9f96c4ee
6
+ metadata.gz: 70ab0e0b2eb55d970b85022074af6297dace9d1de47e2541e2a228a209cfda1cb0bf10336cbcf59a950bacce619faf82c6782009482cb45b6bc5a20fa1fe2112
7
+ data.tar.gz: e8eec0105ef29f3cedc89ae8c8fb1d73a36a4c947e09c87f917966cfbf0a7ac8d6af717a60ade3a35dc39b637ab6a54a00a5ed6ec78a91e87603aa4d8a4613e9
Binary file
Binary file
Binary file
@@ -1,4 +1,4 @@
1
- # Copyright (C) 2013 Ruby-GNOME2 Project Team
1
+ # Copyright (C) 2013-2017 Ruby-GNOME2 Project Team
2
2
  #
3
3
  # This library is free software; you can redistribute it and/or
4
4
  # modify it under the terms of the GNU Lesser General Public
@@ -116,3 +116,23 @@ module GLib
116
116
  end
117
117
  end
118
118
 
119
+ module Gio
120
+ module File
121
+ extend GLib::Deprecatable
122
+
123
+ define_deprecated_singleton_method(:commandline_arg,
124
+ "open(arg: arg, cwd: cwd)") do |_self, arg, cwd=nil|
125
+ open(arg: arg, cwd: cwd)
126
+ end
127
+
128
+ define_deprecated_singleton_method(:path,
129
+ "open(path: path)") do |_self, path|
130
+ open(path: path)
131
+ end
132
+
133
+ define_deprecated_singleton_method(:uri,
134
+ "open(uri: uri)") do |_self, uri|
135
+ open(uri: uri)
136
+ end
137
+ end
138
+ end
@@ -1,4 +1,4 @@
1
- # Copyright (C) 2016 Ruby-GNOME2 Project Team
1
+ # Copyright (C) 2016-2017 Ruby-GNOME2 Project Team
2
2
  #
3
3
  # This library is free software; you can redistribute it and/or
4
4
  # modify it under the terms of the GNU Lesser General Public
@@ -17,12 +17,31 @@
17
17
  module Gio
18
18
  module File
19
19
  class << self
20
- alias_method :commandline_arg_raw, :commandline_arg
21
- def commandline_arg(arg, cwd=nil)
22
- if cwd
23
- commandline_arg_and_cwd(arg, cwd)
20
+ def open(options={})
21
+ arg = options[:arg]
22
+ cwd = options[:cwd]
23
+ path = options[:path]
24
+ uri = options[:uri]
25
+
26
+ if arg
27
+ if cwd
28
+ file = new_for_commandline_arg_and_cmd(arg, cwd)
29
+ else
30
+ file = new_for_commandline_arg(arg)
31
+ end
32
+ elsif path
33
+ file = new_for_path(path)
34
+ elsif uri
35
+ file = new_for_uri(uri)
36
+ else
37
+ message = "must specify :arg, :path or :uri: #{options.inspect}"
38
+ raise ArgumentError, message
39
+ end
40
+
41
+ if block_given?
42
+ yield(file)
24
43
  else
25
- commandline_arg_raw(arg)
44
+ file
26
45
  end
27
46
  end
28
47
  end
@@ -22,6 +22,7 @@ module Gio
22
22
  define_mime_type_class
23
23
  define_dbus_module
24
24
  define_resources_module
25
+ @file_function_infos = []
25
26
  @content_type_guess_for_tree_info = nil
26
27
  end
27
28
 
@@ -116,6 +117,8 @@ module Gio
116
117
  when /\Adbus_/
117
118
  name = rubyish_method_name(info, :prefix => "dbus_")
118
119
  define_singleton_method(@dbus_module, name, info)
120
+ when /\Afile_/
121
+ # Ignore because they are defined by load_interface_info
119
122
  else
120
123
  super
121
124
  end
@@ -172,15 +175,6 @@ module Gio
172
175
  end
173
176
  end
174
177
 
175
- def rubyish_method_name(info, options={})
176
- case info.name
177
- when /\Anew_(?:for_)?/
178
- $POSTMATCH
179
- else
180
- super
181
- end
182
- end
183
-
184
178
  def rubyish_class_name(info)
185
179
  case info.name
186
180
  when /Enum\z/
@@ -1,4 +1,4 @@
1
- # Copyright (C) 2013-2014 Ruby-GNOME2 Project Team
1
+ # Copyright (C) 2013-2017 Ruby-GNOME2 Project Team
2
2
  #
3
3
  # This library is free software; you can redistribute it and/or
4
4
  # modify it under the terms of the GNU Lesser General Public
@@ -19,7 +19,7 @@ class TestFileEnumerator < Test::Unit::TestCase
19
19
 
20
20
  def test_container
21
21
  path = File.dirname(__FILE__)
22
- dir = Gio::File.path(path)
22
+ dir = Gio::File.open(path: path)
23
23
  enumerator = dir.enumerate_children("*", :none)
24
24
  assert_equal(path, enumerator.container.path)
25
25
  end
@@ -1,4 +1,4 @@
1
- # Copyright (C) 2014 Ruby-GNOME2 Project Team
1
+ # Copyright (C) 2014-2017 Ruby-GNOME2 Project Team
2
2
  #
3
3
  # This library is free software; you can redistribute it and/or
4
4
  # modify it under the terms of the GNU Lesser General Public
@@ -22,7 +22,7 @@ class TestFile < Test::Unit::TestCase
22
22
  def test_guess_content_type
23
23
  omit_on_os_x
24
24
  path = fixture_path("content-type", "x-content", "unix-software")
25
- dir = Gio::File.path(path)
25
+ dir = Gio::File.open(path: path)
26
26
  assert_equal(["x-content/unix-software"],
27
27
  dir.guess_content_types.collect(&:to_s))
28
28
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gio2
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.3
4
+ version: 3.1.4
5
5
  platform: x86-mingw32
6
6
  authors:
7
7
  - The Ruby-GNOME2 Project Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-04-27 00:00:00.000000000 Z
11
+ date: 2017-05-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: glib2
@@ -16,28 +16,28 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 3.1.3
19
+ version: 3.1.4
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 3.1.3
26
+ version: 3.1.4
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: gobject-introspection
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 3.1.3
33
+ version: 3.1.4
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 3.1.3
40
+ version: 3.1.4
41
41
  description: Ruby/GIO2 is a Ruby binding of gio-2.x.
42
42
  email: ruby-gnome2-devel-en@lists.sourceforge.net
43
43
  executables: []