| Index: chrome/utility/media_galleries/picasa_album_table_reader.cc
|
| diff --git a/chrome/utility/media_galleries/picasa_album_table_reader.cc b/chrome/utility/media_galleries/picasa_album_table_reader.cc
|
| index ac5fc67cbe50614ab5ebb4828265185ea8c072dd..d6e2cc3667a562575836a2723dbbef684ec2bf31 100644
|
| --- a/chrome/utility/media_galleries/picasa_album_table_reader.cc
|
| +++ b/chrome/utility/media_galleries/picasa_album_table_reader.cc
|
| @@ -89,31 +89,23 @@ bool PicasaAlbumTableReader::Init() {
|
|
|
| base::Time timestamp = TimeFromMicrosoftVariantTime(date);
|
|
|
| - switch (category) {
|
| - case kAlbumCategoryAlbum: {
|
| - std::string token;
|
| - if (!token_column.ReadString(i, &token) || token.empty() ||
|
| - !StartsWithASCII(token, kAlbumTokenPrefix, false)) {
|
| - continue;
|
| - }
|
| -
|
| - albums_.push_back(AlbumInfo(name, timestamp, uid, base::FilePath()));
|
| - break;
|
| + if (category == kAlbumCategoryAlbum) {
|
| + std::string token;
|
| + if (!token_column.ReadString(i, &token) || token.empty() ||
|
| + !StartsWithASCII(token, kAlbumTokenPrefix, false)) {
|
| + continue;
|
| }
|
| - case kAlbumCategoryFolder: {
|
| - std::string filename;
|
| - if (!filename_column.ReadString(i, &filename) || filename.empty())
|
| - continue;
|
|
|
| - base::FilePath path =
|
| - base::FilePath(base::FilePath::FromUTF8Unsafe(filename));
|
| + albums_.push_back(AlbumInfo(name, timestamp, uid, base::FilePath()));
|
| + } else if (category == kAlbumCategoryFolder) {
|
| + std::string filename;
|
| + if (!filename_column.ReadString(i, &filename) || filename.empty())
|
| + continue;
|
|
|
| - folders_.push_back(AlbumInfo(name, timestamp, uid, path));
|
| - break;
|
| - }
|
| - default: {
|
| - break;
|
| - }
|
| + base::FilePath path =
|
| + base::FilePath(base::FilePath::FromUTF8Unsafe(filename));
|
| +
|
| + folders_.push_back(AlbumInfo(name, timestamp, uid, path));
|
| }
|
| }
|
|
|
|
|