picasa 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.rdoc +2 -1
- data/VERSION.yml +1 -1
- data/lib/picasa/web_albums.rb +2 -1
- data/picasa.gemspec +1 -1
- data/test/web_albums_test.rb +1 -0
- metadata +1 -1
data/README.rdoc
CHANGED
@@ -14,7 +14,8 @@ In RAILS_ROOT/config/environment.rb
|
|
14
14
|
== Usage
|
15
15
|
|
16
16
|
Picasa.albums(:google_user => 'google_username')
|
17
|
-
#=> [ {:id => "666", :title => "satan-album", :photos_count => 6, :photo => "url",
|
17
|
+
#=> [ {:id => "666", :title => "satan-album", :photos_count => 6, :photo => "url",
|
18
|
+
# :thumbnail => "url", :slideshow => "url"},
|
18
19
|
# {another one} ]
|
19
20
|
|
20
21
|
Picasa.photos(:google_user => 'google_username', :album_id => 'album_id')
|
data/VERSION.yml
CHANGED
data/lib/picasa/web_albums.rb
CHANGED
@@ -16,6 +16,7 @@ module Picasa
|
|
16
16
|
attributes[:photos_count] = album['numphotos'][0].to_i
|
17
17
|
attributes[:photo] = album['group'][0]['content']['url']
|
18
18
|
attributes[:thumbnail] = album['group'][0]['thumbnail'][0]['url']
|
19
|
+
attributes[:slideshow] = album['link'][1]['href'] + "#slideshow"
|
19
20
|
albums << attributes
|
20
21
|
end if xml['entry']
|
21
22
|
albums
|
@@ -35,7 +36,7 @@ module Picasa
|
|
35
36
|
attributes[:photo] = photo['content']['src']
|
36
37
|
photos << attributes
|
37
38
|
end if xml['entry']
|
38
|
-
{ :photos => photos, :slideshow => xml['link'][
|
39
|
+
{ :photos => photos, :slideshow => xml['link'][1]['href'] + "#slideshow" }
|
39
40
|
end
|
40
41
|
|
41
42
|
private
|
data/picasa.gemspec
CHANGED
data/test/web_albums_test.rb
CHANGED
@@ -12,6 +12,7 @@ class WebAlbumsTest < Test::Unit::TestCase
|
|
12
12
|
assert_equal "5277503612406515713", albums.first[:id]
|
13
13
|
assert_not_nil albums.first[:photo]
|
14
14
|
assert_not_nil albums.first[:thumbnail]
|
15
|
+
assert_not_nil albums.first[:slideshow]
|
15
16
|
end
|
16
17
|
|
17
18
|
test 'Should parse photos page' do
|