diff options
author | tommycli <tommycli@chromium.org> | 2016-03-18 11:52:29 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-03-18 18:53:39 +0000 |
commit | a239a382db30c140c83b8eba6a875718183dc77a (patch) | |
tree | c456daadb4e35ec170011014411ae60861701afe /chrome/common | |
parent | 02158c8c190ae32d55ae64074bd8068bd17a0812 (diff) | |
download | chromium_src-a239a382db30c140c83b8eba6a875718183dc77a.zip chromium_src-a239a382db30c140c83b8eba6a875718183dc77a.tar.gz chromium_src-a239a382db30c140c83b8eba6a875718183dc77a.tar.bz2 |
Media Galleries Partial Deprecation: Remove iPhoto support.
Axes about 2900 SLOC and iPhoto support. Affects Mac OSX only.
BUG=542912
Review URL: https://codereview.chromium.org/1805203002
Cr-Commit-Position: refs/heads/master@{#382034}
Diffstat (limited to 'chrome/common')
-rw-r--r-- | chrome/common/BUILD.gn | 2 | ||||
-rw-r--r-- | chrome/common/extensions/chrome_utility_extensions_messages.h | 29 | ||||
-rw-r--r-- | chrome/common/extensions/docs/templates/intros/mediaGalleries.html | 17 | ||||
-rw-r--r-- | chrome/common/media_galleries/iphoto_library.cc | 34 | ||||
-rw-r--r-- | chrome/common/media_galleries/iphoto_library.h | 49 |
5 files changed, 1 insertions, 130 deletions
diff --git a/chrome/common/BUILD.gn b/chrome/common/BUILD.gn index c156b3a..d1cc2cd 100644 --- a/chrome/common/BUILD.gn +++ b/chrome/common/BUILD.gn @@ -188,8 +188,6 @@ static_library("common") { public_deps += [ "//third_party/boringssl" ] } if (is_mac) { - sources += - rebase_path(gypi_values.chrome_common_mac_sources, ".", "//chrome") public_deps += [ ":app_mode_app_support" ] } if (is_chromeos) { diff --git a/chrome/common/extensions/chrome_utility_extensions_messages.h b/chrome/common/extensions/chrome_utility_extensions_messages.h index ea3920fd..776f9e5 100644 --- a/chrome/common/extensions/chrome_utility_extensions_messages.h +++ b/chrome/common/extensions/chrome_utility_extensions_messages.h @@ -11,7 +11,6 @@ #include "base/files/file_path.h" #include "build/build_config.h" -#include "chrome/common/media_galleries/iphoto_library.h" #include "chrome/common/media_galleries/itunes_library.h" #include "chrome/common/media_galleries/metadata_types.h" #include "chrome/common/media_galleries/picasa_types.h" @@ -24,19 +23,6 @@ #define IPC_MESSAGE_START ChromeUtilityExtensionsMsgStart -#if defined(OS_MACOSX) -IPC_STRUCT_TRAITS_BEGIN(iphoto::parser::Photo) - IPC_STRUCT_TRAITS_MEMBER(id) - IPC_STRUCT_TRAITS_MEMBER(location) - IPC_STRUCT_TRAITS_MEMBER(original_location) -IPC_STRUCT_TRAITS_END() - -IPC_STRUCT_TRAITS_BEGIN(iphoto::parser::Library) - IPC_STRUCT_TRAITS_MEMBER(albums) - IPC_STRUCT_TRAITS_MEMBER(all_photos) -IPC_STRUCT_TRAITS_END() -#endif // defined(OS_MACOSX) - #if defined(OS_WIN) || defined(OS_MACOSX) IPC_STRUCT_TRAITS_BEGIN(itunes::parser::Track) IPC_STRUCT_TRAITS_MEMBER(id) @@ -85,13 +71,6 @@ IPC_MESSAGE_CONTROL1(ChromeUtilityMsg_ParseITunesPrefXml, std::string /* XML to parse */) #endif // defined(OS_WIN) -#if defined(OS_MACOSX) -// Tell the utility process to parse the iPhoto library XML file and -// return the parse result as well as the iPhoto library as an iphoto::Library. -IPC_MESSAGE_CONTROL1(ChromeUtilityMsg_ParseIPhotoLibraryXmlFile, - IPC::PlatformFileForTransit /* XML file to parse */) -#endif // defined(OS_MACOSX) - #if defined(OS_WIN) || defined(OS_MACOSX) // Tell the utility process to parse the iTunes library XML file and // return the parse result as well as the iTunes library as an itunes::Library. @@ -155,14 +134,6 @@ IPC_MESSAGE_CONTROL1(ChromeUtilityHostMsg_GotITunesDirectory, base::FilePath /* Path to iTunes library */) #endif // defined(OS_WIN) -#if defined(OS_MACOSX) -// Reply after parsing the iPhoto library XML file with the parser result and -// an iphoto::Library data structure. -IPC_MESSAGE_CONTROL2(ChromeUtilityHostMsg_GotIPhotoLibrary, - bool /* Parser result */, - iphoto::parser::Library /* iPhoto library */) -#endif // defined(OS_MACOSX) - #if defined(OS_WIN) || defined(OS_MACOSX) // Reply after parsing the iTunes library XML file with the parser result and // an itunes::Library data structure. diff --git a/chrome/common/extensions/docs/templates/intros/mediaGalleries.html b/chrome/common/extensions/docs/templates/intros/mediaGalleries.html index 9570bc9..197cc50 100644 --- a/chrome/common/extensions/docs/templates/intros/mediaGalleries.html +++ b/chrome/common/extensions/docs/templates/intros/mediaGalleries.html @@ -133,19 +133,4 @@ incrementing integer in parenthesis before the extension.</p> <h2 id="iPhoto">iPhoto</h2> -<p>If present, the user's iPhoto library can be accessed as a media gallery. -The files are structured within a subdirectory called "Albums/". Within that -subdirectory, each album in the user's iPhoto library will appear as a -subdirectory by name, and contain file entries for the photos in that album. -</p> -<p>Duplicate album names or image filenames within albums will get a -disambiguating suffix like "(NN)" where NN is a unique number.</p> -<p>Any items appearing in multiple albums in iPhoto will appear in all those -albums in the gallery.</p> -<p>If the user has modified any images within an album, there will be an -additional subdirectory called "originals/" within the album directory. -It will contain the original image with the same filename as in the parent -album subdirectory. The file as it appears in the parrent album directory -will be the one the user has invested time cropping, rotating, or -otherwise editing.</p> - +<p>iPhoto support was removed in Chrome 51.</p> diff --git a/chrome/common/media_galleries/iphoto_library.cc b/chrome/common/media_galleries/iphoto_library.cc deleted file mode 100644 index 03e13c0..0000000 --- a/chrome/common/media_galleries/iphoto_library.cc +++ /dev/null @@ -1,34 +0,0 @@ -// Copyright 2013 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "chrome/common/media_galleries/iphoto_library.h" - -namespace iphoto { -namespace parser { - -Photo::Photo() - : id(0) { -} - -Photo::Photo(uint64_t id, - const base::FilePath& location, - const base::FilePath& original_location) - : id(id), location(location), original_location(original_location) {} - -bool Photo::operator<(const Photo& other) const { - return id < other.id; -} - -Library::Library() {} - -Library::Library(const Albums& albums, - const std::set<Photo>& all_photos) - : albums(albums), - all_photos(all_photos) {} - -Library::~Library() {} - - -} // namespace parser -} // namespace iphoto diff --git a/chrome/common/media_galleries/iphoto_library.h b/chrome/common/media_galleries/iphoto_library.h deleted file mode 100644 index dcae0ec..0000000 --- a/chrome/common/media_galleries/iphoto_library.h +++ /dev/null @@ -1,49 +0,0 @@ -// Copyright 2013 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// These data structures can be used to describe the contents of an iPhoto -// library. - -#ifndef CHROME_COMMON_MEDIA_GALLERIES_IPHOTO_LIBRARY_H_ -#define CHROME_COMMON_MEDIA_GALLERIES_IPHOTO_LIBRARY_H_ - -#include <stdint.h> - -#include <map> -#include <set> - -#include "base/files/file_path.h" - -namespace iphoto { -namespace parser { - -struct Photo { - Photo(); - Photo(uint64_t id, - const base::FilePath& location, - const base::FilePath& original_location); - bool operator<(const Photo& other) const; - - uint64_t id; - base::FilePath location; - base::FilePath original_location; -}; - -typedef std::set<uint64_t> Album; -typedef std::map<std::string /*album name*/, Album> Albums; - -struct Library { - Library(); - Library(const Albums& albums, const std::set<Photo>& all_photos); - ~Library(); - - Albums albums; - std::set<Photo> all_photos; -}; - -} // namespace parser -} // namespace iphoto - -#endif // CHROME_COMMON_MEDIA_GALLERIES_IPHOTO_LIBRARY_H_ - |