redpotion 0.4.0 → 0.4.1

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: b0deea12cefd00811de29eb3d9ae59da6b0bca9b
4
- data.tar.gz: cbe219de2dcc3feac16fe920fa00bf89dd0125b7
3
+ metadata.gz: 055b57bb86182f1b3ff4bbe63a833b30a98fa2c4
4
+ data.tar.gz: 710534e68a7566a34589f817c3aebd72b91310ea
5
5
  SHA512:
6
- metadata.gz: 44f1b86f590eba11d47f3a25031b57104c6f57466641354d376bd1b7026107a0ea294adcfd9974a43ea0e8ce2eb31fe7f0c6d4a267c6d95c042528040e055ab2
7
- data.tar.gz: a8f733ae1ba00bf1d1d4ca5ae91539f6a4ea35d25ae835aaf7cccb2da0e0d7d78725e551f7bc8a37bdb7ae9d3ce9ae7a9e95f27424e05708d4e2cd2df85a1300
6
+ metadata.gz: d6bc042e08e0fdbfb10e18f0033a52c4309f7a85e7d4de4243a8f9a94b773f97cf81afb2d451a77fae8526890c2998426895c5f83d9946e64f7627299b1dbe14
7
+ data.tar.gz: b5905ea0cdcf66d84134d1f55df6d1ae07d23734af798112ae1d22fd95a816818fe1075a9feeca0dd60efe1fd941a620b78177570e66a5b01b686ac197b6a38d
@@ -1,8 +1,12 @@
1
1
  module ProMotion
2
2
  module ScreenModule
3
3
  def view_did_load
4
- self.rmq.stylesheet = self.class.rmq_style_sheet_class
5
- self.view.rmq.apply_style :root_view
4
+ if self.class.rmq_style_sheet_class.nil?
5
+ puts "[Redpotion Error] Stylesheet should be set in #{self.class}, ex: 'stylesheet #{self.class}Stylesheet'"
6
+ else
7
+ self.rmq.stylesheet = self.class.rmq_style_sheet_class
8
+ self.view.rmq.apply_style :root_view
9
+ end
6
10
 
7
11
  self.on_load
8
12
  end
@@ -66,7 +66,7 @@ class UIViewController
66
66
  end
67
67
  end
68
68
 
69
- class ProMotion::Screen
69
+ class ProMotion::ScreenModule
70
70
  def append(view_or_constant, style=nil, opts = {})
71
71
  view.append(view_or_constant, style, opts)
72
72
  end
@@ -1,3 +1,3 @@
1
1
  module RedPotion
2
- VERSION = "0.4.0"
2
+ VERSION = "0.4.1"
3
3
  end
data/lib/redpotion.rb CHANGED
@@ -6,8 +6,13 @@ end
6
6
 
7
7
  require 'ruby_motion_query'
8
8
  require 'ProMotion'
9
+ require 'motion_print'
9
10
 
10
11
  lib_dir_path = File.dirname(File.expand_path(__FILE__))
11
12
  Motion::Project::App.setup do |app|
12
- app.files.push(Dir.glob(File.join(lib_dir_path, "project/**/*.rb")))
13
+ insert_point = app.files.find_index { |file| file =~ /^(?:\.\/)?app\// } || 0
14
+
15
+ Dir.glob(File.join(lib_dir_path, "project/**/*.rb")).reverse.each do |file|
16
+ app.files.insert(insert_point, file)
17
+ end
13
18
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: redpotion
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - InfiniteRed
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-11-29 00:00:00.000000000 Z
12
+ date: 2014-12-02 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: ruby_motion_query