motion-settings-bundle 0.2.0 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 209ca125e2380375c9d232a463e225a56e86933b
4
+ data.tar.gz: e73a82b1710e37caf14476148f229be470a949cd
5
+ SHA512:
6
+ metadata.gz: 737a1868e82332653fb6dd62a4d4b7ddb3ef285bf23b4c5834bb45975d6951eea04e3dfdd225492e40a68ffd70c2dc26e942ecd861966a1e3bbc308008aa3ad1
7
+ data.tar.gz: ef5010a59e6118abd5b5cb43824979216e54575f424da21190a5ac42aa5d6d6ad643bab0081cfad9ff8598a7bae2208209070a4e9aa0107094700f42a2201f23
data/README.md CHANGED
@@ -35,6 +35,13 @@ Motion::SettingsBundle.setup do |app|
35
35
  # An on/off switch. Turn something on or off. Default is `false` (off).
36
36
  app.toggle "Kwisatz Haderach?", key: "superpowersEnabled", default: true
37
37
 
38
+ # MultiValue, to choose from some item
39
+ app.multivalue "Picture Resolution 1", key: "pictureResolution1", default: "1500", values: ["1500", "1200", "1000"]
40
+
41
+ # MultiValue 2, with values and different titles (required when the values are numbers not string)
42
+ app.multivalue "Picture Resolution 2", key: "pictureResolution2", default: 1500, values: [1500, 1200, 1000],
43
+ titles: ["1500px", "1200px", "1000px"]
44
+
38
45
  # A slider, configure volume or something linear
39
46
  app.slider "Spice Level", key: "spiceLevel", default: 50, min: 1, max: 100
40
47
 
@@ -22,6 +22,13 @@ module Motion
22
22
  preference(title, "PSTitleValueSpecifier", options)
23
23
  end
24
24
 
25
+ def multivalue(title, options = {})
26
+ preference(title, "PSMultiValueSpecifier", options, {
27
+ "Values" => options[:values],
28
+ "Titles" => options[:titles].nil? ? options[:values] : options[:titles]
29
+ })
30
+ end
31
+
25
32
  def toggle(title, options = {})
26
33
  preference(title, "PSToggleSwitchSpecifier", options, {
27
34
  "TrueValue" => true,
@@ -1,5 +1,5 @@
1
1
  module Motion
2
2
  module SettingsBundle
3
- VERSION = "0.2.0"
3
+ VERSION = "0.3.0"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,20 +1,18 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: motion-settings-bundle
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
5
- prerelease:
4
+ version: 0.3.0
6
5
  platform: ruby
7
6
  authors:
8
7
  - Nick Quaranto
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2013-03-18 00:00:00.000000000 Z
11
+ date: 2014-01-27 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: plist
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
17
  - - ~>
20
18
  - !ruby/object:Gem::Version
@@ -22,7 +20,6 @@ dependencies:
22
20
  type: :runtime
23
21
  prerelease: false
24
22
  version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
23
  requirements:
27
24
  - - ~>
28
25
  - !ruby/object:Gem::Version
@@ -30,17 +27,15 @@ dependencies:
30
27
  - !ruby/object:Gem::Dependency
31
28
  name: rake
32
29
  requirement: !ruby/object:Gem::Requirement
33
- none: false
34
30
  requirements:
35
- - - ! '>='
31
+ - - '>='
36
32
  - !ruby/object:Gem::Version
37
33
  version: '0'
38
34
  type: :development
39
35
  prerelease: false
40
36
  version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
37
  requirements:
43
- - - ! '>='
38
+ - - '>='
44
39
  - !ruby/object:Gem::Version
45
40
  version: '0'
46
41
  description: Create a Settings.bundle for your RubyMotion app. This allows your app
@@ -66,27 +61,26 @@ files:
66
61
  - screenshot3.png
67
62
  homepage: https://github.com/qrush/motion-settings-bundle
68
63
  licenses: []
64
+ metadata: {}
69
65
  post_install_message:
70
66
  rdoc_options: []
71
67
  require_paths:
72
68
  - lib
73
69
  required_ruby_version: !ruby/object:Gem::Requirement
74
- none: false
75
70
  requirements:
76
- - - ! '>='
71
+ - - '>='
77
72
  - !ruby/object:Gem::Version
78
73
  version: '0'
79
74
  required_rubygems_version: !ruby/object:Gem::Requirement
80
- none: false
81
75
  requirements:
82
- - - ! '>='
76
+ - - '>='
83
77
  - !ruby/object:Gem::Version
84
78
  version: '0'
85
79
  requirements: []
86
80
  rubyforge_project:
87
- rubygems_version: 1.8.23
81
+ rubygems_version: 2.2.1
88
82
  signing_key:
89
- specification_version: 3
83
+ specification_version: 4
90
84
  summary: Create a Settings.bundle for your RubyMotion app. This allows your app to
91
85
  have a "global" settings entry in the Settings app.
92
86
  test_files: []