airake 0.2.2 → 0.2.3
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +6 -0
- data/Manifest.txt +1 -1
- data/app_generators/airake/airake_generator.rb +16 -17
- data/app_generators/browsair/USAGE +1 -1
- data/app_generators/browsair/browsair_generator.rb +17 -17
- data/app_generators/browsair/templates/README +11 -1
- data/app_generators/shared/application.mxml +3 -5
- data/bin/airake +1 -1
- data/bin/browsair +1 -1
- data/lib/airake/commands/adl.rb +1 -1
- data/lib/airake/commands/adt.rb +1 -1
- data/lib/airake/commands/amxmlc.rb +1 -1
- data/lib/airake/version.rb +1 -1
- data/test/test_browsair_generator.rb +1 -5
- metadata +3 -3
- /data/app_generators/{airake/templates → shared}/lib/corelib-08.30.2007.swc +0 -0
data/History.txt
CHANGED
data/Manifest.txt
CHANGED
@@ -7,7 +7,6 @@ Rakefile
|
|
7
7
|
app_generators/airake/USAGE
|
8
8
|
app_generators/airake/airake_generator.rb
|
9
9
|
app_generators/airake/templates/README
|
10
|
-
app_generators/airake/templates/lib/corelib-08.30.2007.swc
|
11
10
|
app_generators/browsair/USAGE
|
12
11
|
app_generators/browsair/browsair_generator.rb
|
13
12
|
app_generators/browsair/templates/README
|
@@ -16,6 +15,7 @@ app_generators/shared/application.mxml
|
|
16
15
|
app_generators/shared/descriptor.xml
|
17
16
|
app_generators/shared/icons/MouseRunnerDotComGraphicsLicense.txt
|
18
17
|
app_generators/shared/icons/Web.png
|
18
|
+
app_generators/shared/lib/corelib-08.30.2007.swc
|
19
19
|
app_generators/shared/lib/flexunit-08.30.2007.swc
|
20
20
|
app_generators/shared/test/Test-app.xml
|
21
21
|
app_generators/shared/test/Test.mxml
|
@@ -5,13 +5,15 @@ class AirakeGenerator < RubiGen::Base
|
|
5
5
|
def initialize(runtime_args, runtime_options = {})
|
6
6
|
super
|
7
7
|
usage if args.empty? || args.size < 1
|
8
|
-
@name = args.shift
|
9
|
-
@
|
10
|
-
@app_name = File.basename(@destination_root).gsub(/\s+/, "").camelize
|
8
|
+
@name = args.shift
|
9
|
+
@app_name = @name.gsub(/\s+/, "").camelize
|
11
10
|
@title = @name
|
12
11
|
@url = "http://airake.rubyforge.org/resources.html"
|
13
12
|
@description = "Put description here"
|
14
13
|
extract_options
|
14
|
+
|
15
|
+
@destination_root = File.expand_path(@name)
|
16
|
+
@source_root = File.join(File.dirname(__FILE__), "..", "shared")
|
15
17
|
end
|
16
18
|
|
17
19
|
def manifest
|
@@ -20,29 +22,26 @@ class AirakeGenerator < RubiGen::Base
|
|
20
22
|
m.directory ''
|
21
23
|
BASEDIRS.each { |path| m.directory path }
|
22
24
|
|
23
|
-
m.file "README", "README"
|
24
|
-
m.file "lib/corelib-08.30.2007.swc", "lib/corelib-08.30.2007.swc"
|
25
|
-
|
26
|
-
# Shared templates
|
27
|
-
shared_path = "../../shared"
|
25
|
+
m.file "../airake/templates/README", "README"
|
28
26
|
|
29
27
|
# Lib
|
30
|
-
m.file "
|
28
|
+
m.file "lib/flexunit-08.30.2007.swc", "lib/flexunit-08.30.2007.swc"
|
29
|
+
m.file "lib/corelib-08.30.2007.swc", "lib/corelib-08.30.2007.swc"
|
31
30
|
|
32
31
|
# Test
|
33
|
-
m.file "
|
34
|
-
m.file "
|
32
|
+
m.file "test/Test-app.xml", "test/Test-app.xml"
|
33
|
+
m.file "test/Test.mxml", "test/Test.mxml"
|
35
34
|
m.directory "test/suite"
|
36
|
-
m.file "
|
35
|
+
m.file "test/suite/AllTests.as", "test/suite/AllTests.as"
|
37
36
|
|
38
|
-
m.template "
|
39
|
-
m.template "
|
40
|
-
m.template "
|
37
|
+
m.template "Rakefile", "Rakefile"
|
38
|
+
m.template "descriptor.xml", "src/#{app_name}-app.xml"
|
39
|
+
m.template "application.mxml", "src/#{app_name}.mxml"
|
41
40
|
|
42
41
|
# Icons
|
43
42
|
m.directory "src/assets/app_icons"
|
44
|
-
m.file "
|
45
|
-
m.file "
|
43
|
+
m.file "icons/Web.png", "src/assets/app_icons/icon_128.png"
|
44
|
+
m.file "icons/MouseRunnerDotComGraphicsLicense.txt", "src/assets/app_icons/MouseRunnerDotComGraphicsLicense.txt"
|
46
45
|
|
47
46
|
end
|
48
47
|
end
|
@@ -5,14 +5,17 @@ class BrowsairGenerator < RubiGen::Base
|
|
5
5
|
def initialize(runtime_args, runtime_options = {})
|
6
6
|
super
|
7
7
|
usage if args.empty? || args.size < 2
|
8
|
-
@
|
9
|
-
@
|
10
|
-
@app_name =
|
8
|
+
@path = args.shift
|
9
|
+
@name = File.basename(@path)
|
10
|
+
@app_name = @name.gsub(/\s+/, "")
|
11
11
|
@url = args.shift
|
12
12
|
@title = "#{@name} - #{@url}"
|
13
13
|
@description = "AIR Browser for #{@url}"
|
14
14
|
@icon_src_path = File.expand_path(args.shift) unless args.empty?
|
15
15
|
extract_options
|
16
|
+
|
17
|
+
@destination_root = File.expand_path(@path)
|
18
|
+
@source_root = File.join(File.dirname(__FILE__), "..", "shared")
|
16
19
|
end
|
17
20
|
|
18
21
|
def manifest
|
@@ -21,31 +24,28 @@ class BrowsairGenerator < RubiGen::Base
|
|
21
24
|
m.directory ''
|
22
25
|
BASEDIRS.each { |path| m.directory path }
|
23
26
|
|
24
|
-
m.file "README", "README"
|
25
|
-
|
26
|
-
# Shared templates
|
27
|
-
shared_path = "../../shared"
|
27
|
+
m.file "../browsair/templates/README", "README"
|
28
28
|
|
29
29
|
# Lib
|
30
|
-
m.file "
|
30
|
+
m.file "lib/flexunit-08.30.2007.swc", "lib/flexunit-08.30.2007.swc"
|
31
31
|
|
32
32
|
# Test
|
33
|
-
m.file "
|
34
|
-
m.file "
|
33
|
+
m.file "test/Test-app.xml", "test/Test-app.xml"
|
34
|
+
m.file "test/Test.mxml", "test/Test.mxml"
|
35
35
|
m.directory "test/suite"
|
36
|
-
m.file "
|
36
|
+
m.file "test/suite/AllTests.as", "test/suite/AllTests.as"
|
37
37
|
|
38
38
|
# Basic
|
39
|
-
m.template "
|
40
|
-
m.template "
|
41
|
-
m.template "
|
39
|
+
m.template "Rakefile", "Rakefile"
|
40
|
+
m.template "descriptor.xml", "src/#{app_name}-app.xml"
|
41
|
+
m.template "application.mxml", "src/#{app_name}.mxml"
|
42
42
|
|
43
43
|
# Icons
|
44
44
|
m.directory "src/assets/app_icons"
|
45
45
|
|
46
46
|
if @icon_src_path.blank?
|
47
|
-
m.file "
|
48
|
-
m.file "
|
47
|
+
m.file "icons/Web.png", "src/assets/app_icons/icon_128.png"
|
48
|
+
m.file "icons/MouseRunnerDotComGraphicsLicense.txt", "src/assets/app_icons/MouseRunnerDotComGraphicsLicense.txt"
|
49
49
|
else
|
50
50
|
icon_dest_path = destination_path("src/assets/app_icons/icon_128.png")
|
51
51
|
FileUtils.cp(icon_src_path, icon_dest_path)
|
@@ -59,7 +59,7 @@ class BrowsairGenerator < RubiGen::Base
|
|
59
59
|
<<-EOS
|
60
60
|
Create an AIR browser for a specific URL.
|
61
61
|
|
62
|
-
USAGE: #{spec.name} [
|
62
|
+
USAGE: #{spec.name} [path/to/Project] [http://the.url] [path/to/icon_128.png (optional)]
|
63
63
|
EOS
|
64
64
|
end
|
65
65
|
|
@@ -1,23 +1,21 @@
|
|
1
1
|
<?xml version="1.0" encoding="utf-8"?>
|
2
2
|
<mx:WindowedApplication xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" showStatusBar="false">
|
3
3
|
|
4
|
-
<mx:VBox width="100%" height="100%" backgroundColor="#FFFFFF">
|
4
|
+
<mx:VBox width="100%" height="100%" backgroundColor="#FFFFFF" verticalGap="0">
|
5
5
|
|
6
6
|
<mx:HBox id="buttons" width="100%" paddingLeft="5" paddingTop="5"
|
7
7
|
borderColor="#CCCCCC" borderSides="bottom" borderThickness="2" borderStyle="solid">
|
8
8
|
|
9
9
|
<mx:Button label="Back" click="html.htmlControl.historyBack()" />
|
10
10
|
<mx:Button label="Forward" click="html.htmlControl.historyForward()" />
|
11
|
-
<mx:Button label="Home" click="html.location
|
12
|
-
<!-- <mx:Button label="Cancel" click="html.htmlControl.cancelLoad()" /> -->
|
13
|
-
<!-- <mx:Label text="{html.location}" width="100%" /> -->
|
11
|
+
<mx:Button label="Home" click="html.location='<%= url %>'" />
|
14
12
|
|
15
13
|
<mx:HBox width="100%" horizontalAlign="right" paddingBottom="5" paddingRight="5">
|
16
14
|
<mx:Button label="Hide" click="buttons.height = 0" />
|
17
15
|
</mx:HBox>
|
18
16
|
</mx:HBox>
|
19
17
|
|
20
|
-
<mx:VBox width="100%" height="100%"
|
18
|
+
<mx:VBox width="100%" height="100%">
|
21
19
|
<mx:HTML id="html" width="100%" height="100%" location="<%= url %>" />
|
22
20
|
</mx:VBox>
|
23
21
|
</mx:VBox>
|
data/bin/airake
CHANGED
data/bin/browsair
CHANGED
data/lib/airake/commands/adl.rb
CHANGED
data/lib/airake/commands/adt.rb
CHANGED
data/lib/airake/version.rb
CHANGED
@@ -3,12 +3,8 @@ require File.join(File.dirname(__FILE__), "test_generator_helper.rb")
|
|
3
3
|
class TestBrowsairGenerator < Test::Unit::TestCase
|
4
4
|
include RubiGen::GeneratorTestHelper
|
5
5
|
|
6
|
-
attr_reader :app_name, :url
|
7
|
-
|
8
6
|
def setup
|
9
7
|
bare_setup
|
10
|
-
@app_name = "GReader"
|
11
|
-
@url = "http://reader.google.com"
|
12
8
|
end
|
13
9
|
|
14
10
|
def teardown
|
@@ -30,7 +26,7 @@ class TestBrowsairGenerator < Test::Unit::TestCase
|
|
30
26
|
# bare_teardown - place this in teardown method to destroy the TMP_ROOT or APP_ROOT folder after each test
|
31
27
|
|
32
28
|
def test_generator_with_options
|
33
|
-
run_generator('browsair', [ APP_ROOT,
|
29
|
+
run_generator('browsair', [ APP_ROOT, "http://reader.google.com" ], sources)
|
34
30
|
assert_generated_file "Rakefile"
|
35
31
|
assert_generated_file "README"
|
36
32
|
assert_directory_exists "bin"
|
metadata
CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.9.4
|
|
3
3
|
specification_version: 1
|
4
4
|
name: airake
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 0.2.
|
7
|
-
date: 2007-10-
|
6
|
+
version: 0.2.3
|
7
|
+
date: 2007-10-12 00:00:00 -04:00
|
8
8
|
summary: Adobe AIR generators and tasks
|
9
9
|
require_paths:
|
10
10
|
- lib
|
@@ -38,7 +38,6 @@ files:
|
|
38
38
|
- app_generators/airake/USAGE
|
39
39
|
- app_generators/airake/airake_generator.rb
|
40
40
|
- app_generators/airake/templates/README
|
41
|
-
- app_generators/airake/templates/lib/corelib-08.30.2007.swc
|
42
41
|
- app_generators/browsair/USAGE
|
43
42
|
- app_generators/browsair/browsair_generator.rb
|
44
43
|
- app_generators/browsair/templates/README
|
@@ -47,6 +46,7 @@ files:
|
|
47
46
|
- app_generators/shared/descriptor.xml
|
48
47
|
- app_generators/shared/icons/MouseRunnerDotComGraphicsLicense.txt
|
49
48
|
- app_generators/shared/icons/Web.png
|
49
|
+
- app_generators/shared/lib/corelib-08.30.2007.swc
|
50
50
|
- app_generators/shared/lib/flexunit-08.30.2007.swc
|
51
51
|
- app_generators/shared/test/Test-app.xml
|
52
52
|
- app_generators/shared/test/Test.mxml
|
File without changes
|