sharp_office_bruce 1.0.1 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/sharp_office/office.rb +4 -3
- data/lib/sharp_office/version.rb +1 -1
- metadata +2 -2
data/lib/sharp_office/office.rb
CHANGED
@@ -8,6 +8,7 @@ module SharpOffice
|
|
8
8
|
include Singleton
|
9
9
|
|
10
10
|
def start(path, options)
|
11
|
+
@options = options
|
11
12
|
@path = File.expand_path(path)
|
12
13
|
|
13
14
|
system_or_exit(convert_to_pdf) unless options[:ignore_pdf]
|
@@ -39,7 +40,7 @@ module SharpOffice
|
|
39
40
|
end
|
40
41
|
|
41
42
|
def pdf_path
|
42
|
-
if options[:ignore_pdf]
|
43
|
+
if @options[:ignore_pdf]
|
43
44
|
return @path if @path.end_with?('pdf')
|
44
45
|
end
|
45
46
|
@path.gsub('.', '-').to_s+'.pdf'
|
@@ -47,12 +48,12 @@ module SharpOffice
|
|
47
48
|
end
|
48
49
|
|
49
50
|
def cover_path
|
50
|
-
return '' if options[:ignore_cover]
|
51
|
+
return '' if @options[:ignore_cover]
|
51
52
|
@path.gsub('.', '-').to_s+'.png'
|
52
53
|
end
|
53
54
|
|
54
55
|
def swf_path
|
55
|
-
return '' if options[:ignore_swf]
|
56
|
+
return '' if @options[:ignore_swf]
|
56
57
|
@path.gsub('.', '-').to_s+'.swf'
|
57
58
|
end
|
58
59
|
|
data/lib/sharp_office/version.rb
CHANGED