gir_ffi-gnome_keyring 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Changelog.md +6 -0
- data/lib/gir_ffi-gnome_keyring/attribute.rb +4 -0
- data/lib/gir_ffi-gnome_keyring.rb +12 -11
- data/test/unit/gir_ffi-gnome_keyring_test.rb +2 -2
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c3048f24273bbc8edba0c65169092ee6584d3f00
|
4
|
+
data.tar.gz: 87c50014c4c13b592112aedeab97f7354fbac557
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c12fc2555407e363f4318bca376abaa2bcdad645f50fcc4a16692049173ce1e023fe960c0e1b472cd537bed59f16b5ad5a0ec30d7781d378097e12adf4d1ee31
|
7
|
+
data.tar.gz: dc12b9fc5ddc5a40fc84968ac42716f3b19827f8af490dc3fb31aabf017655909e0a478beaa75ac7cc2ded55c3e9b7b337244d2abd0299419477833a34c00472
|
data/Changelog.md
CHANGED
@@ -21,36 +21,37 @@ module GnomeKeyring
|
|
21
21
|
|
22
22
|
def self.find_items_sync(type, attributes)
|
23
23
|
_v2 = GnomeKeyring::AttributeList.from(attributes)
|
24
|
-
_v3 =
|
24
|
+
_v3 = FFI::MemoryPointer.new :pointer
|
25
25
|
_v4 = GnomeKeyring::Lib.gnome_keyring_find_items_sync(type, _v2, _v3)
|
26
|
-
_v5 = GLib::List.wrap(GnomeKeyring::Found, _v3.
|
26
|
+
_v5 = GLib::List.wrap(GnomeKeyring::Found, _v3.get_pointer(0))
|
27
27
|
return [_v4, _v5]
|
28
28
|
end
|
29
29
|
|
30
30
|
def self.item_create_sync(keyring, type, display_name, attributes, secret,
|
31
31
|
update_if_exists)
|
32
|
-
_v1 = GirFFI::InPointer.
|
33
|
-
_v3 = GirFFI::InPointer.
|
32
|
+
_v1 = GirFFI::InPointer.from_utf8(keyring)
|
33
|
+
_v3 = GirFFI::InPointer.from_utf8(display_name)
|
34
34
|
_v4 = GnomeKeyring::AttributeList.from(attributes)
|
35
|
-
_v5 = GirFFI::InPointer.
|
36
|
-
_v7 =
|
35
|
+
_v5 = GirFFI::InPointer.from_utf8(secret)
|
36
|
+
_v7 = FFI::MemoryPointer.new :uint32
|
37
37
|
_v8 = GnomeKeyring::Lib.gnome_keyring_item_create_sync(_v1, type, _v3, _v4,
|
38
38
|
_v5,
|
39
39
|
update_if_exists,
|
40
40
|
_v7)
|
41
|
-
|
41
|
+
_v9 = _v7.get_uint32(0)
|
42
|
+
return [_v8, _v9]
|
42
43
|
end
|
43
44
|
|
44
45
|
def self.item_get_attributes_sync(keyring, id)
|
45
|
-
_v1 = GirFFI::InPointer.
|
46
|
-
_v3 =
|
46
|
+
_v1 = GirFFI::InPointer.from_utf8(keyring)
|
47
|
+
_v3 = FFI::MemoryPointer.new :pointer
|
47
48
|
_v4 = GnomeKeyring::Lib.gnome_keyring_item_get_attributes_sync(_v1, id, _v3)
|
48
|
-
attributes = GnomeKeyring::AttributeList.wrap(_v3.
|
49
|
+
attributes = GnomeKeyring::AttributeList.wrap(_v3.get_pointer(0))
|
49
50
|
return [_v4, attributes]
|
50
51
|
end
|
51
52
|
|
52
53
|
def self.item_set_attributes_sync(keyring, id, attributes)
|
53
|
-
_v1 = GirFFI::InPointer.
|
54
|
+
_v1 = GirFFI::InPointer.from_utf8(keyring)
|
54
55
|
_v3 = GnomeKeyring::AttributeList.from(attributes)
|
55
56
|
GnomeKeyring::Lib.gnome_keyring_item_set_attributes_sync(_v1, id, _v3)
|
56
57
|
end
|
@@ -6,7 +6,7 @@ describe GnomeKeyring do
|
|
6
6
|
body = lambda { |type, attrs, listptr|
|
7
7
|
type.must_equal :generic_secret
|
8
8
|
attrs.must_be_instance_of GnomeKeyring::AttributeList
|
9
|
-
listptr.must_be_instance_of
|
9
|
+
listptr.must_be_instance_of FFI::MemoryPointer
|
10
10
|
:ok
|
11
11
|
}
|
12
12
|
|
@@ -50,7 +50,7 @@ describe GnomeKeyring do
|
|
50
50
|
body = lambda { |keyring, id, attributes|
|
51
51
|
keyring.to_utf8.must_equal "foo"
|
52
52
|
id.must_equal 42
|
53
|
-
attributes.must_be_instance_of
|
53
|
+
attributes.must_be_instance_of FFI::MemoryPointer
|
54
54
|
:ok
|
55
55
|
}
|
56
56
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gir_ffi-gnome_keyring
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matijs van Zuijlen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-03-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: gir_ffi
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.
|
19
|
+
version: 0.10.0
|
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: 0.
|
26
|
+
version: 0.10.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: minitest
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -44,14 +44,14 @@ dependencies:
|
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: '
|
47
|
+
version: '11.1'
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: '
|
54
|
+
version: '11.1'
|
55
55
|
description: Bindings for GnomeKeyring generated by GirFFI, with overrides.
|
56
56
|
email:
|
57
57
|
- matijs@matijs.net
|
@@ -97,7 +97,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
97
97
|
version: '0'
|
98
98
|
requirements: []
|
99
99
|
rubyforge_project:
|
100
|
-
rubygems_version: 2.
|
100
|
+
rubygems_version: 2.5.1
|
101
101
|
signing_key:
|
102
102
|
specification_version: 4
|
103
103
|
summary: GirFFI-based binding to GnomeKeyring
|