summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorthakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-08-09 20:27:26 +0000
committerthakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-08-09 20:27:26 +0000
commitbeee7a9de8c1fb91f05ffa7eeb657a5679c1dfe4 (patch)
tree98bfad12c48d26401a5d0520f2ee85641c364b18
parent5f818b93158695864a8b8958e7f62b6a1741420f (diff)
downloadchromium_src-beee7a9de8c1fb91f05ffa7eeb657a5679c1dfe4.zip
chromium_src-beee7a9de8c1fb91f05ffa7eeb657a5679c1dfe4.tar.gz
chromium_src-beee7a9de8c1fb91f05ffa7eeb657a5679c1dfe4.tar.bz2
mac: Delete more 10.5-only code
BUG=137676 TBR=tony, sky Review URL: https://chromiumcodereview.appspot.com/10837158 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@150878 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--base/mac/mac_util.h6
-rw-r--r--base/mac/mac_util.mm13
-rw-r--r--base/mac/mac_util_unittest.mm21
-rw-r--r--base/process_util_mac.mm2
-rw-r--r--chrome/app/generated_resources.grd8
-rw-r--r--chrome/browser/app_controller_mac.mm7
-rw-r--r--chrome/browser/gpu_util.cc6
-rw-r--r--chrome/browser/prefs/browser_prefs.cc2
-rw-r--r--chrome/browser/process_info_snapshot_mac.cc76
-rw-r--r--chrome/browser/resources/help/help.css4
-rw-r--r--chrome/browser/resources/help/help.html7
-rw-r--r--chrome/browser/resources/help/help.js12
-rw-r--r--chrome/browser/ui/cocoa/obsolete_os.cc24
-rw-r--r--chrome/browser/ui/cocoa/obsolete_os.h29
-rw-r--r--chrome/browser/ui/startup/obsolete_os_prompt.cc4
-rw-r--r--chrome/browser/ui/startup/obsolete_os_prompt.h5
-rw-r--r--chrome/browser/ui/startup/obsolete_os_prompt_mac.cc62
-rw-r--r--chrome/browser/ui/webui/help/help_handler.cc18
-rw-r--r--chrome/chrome_browser.gypi3
-rw-r--r--chrome/common/mac/objc_zombie.mm130
-rw-r--r--chrome/common/pref_names.cc6
-rw-r--r--chrome/common/pref_names.h4
-rw-r--r--chrome/common/url_constants.cc5
-rw-r--r--chrome/common/url_constants.h5
-rw-r--r--media/audio/mac/audio_manager_mac.cc16
-rw-r--r--remoting/host/video_frame_capturer_mac.mm7
-rw-r--r--skia/ext/skia_utils_mac.mm35
-rw-r--r--ui/gfx/scoped_ns_graphics_context_save_gstate_mac.mm11
-rw-r--r--ui/gfx/video_decode_acceleration_support_mac_unittest.mm6
-rw-r--r--webkit/plugins/npapi/plugin_host.cc2
-rw-r--r--webkit/plugins/npapi/plugin_list_mac.mm8
-rw-r--r--webkit/plugins/npapi/webplugin_delegate_impl_mac.mm5
32 files changed, 30 insertions, 519 deletions
diff --git a/base/mac/mac_util.h b/base/mac/mac_util.h
index a4053fd..ba13ff9 100644
--- a/base/mac/mac_util.h
+++ b/base/mac/mac_util.h
@@ -126,10 +126,6 @@ BASE_EXPORT bool WasLaunchedAsHiddenLoginItem();
// "OrLater" variants to those that check for a specific version, unless you
// know for sure that you need to check for a specific version.
-// Leopard is Mac OS X 10.5, Darwin 9.
-BASE_EXPORT bool IsOSLeopard();
-BASE_EXPORT bool IsOSLeopardOrEarlier();
-
// Snow Leopard is Mac OS X 10.6, Darwin 10.
BASE_EXPORT bool IsOSSnowLeopard();
BASE_EXPORT bool IsOSSnowLeopardOrEarlier();
@@ -158,8 +154,6 @@ BASE_EXPORT
#if defined(MAC_OS_X_VERSION_10_6) && \
MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6
#define BASE_MAC_MAC_UTIL_H_INLINED_GE_10_6
-inline bool IsOSLeopard() { return false; }
-inline bool IsOSLeopardOrEarlier() { return false; }
inline bool IsOSSnowLeopardOrLater() { return true; }
#endif
diff --git a/base/mac/mac_util.mm b/base/mac/mac_util.mm
index 0d8fe63..f6aeebe 100644
--- a/base/mac/mac_util.mm
+++ b/base/mac/mac_util.mm
@@ -560,7 +560,6 @@ int MacOSXMinorVersion() {
}
enum {
- LEOPARD_MINOR_VERSION = 5,
SNOW_LEOPARD_MINOR_VERSION = 6,
LION_MINOR_VERSION = 7,
MOUNTAIN_LION_MINOR_VERSION = 8,
@@ -568,18 +567,6 @@ enum {
} // namespace
-#if !defined(BASE_MAC_MAC_UTIL_H_INLINED_GE_10_6)
-bool IsOSLeopard() {
- return MacOSXMinorVersion() == LEOPARD_MINOR_VERSION;
-}
-#endif
-
-#if !defined(BASE_MAC_MAC_UTIL_H_INLINED_GE_10_6)
-bool IsOSLeopardOrEarlier() {
- return MacOSXMinorVersion() <= LEOPARD_MINOR_VERSION;
-}
-#endif
-
#if !defined(BASE_MAC_MAC_UTIL_H_INLINED_GE_10_7)
bool IsOSSnowLeopard() {
return MacOSXMinorVersion() == SNOW_LEOPARD_MINOR_VERSION;
diff --git a/base/mac/mac_util_unittest.mm b/base/mac/mac_util_unittest.mm
index b09d685..94ec5bd 100644
--- a/base/mac/mac_util_unittest.mm
+++ b/base/mac/mac_util_unittest.mm
@@ -151,22 +151,7 @@ TEST_F(MacUtilTest, IsOSEllipsis) {
base::SysInfo::OperatingSystemVersionNumbers(&major, &minor, &bugfix);
if (major == 10) {
- if (minor == 5) {
- EXPECT_TRUE(IsOSLeopard());
- EXPECT_TRUE(IsOSLeopardOrEarlier());
- EXPECT_FALSE(IsOSSnowLeopard());
- EXPECT_TRUE(IsOSSnowLeopardOrEarlier());
- EXPECT_FALSE(IsOSSnowLeopardOrLater());
- EXPECT_FALSE(IsOSLion());
- EXPECT_TRUE(IsOSLionOrEarlier());
- EXPECT_FALSE(IsOSLionOrLater());
- EXPECT_FALSE(IsOSMountainLion());
- EXPECT_FALSE(IsOSMountainLionOrLater());
- EXPECT_FALSE(
- IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement());
- } else if (minor == 6) {
- EXPECT_FALSE(IsOSLeopard());
- EXPECT_FALSE(IsOSLeopardOrEarlier());
+ if (minor == 6) {
EXPECT_TRUE(IsOSSnowLeopard());
EXPECT_TRUE(IsOSSnowLeopardOrEarlier());
EXPECT_TRUE(IsOSSnowLeopardOrLater());
@@ -178,8 +163,6 @@ TEST_F(MacUtilTest, IsOSEllipsis) {
EXPECT_FALSE(
IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement());
} else if (minor == 7) {
- EXPECT_FALSE(IsOSLeopard());
- EXPECT_FALSE(IsOSLeopardOrEarlier());
EXPECT_FALSE(IsOSSnowLeopard());
EXPECT_FALSE(IsOSSnowLeopardOrEarlier());
EXPECT_TRUE(IsOSSnowLeopardOrLater());
@@ -191,8 +174,6 @@ TEST_F(MacUtilTest, IsOSEllipsis) {
EXPECT_FALSE(
IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement());
} else if (minor == 8) {
- EXPECT_FALSE(IsOSLeopard());
- EXPECT_FALSE(IsOSLeopardOrEarlier());
EXPECT_FALSE(IsOSSnowLeopard());
EXPECT_FALSE(IsOSSnowLeopardOrEarlier());
EXPECT_TRUE(IsOSSnowLeopardOrLater());
diff --git a/base/process_util_mac.mm b/base/process_util_mac.mm
index df539df..b257021 100644
--- a/base/process_util_mac.mm
+++ b/base/process_util_mac.mm
@@ -775,7 +775,7 @@ bool CanGetContextForCFAllocator() {
}
CFAllocatorContext* ContextForCFAllocator(CFAllocatorRef allocator) {
- if (base::mac::IsOSLeopard() || base::mac::IsOSSnowLeopard()) {
+ if (base::mac::IsOSSnowLeopard()) {
ChromeCFAllocatorLeopards* our_allocator =
const_cast<ChromeCFAllocatorLeopards*>(
reinterpret_cast<const ChromeCFAllocatorLeopards*>(allocator));
diff --git a/chrome/app/generated_resources.grd b/chrome/app/generated_resources.grd
index 996cac6..d5c17b6 100644
--- a/chrome/app/generated_resources.grd
+++ b/chrome/app/generated_resources.grd
@@ -13223,14 +13223,6 @@ Some features may be unavailable. Please check that the profile exists and you
<message name="IDS_INSTALL_FROM_DMG_ERROR" desc="Error dialog message to be displayed when installation from the disk image fails. Mac-only.">
<ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> couldn't complete installation, but will continue to run from its disk image.
</message>
-
- <!-- Mac 10.5 deprecation -->
- <message name="IDS_MAC_10_5_LEOPARD_OBSOLETE_SOON" desc="A message displayed on a weekly infobar and About (Help) page warning the user that the OS they are running is about to become unsupported.">
- This computer will soon stop receiving updates of <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> because it's running Mac OS X 10.5.
- </message>
- <message name="IDS_MAC_10_5_LEOPARD_OBSOLETE_NOW" desc="A message displayed on a weekly infobar and About (Help) page warning the user that the OS they are running is no longer supported.">
- This computer will no longer receive updates of <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph> because it's running Mac OS X 10.5.
- </message>
</if>
<!-- File Selection Dialog Policy - Infobar -->
diff --git a/chrome/browser/app_controller_mac.mm b/chrome/browser/app_controller_mac.mm
index 2cc8390..52f8f95 100644
--- a/chrome/browser/app_controller_mac.mm
+++ b/chrome/browser/app_controller_mac.mm
@@ -1026,12 +1026,7 @@ const AEEventClass kAECloudPrintUninstallClass = 'GCPu';
NSMenu* mainMenu = [NSApp mainMenu];
NSMenuItem* profileMenu = [mainMenu itemWithTag:IDC_PROFILE_MAIN_MENU];
- // On Leopard, hiding main menubar items does not work. This manifests itself
- // in Chromium as squished menu items <http://crbug.com/90753>. To prevent
- // this, remove the Profile menu on Leopard, regardless of the user's
- // multiprofile state.
- if (!ProfileManager::IsMultipleProfilesEnabled() ||
- base::mac::IsOSLeopard()) {
+ if (!ProfileManager::IsMultipleProfilesEnabled()) {
[mainMenu removeItem:profileMenu];
return;
}
diff --git a/chrome/browser/gpu_util.cc b/chrome/browser/gpu_util.cc
index 2af41916..730aa72 100644
--- a/chrome/browser/gpu_util.cc
+++ b/chrome/browser/gpu_util.cc
@@ -25,8 +25,6 @@
#if defined(OS_WIN)
#include "base/win/windows_version.h"
-#elif defined(OS_MACOSX)
-#include "base/mac/mac_util.h"
#endif
using content::GpuDataManager;
@@ -183,10 +181,6 @@ void InitializeCompositingFieldTrial() {
// Don't run the trial on Windows XP.
if (base::win::GetVersion() < base::win::VERSION_VISTA)
return;
-#elif defined(OS_MACOSX)
- // Accelerated compositing is only implemented on Mac OSX 10.6 or later.
- if (base::mac::IsOSLeopardOrEarlier())
- return;
#endif
// The performance of accelerated compositing is too low with software
diff --git a/chrome/browser/prefs/browser_prefs.cc b/chrome/browser/prefs/browser_prefs.cc
index 67f95ff..12dd6a0 100644
--- a/chrome/browser/prefs/browser_prefs.cc
+++ b/chrome/browser/prefs/browser_prefs.cc
@@ -76,7 +76,6 @@
#if defined(OS_MACOSX)
#include "chrome/browser/ui/cocoa/confirm_quit.h"
-#include "chrome/browser/ui/startup/obsolete_os_prompt.h"
#endif
#if defined(TOOLKIT_VIEWS)
@@ -186,7 +185,6 @@ void RegisterLocalState(PrefService* local_state) {
#endif
#if defined(OS_MACOSX)
- RegisterObsoleteOSInfobarPrefs(local_state);
confirm_quit::RegisterLocalState(local_state);
#endif
}
diff --git a/chrome/browser/process_info_snapshot_mac.cc b/chrome/browser/process_info_snapshot_mac.cc
index 74d93bf..6ee0e05 100644
--- a/chrome/browser/process_info_snapshot_mac.cc
+++ b/chrome/browser/process_info_snapshot_mac.cc
@@ -10,7 +10,6 @@
#include "base/command_line.h"
#include "base/logging.h"
-#include "base/mac/mac_util.h"
#include "base/string_number_conversions.h"
#include "base/string_util.h"
#include "base/threading/thread.h"
@@ -268,75 +267,6 @@ static bool GetProcessMemoryInfoUsingTop(
return true;
}
-static bool GetProcessMemoryInfoUsingTop_10_5(
- std::map<int,ProcessInfoSnapshot::ProcInfoEntry>& proc_info_entries) {
- const FilePath kProgram("/usr/bin/top");
- CommandLine command_line(kProgram);
-
- // -p tells top to print just the given fields as ordered.
- command_line.AppendArg("-p");
- command_line.AppendArg(
- "^aaaaaaaaaaaaaaaaaaaa " // Process ID (PID)
- "^jjjjjjjjjjjjjjjjjjjj " // Resident memory (RSIZE)
- "^iiiiiiiiiiiiiiiiiiii " // Resident shared memory (RSHRD)
- "^hhhhhhhhhhhhhhhhhhhh " // Resident private memory (RPRVT)
- "^llllllllllllllllllll"); // Total virtual memory (VSIZE)
- // Run top in logging (non-interactive) mode.
- command_line.AppendArg("-l");
- command_line.AppendArg("1");
- // Set the delay between updates to 0.
- command_line.AppendArg("-s");
- command_line.AppendArg("0");
-
- std::string output;
- // Limit output read to a megabyte for safety.
- if (!base::GetAppOutputRestricted(command_line, &output, 1024 * 1024)) {
- LOG(ERROR) << "Failure running " << kProgram.value() << " to acquire data.";
- return false;
- }
-
- // Process lines until done. Lines should look something like this:
- // PID RSIZE RSHRD RPRVT VSIZE
- // 16943 815104 262144 290816 18489344
- // 16922 954368 720896 278528 18976768
- std::istringstream top_in(output, std::istringstream::in);
- std::string line;
- while (std::getline(top_in, line)) {
- std::istringstream in(line, std::istringstream::in);
-
- // Try to read the PID.
- pid_t pid;
- in >> pid;
- if (in.fail())
- continue;
-
- // Make sure that caller is interested in this process.
- if (proc_info_entries.find(pid) == proc_info_entries.end())
- continue;
-
- uint64_t values[4];
- size_t i;
- for (i = 0; i < arraysize(values); i++) {
- in >> values[i];
- if (in.fail())
- break;
- }
- if (i != arraysize(values))
- continue;
-
- ProcessInfoSnapshot::ProcInfoEntry proc_info = proc_info_entries[pid];
- proc_info.rss = values[0];
- proc_info.rshrd = values[1];
- proc_info.rprvt = values[2];
- proc_info.vsize = values[3];
- // Record the process information.
- proc_info_entries[proc_info.pid] = proc_info;
- }
-
- return true;
-}
-
-
bool ProcessInfoSnapshot::Sample(std::vector<base::ProcessId> pid_list) {
Reset();
@@ -379,11 +309,7 @@ bool ProcessInfoSnapshot::Sample(std::vector<base::ProcessId> pid_list) {
}
// Get memory information using top.
- bool memory_info_success = false;
- if (base::mac::IsOSLeopardOrEarlier())
- memory_info_success = GetProcessMemoryInfoUsingTop_10_5(proc_info_entries_);
- else
- memory_info_success = GetProcessMemoryInfoUsingTop(proc_info_entries_);
+ bool memory_info_success = GetProcessMemoryInfoUsingTop(proc_info_entries_);
// If top didn't work then fall back to ps.
if (!memory_info_success) {
diff --git a/chrome/browser/resources/help/help.css b/chrome/browser/resources/help/help.css
index ca482da..8ee1966 100644
--- a/chrome/browser/resources/help/help.css
+++ b/chrome/browser/resources/help/help.css
@@ -79,10 +79,6 @@ body {
background-size: 17px;
}
-#update-obsolete-os-container {
- -webkit-margin-start: 25px;
-}
-
#more-info-expander {
-webkit-padding-start: 0;
}
diff --git a/chrome/browser/resources/help/help.html b/chrome/browser/resources/help/help.html
index 762f59a..24bb6bd 100644
--- a/chrome/browser/resources/help/help.html
+++ b/chrome/browser/resources/help/help.html
@@ -76,13 +76,6 @@
<div id="update-status-icon" class="up-to-date"></div>
<span id="update-status" i18n-content="updateCheckStarted"></span>
</div>
-<if expr="is_macosx">
- <div id="update-obsolete-os-container" hidden>
- <span id="update-obsolete-os" i18n-content="updateObsoleteOS"></span>
- <a i18n-values="href:updateObsoleteOSURL" i18n-content="learnMore"
- target="_blank"></a>
- </div>
-</if>
<div id="update-buttons-container">
<div id="update-percentage" hidden></div>
<if expr="is_macosx">
diff --git a/chrome/browser/resources/help/help.js b/chrome/browser/resources/help/help.js
index ba609bc..420a599 100644
--- a/chrome/browser/resources/help/help.js
+++ b/chrome/browser/resources/help/help.js
@@ -154,18 +154,6 @@ cr.define('help', function() {
/**
* @private
*/
- setObsoleteOS_: function(obsolete) {
- if (cr.isMac) {
- var updateObsoleteOSContainer = $('update-obsolete-os-container');
- if (updateObsoleteOSContainer) {
- updateObsoleteOSContainer.hidden = !obsolete;
- }
- }
- },
-
- /**
- * @private
- */
setOSVersion_: function(version) {
if (!cr.isChromeOS)
console.error('OS version unsupported on non-CrOS');
diff --git a/chrome/browser/ui/cocoa/obsolete_os.cc b/chrome/browser/ui/cocoa/obsolete_os.cc
deleted file mode 100644
index 764bf1d..0000000
--- a/chrome/browser/ui/cocoa/obsolete_os.cc
+++ /dev/null
@@ -1,24 +0,0 @@
-// Copyright (c) 2012 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/browser/ui/cocoa/obsolete_os.h"
-
-#include "grit/chromium_strings.h"
-#include "grit/generated_resources.h"
-#include "ui/base/l10n/l10n_util.h"
-
-namespace chrome {
-
-string16 LocalizedObsoleteOSString() {
- // TODO(mark): Change kEndOfTheLine to true immediately prior to the last
- // build on the Chrome 21 branch.
- const bool kEndOfTheLine = false;
-
- return l10n_util::GetStringFUTF16(
- kEndOfTheLine ? IDS_MAC_10_5_LEOPARD_OBSOLETE_NOW :
- IDS_MAC_10_5_LEOPARD_OBSOLETE_SOON,
- l10n_util::GetStringUTF16(IDS_PRODUCT_NAME));
-}
-
-} // namespace chrome
diff --git a/chrome/browser/ui/cocoa/obsolete_os.h b/chrome/browser/ui/cocoa/obsolete_os.h
deleted file mode 100644
index 2cba8aa..0000000
--- a/chrome/browser/ui/cocoa/obsolete_os.h
+++ /dev/null
@@ -1,29 +0,0 @@
-// Copyright (c) 2012 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.
-
-#ifndef CHROME_BROWSER_UI_COCOA_OBSOLETE_OS_H_
-#define CHROME_BROWSER_UI_COCOA_OBSOLETE_OS_H_
-
-#include "base/mac/mac_util.h"
-#include "base/string16.h"
-
-namespace chrome {
-
-// Returns true if the OS will either be unsupported by future versions of the
-// application in the near future, or if this is the last version of the
-// application that supports the OS.
-inline bool IsOSObsoleteOrNearlySo() {
- return base::mac::IsOSLeopardOrEarlier();
-}
-
-// Returns a localized string informing users that their OS will either soon
-// be unsupported by future versions of the application, or that they are
-// already using the last version of the application that supports their OS.
-// Do not use the returned string unless IsOSObsoleteOrNearlySo() returns
-// true.
-string16 LocalizedObsoleteOSString();
-
-} // namespace chrome
-
-#endif // CHROME_BROWSER_UI_COCOA_OBSOLETE_OS_H_
diff --git a/chrome/browser/ui/startup/obsolete_os_prompt.cc b/chrome/browser/ui/startup/obsolete_os_prompt.cc
index cd89442..052ddf4 100644
--- a/chrome/browser/ui/startup/obsolete_os_prompt.cc
+++ b/chrome/browser/ui/startup/obsolete_os_prompt.cc
@@ -6,9 +6,9 @@
namespace chrome {
-#if !defined(TOOLKIT_GTK) && !defined(OS_MACOSX)
+#if !defined(TOOLKIT_GTK)
void ShowObsoleteOSPrompt(Browser* browser) {
- // Only shown on Gtk and OS X.
+ // Only shown on Gtk.
}
#endif
diff --git a/chrome/browser/ui/startup/obsolete_os_prompt.h b/chrome/browser/ui/startup/obsolete_os_prompt.h
index 825d40f..4db6844 100644
--- a/chrome/browser/ui/startup/obsolete_os_prompt.h
+++ b/chrome/browser/ui/startup/obsolete_os_prompt.h
@@ -12,11 +12,6 @@ class PrefService;
namespace chrome {
-#if defined(OS_MACOSX)
-// Registers the Mac-specific preference about when to show obsolete OS prompts.
-void RegisterObsoleteOSInfobarPrefs(PrefService* local_state);
-#endif
-
// Shows a warning notification in |browser| that the app is being run on an
// unsupported operating system.
void ShowObsoleteOSPrompt(Browser* browser);
diff --git a/chrome/browser/ui/startup/obsolete_os_prompt_mac.cc b/chrome/browser/ui/startup/obsolete_os_prompt_mac.cc
deleted file mode 100644
index 65faa16..0000000
--- a/chrome/browser/ui/startup/obsolete_os_prompt_mac.cc
+++ /dev/null
@@ -1,62 +0,0 @@
-// Copyright (c) 2012 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/browser/ui/startup/obsolete_os_prompt.h"
-
-#include "base/time.h"
-#include "chrome/browser/browser_process.h"
-#include "chrome/browser/infobars/infobar_tab_helper.h"
-#include "chrome/browser/prefs/pref_service.h"
-#include "chrome/browser/ui/browser.h"
-#include "chrome/browser/ui/browser_tabstrip.h"
-#include "chrome/browser/ui/cocoa/obsolete_os.h"
-#include "chrome/browser/ui/startup/obsolete_os_info_bar.h"
-#include "chrome/browser/ui/tab_contents/tab_contents.h"
-#include "chrome/common/pref_names.h"
-#include "chrome/common/url_constants.h"
-
-namespace chrome {
-
-void RegisterObsoleteOSInfobarPrefs(PrefService* local_state) {
- local_state->RegisterDoublePref(
- prefs::kMacLeopardObsoleteInfobarLastShown,
- 0,
- PrefService::UNSYNCABLE_PREF);
-}
-
-void ShowObsoleteOSPrompt(Browser* browser) {
- if (!IsOSObsoleteOrNearlySo())
- return;
-
- PrefService* local_state = g_browser_process->local_state();
- if (!local_state)
- return;
-
- // Only show the infobar if the user has not been shown it for more than a
- // week.
- base::Time time_now(base::Time::Now());
- if (local_state->HasPrefPath(prefs::kMacLeopardObsoleteInfobarLastShown)) {
- double time_double =
- local_state->GetDouble(prefs::kMacLeopardObsoleteInfobarLastShown);
- base::Time last_shown(base::Time::FromDoubleT(time_double));
-
- base::TimeDelta a_week(base::TimeDelta::FromDays(7));
- if (last_shown >= time_now - a_week)
- return;
- }
-
- TabContents* tab = chrome::GetActiveTabContents(browser);
- if (!tab)
- return;
- tab->infobar_tab_helper()->AddInfoBar(
- new ObsoleteOSInfoBar(
- tab->infobar_tab_helper(),
- LocalizedObsoleteOSString(),
- GURL(chrome::kMacLeopardObsoleteURL)));
-
- local_state->SetDouble(prefs::kMacLeopardObsoleteInfobarLastShown,
- time_now.ToDoubleT());
-}
-
-} // namespace chrome
diff --git a/chrome/browser/ui/webui/help/help_handler.cc b/chrome/browser/ui/webui/help/help_handler.cc
index 82312fa..5a1fb3d 100644
--- a/chrome/browser/ui/webui/help/help_handler.cc
+++ b/chrome/browser/ui/webui/help/help_handler.cc
@@ -46,10 +46,6 @@
#include "content/public/browser/browser_thread.h"
#endif
-#if defined(OS_MACOSX)
-#include "chrome/browser/ui/cocoa/obsolete_os.h"
-#endif
-
using base::ListValue;
using content::BrowserThread;
@@ -170,13 +166,6 @@ void HelpHandler::GetLocalizedValues(DictionaryValue* localized_strings) {
l10n_util::GetStringUTF16(resources[i].ids));
}
-#if defined(OS_MACOSX)
- localized_strings->SetString("updateObsoleteOS",
- chrome::LocalizedObsoleteOSString());
- localized_strings->SetString("updateObsoleteOSURL",
- chrome::kMacLeopardObsoleteURL);
-#endif
-
localized_strings->SetString(
"browserVersion",
l10n_util::GetStringFUTF16(IDS_ABOUT_PRODUCT_VERSION,
@@ -293,13 +282,6 @@ void HelpHandler::OnPageLoaded(const ListValue* args) {
version_updater_->GetReleaseChannel(
base::Bind(&HelpHandler::OnReleaseChannel, base::Unretained(this)));
#endif
-
-#if defined(OS_MACOSX)
- scoped_ptr<base::Value> is_os_obsolete(
- base::Value::CreateBooleanValue(chrome::IsOSObsoleteOrNearlySo()));
- web_ui()->CallJavascriptFunction("help.HelpPage.setObsoleteOS",
- *is_os_obsolete);
-#endif
}
#if defined(OS_MACOSX)
diff --git a/chrome/chrome_browser.gypi b/chrome/chrome_browser.gypi
index b434902..69a83a2 100644
--- a/chrome/chrome_browser.gypi
+++ b/chrome/chrome_browser.gypi
@@ -2893,8 +2893,6 @@
'browser/ui/cocoa/nsmenuitem_additions.mm',
'browser/ui/cocoa/nsview_additions.h',
'browser/ui/cocoa/nsview_additions.mm',
- 'browser/ui/cocoa/obsolete_os.cc',
- 'browser/ui/cocoa/obsolete_os.h',
'browser/ui/cocoa/omnibox/omnibox_popup_view_mac.h',
'browser/ui/cocoa/omnibox/omnibox_popup_view_mac.mm',
'browser/ui/cocoa/omnibox/omnibox_view_mac.h',
@@ -3460,7 +3458,6 @@
'browser/ui/startup/obsolete_os_prompt.cc',
'browser/ui/startup/obsolete_os_prompt.h',
'browser/ui/startup/obsolete_os_prompt_gtk.cc',
- 'browser/ui/startup/obsolete_os_prompt_mac.cc',
'browser/ui/startup/session_crashed_prompt.cc',
'browser/ui/startup/session_crashed_prompt.h',
'browser/ui/startup/startup_browser_creator.cc',
diff --git a/chrome/common/mac/objc_zombie.mm b/chrome/common/mac/objc_zombie.mm
index a934359..afb5328 100644
--- a/chrome/common/mac/objc_zombie.mm
+++ b/chrome/common/mac/objc_zombie.mm
@@ -4,12 +4,15 @@
#import "chrome/common/mac/objc_zombie.h"
+#include <AvailabilityMacros.h>
+
#include <dlfcn.h>
#include <execinfo.h>
#include <mach-o/dyld.h>
#include <mach-o/nlist.h>
#import <objc/objc-class.h>
+#import <objc/runtime.h>
#include <algorithm>
@@ -22,6 +25,12 @@
#include "base/synchronization/lock.h"
#import "chrome/common/mac/objc_method_swizzle.h"
+#if MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_6
+// Apparently objc/runtime.h doesn't define this with the 10.6 SDK yet.
+// The docs say it exists since 10.6 however.
+OBJC_EXPORT void *objc_destructInstance(id obj);
+#endif
+
// Deallocated objects are re-classed as |CrZombie|. No superclass
// because then the class would have to override many/most of the
// inherited methods (|NSObject| is like a category magnet!).
@@ -52,16 +61,6 @@ namespace {
// the maximum number of 32-bit items which can be encoded is 23.
const size_t kBacktraceDepth = 20;
-// Function which destroys the contents of an object without freeing
-// the object. On 10.5 this is |object_cxxDestruct()|, which
-// traverses the class hierarchy to run the C++ destructors. On 10.6
-// this is |objc_destructInstance()| which calls
-// |object_cxxDestruct()| and removes associative references.
-// |objc_destructInstance()| returns |void*| but pretending it has no
-// return value makes the code simpler.
-typedef void DestructFn(id obj);
-DestructFn* g_objectDestruct = NULL;
-
// The original implementation for |-[NSObject dealloc]|.
IMP g_originalDeallocIMP = NULL;
@@ -105,60 +104,6 @@ const char* LookupObjcRuntimePath() {
return NULL;
}
-// Lookup |objc_destructInstance()| dynamically because it isn't
-// available on 10.5, but we link with the 10.5 SDK.
-DestructFn* LookupObjectDestruct_10_6() {
- const char* objc_runtime_path = LookupObjcRuntimePath();
- if (!objc_runtime_path)
- return NULL;
-
- void* handle = dlopen(objc_runtime_path, RTLD_LAZY | RTLD_LOCAL);
- if (!handle)
- return NULL;
-
- void* fn = dlsym(handle, "objc_destructInstance");
-
- // |fn| would normally be expected to become invalid after this
- // |dlclose()|, but since the |dlopen()| was on a library
- // containing an already-mapped symbol, it will remain valid.
- dlclose(handle);
- return reinterpret_cast<DestructFn*>(fn);
-}
-
-// Under 10.5 |object_cxxDestruct()| is used but unfortunately it is
-// |__private_extern__| in the runtime, meaning |dlsym()| cannot reach it.
-DestructFn* LookupObjectDestruct_10_5() {
- // |nlist()| is only present for 32-bit.
-#if ARCH_CPU_32_BITS
- const char* objc_runtime_path = LookupObjcRuntimePath();
- if (!objc_runtime_path)
- return NULL;
-
- struct nlist nl[3];
- bzero(&nl, sizeof(nl));
-
- nl[0].n_un.n_name = const_cast<char*>("_object_cxxDestruct");
-
- // My ability to calculate the base for offsets is apparently poor.
- // Use |class_addIvar| as a known reference point.
- nl[1].n_un.n_name = const_cast<char*>("_class_addIvar");
-
- if (nlist(objc_runtime_path, nl) < 0 ||
- nl[0].n_type == N_UNDF || nl[1].n_type == N_UNDF)
- return NULL;
-
- // Back out offset to |class_addIvar()| to get the baseline, then
- // add back offset to |object_cxxDestruct()|.
- uintptr_t reference_addr = reinterpret_cast<uintptr_t>(&class_addIvar);
- reference_addr -= nl[1].n_value;
- reference_addr += nl[0].n_value;
-
- return reinterpret_cast<DestructFn*>(reference_addr);
-#endif
-
- return NULL;
-}
-
// Replacement |-dealloc| which turns objects into zombies and places
// them into |g_zombies| to be freed later.
void ZombieDealloc(id self, SEL _cmd) {
@@ -172,16 +117,6 @@ void ZombieDealloc(id self, SEL _cmd) {
return;
}
- // Use the original |-dealloc| if |g_objectDestruct| was never
- // initialized, because otherwise C++ destructors won't be called.
- // This case should be impossible, but doing it wrong would cause
- // terrible problems.
- DCHECK(g_objectDestruct);
- if (!g_objectDestruct) {
- g_originalDeallocIMP(self, _cmd);
- return;
- }
-
Class wasa = object_getClass(self);
const size_t size = class_getInstanceSize(wasa);
@@ -191,7 +126,7 @@ void ZombieDealloc(id self, SEL _cmd) {
// zombie falls off the treadmill! But by then |isa| will be a
// class without C++ destructors or associative references, so it
// won't hurt anything.
- (*g_objectDestruct)(self);
+ objc_destructInstance(self);
memset(self, '!', size);
// If the instance is big enough, make it into a fat zombie and have
@@ -313,54 +248,12 @@ void ZombieObjectCrash(id object, SEL aSelector, SEL viaSelector) {
*zero = 0;
}
-// For monitoring failures in |ZombieInit()|.
-enum ZombieFailure {
- FAILED_10_5,
- FAILED_10_6,
-
- // Add new versions before here.
- FAILED_MAX,
-};
-
-void RecordZombieFailure(ZombieFailure failure) {
- UMA_HISTOGRAM_ENUMERATION("OSX.ZombieInitFailure", failure, FAILED_MAX);
-}
-
// Initialize our globals, returning YES on success.
BOOL ZombieInit() {
static BOOL initialized = NO;
if (initialized)
return YES;
- // Whitelist releases that are compatible with objc zombies.
- if (base::mac::IsOSLeopard()) {
- g_objectDestruct = LookupObjectDestruct_10_5();
- if (!g_objectDestruct) {
- RecordZombieFailure(FAILED_10_5);
- return NO;
- }
- } else if (base::mac::IsOSSnowLeopard()) {
- g_objectDestruct = LookupObjectDestruct_10_6();
- if (!g_objectDestruct) {
- RecordZombieFailure(FAILED_10_6);
- return NO;
- }
- } else if (base::mac::IsOSLionOrLater()) {
- // Assume the future looks like the present.
- g_objectDestruct = LookupObjectDestruct_10_6();
-
- // Put all future failures into the MAX bin. New OS releases come
- // out infrequently enough that this should always correspond to
- // "Next release", and once the next release happens that bin will
- // get an official name.
- if (!g_objectDestruct) {
- RecordZombieFailure(FAILED_MAX);
- return NO;
- }
- } else {
- return NO;
- }
-
Class rootClass = [NSObject class];
g_originalDeallocIMP =
class_getMethodImplementation(rootClass, @selector(dealloc));
@@ -369,8 +262,7 @@ BOOL ZombieInit() {
g_fatZombieClass = objc_getClass("CrFatZombie");
g_fatZombieSize = class_getInstanceSize(g_fatZombieClass);
- if (!g_objectDestruct || !g_originalDeallocIMP ||
- !g_zombieClass || !g_fatZombieClass)
+ if (!g_originalDeallocIMP || !g_zombieClass || !g_fatZombieClass)
return NO;
initialized = YES;
diff --git a/chrome/common/pref_names.cc b/chrome/common/pref_names.cc
index ec389ed..3fa64e0 100644
--- a/chrome/common/pref_names.cc
+++ b/chrome/common/pref_names.cc
@@ -2034,10 +2034,4 @@ const char kNetworkProfileWarningsLeft[] = "network_profile.warnings_left";
const char kNetworkProfileLastWarningTime[] =
"network_profile.last_warning_time";
-#if defined(OS_MACOSX)
-// A timestamp of when the obsolete OS infobar was last shown to a user on 10.5.
-const char kMacLeopardObsoleteInfobarLastShown[] =
- "mac_105_obsolete_infobar_last_shown";
-#endif // defined(OS_MACOSX)
-
} // namespace prefs
diff --git a/chrome/common/pref_names.h b/chrome/common/pref_names.h
index 54cbc6c..c6eb8b2 100644
--- a/chrome/common/pref_names.h
+++ b/chrome/common/pref_names.h
@@ -749,10 +749,6 @@ extern const char kInManagedMode[];
extern const char kNetworkProfileWarningsLeft[];
extern const char kNetworkProfileLastWarningTime[];
-#if defined(OS_MACOSX)
-extern const char kMacLeopardObsoleteInfobarLastShown[];
-#endif // defined(OS_MACOSX)
-
} // namespace prefs
#endif // CHROME_COMMON_PREF_NAMES_H_
diff --git a/chrome/common/url_constants.cc b/chrome/common/url_constants.cc
index 2b27436..df254b3 100644
--- a/chrome/common/url_constants.cc
+++ b/chrome/common/url_constants.cc
@@ -465,11 +465,6 @@ const char kNaturalScrollHelpURL[] =
"https://support.google.com/chromeos/?p=simple_scrolling";
#endif
-#if defined(OS_MACOSX)
-const char kMacLeopardObsoleteURL[] =
- "https://support.google.com/chrome/?p=ui_mac_leopard_support";
-#endif
-
const char* const kChromeDebugURLs[] = {
kChromeUICrashURL,
kChromeUIKillURL,
diff --git a/chrome/common/url_constants.h b/chrome/common/url_constants.h
index 2b72c4c..47924c7 100644
--- a/chrome/common/url_constants.h
+++ b/chrome/common/url_constants.h
@@ -372,11 +372,6 @@ extern const char kChromeToMobileLearnMoreURL[];
extern const char kNaturalScrollHelpURL[];
#endif
-#if defined(OS_MACOSX)
-// The URL for the Mac OS X 10.5 deprecation help center article.
-extern const char kMacLeopardObsoleteURL[];
-#endif
-
// "Debug" pages which are dangerous and not for general consumption.
extern const char* const kChromeDebugURLs[];
extern const int kNumberOfChromeDebugURLs;
diff --git a/media/audio/mac/audio_manager_mac.cc b/media/audio/mac/audio_manager_mac.cc
index ddddc7b..cb259ff 100644
--- a/media/audio/mac/audio_manager_mac.cc
+++ b/media/audio/mac/audio_manager_mac.cc
@@ -7,7 +7,6 @@
#include <string>
#include "base/mac/mac_logging.h"
-#include "base/mac/mac_util.h"
#include "base/mac/scoped_cftyperef.h"
#include "base/sys_string_conversions.h"
#include "media/audio/mac/audio_input_mac.h"
@@ -22,10 +21,6 @@ namespace media {
// Maximum number of output streams that can be open simultaneously.
static const int kMaxOutputStreams = 50;
-// By experiment the maximum number of audio streams allowed in Leopard
-// is 18. But we put a slightly smaller number just to be safe.
-static const int kMaxOutputStreamsLeopard = 15;
-
static bool HasAudioHardware(AudioObjectPropertySelector selector) {
AudioDeviceID output_device_id = kAudioObjectUnknown;
const AudioObjectPropertyAddress property_address = {
@@ -212,16 +207,7 @@ static AudioDeviceID GetAudioDeviceIdByUId(bool is_input,
}
AudioManagerMac::AudioManagerMac() {
- // We are hitting a bug in Leopard where too many audio streams will cause
- // a deadlock in the AudioQueue API when starting the stream. Unfortunately
- // there's no way to detect it within the AudioQueue API, so we put a
- // special hard limit only for Leopard.
- // See bug: http://crbug.com/30242
- // In OS other than OSX Leopard, the number of audio streams
- // allowed is a lot more.
- int max_output_stream = base::mac::IsOSLeopardOrEarlier() ?
- kMaxOutputStreamsLeopard : kMaxOutputStreams;
- SetMaxOutputStreamsAllowed(max_output_stream);
+ SetMaxOutputStreamsAllowed(kMaxOutputStreams);
}
AudioManagerMac::~AudioManagerMac() {
diff --git a/remoting/host/video_frame_capturer_mac.mm b/remoting/host/video_frame_capturer_mac.mm
index 36b82ad..fce6612 100644
--- a/remoting/host/video_frame_capturer_mac.mm
+++ b/remoting/host/video_frame_capturer_mac.mm
@@ -68,13 +68,6 @@ scoped_pixel_buffer_object::~scoped_pixel_buffer_object() {
bool scoped_pixel_buffer_object::Init(CGLContextObj cgl_context,
int size_in_bytes) {
- // The PBO path is only done on 10.6 (SnowLeopard) and above due to
- // a driver issue that was found on 10.5
- // (specifically on a NVIDIA GeForce 7300 GT).
- // http://crbug.com/87283
- if (base::mac::IsOSLeopardOrEarlier()) {
- return false;
- }
cgl_context_ = cgl_context;
CGLContextObj CGL_MACRO_CONTEXT = cgl_context_;
glGenBuffersARB(1, &pixel_buffer_object_);
diff --git a/skia/ext/skia_utils_mac.mm b/skia/ext/skia_utils_mac.mm
index 1811dae..64b14f2 100644
--- a/skia/ext/skia_utils_mac.mm
+++ b/skia/ext/skia_utils_mac.mm
@@ -7,7 +7,6 @@
#import <AppKit/AppKit.h>
#include "base/logging.h"
-#include "base/mac/mac_util.h"
#include "base/mac/scoped_cftyperef.h"
#include "base/memory/scoped_nsobject.h"
#include "base/memory/scoped_ptr.h"
@@ -57,45 +56,28 @@ SkBitmap NSImageOrNSImageRepToSkBitmap(
// Something went really wrong. Best guess is that the bitmap data is invalid.
DCHECK(context);
- // Save the current graphics context so that we can restore it later.
- NSGraphicsContext* old_context = [NSGraphicsContext currentContext];
[NSGraphicsContext saveGraphicsState];
- // Dummy context that we will draw into.
NSGraphicsContext* context_cocoa =
[NSGraphicsContext graphicsContextWithGraphicsPort:context flipped:NO];
[NSGraphicsContext setCurrentContext:context_cocoa];
- // This will stretch any images to |size| if it does not fit or is non-square.
NSRect drawRect = NSMakeRect(0, 0, size.width, size.height);
-
- // NSImage does caching such that subsequent drawing is much faster (on my
- // machine, about 4x faster). Unfortunately on 10.5 NSImageRep doesn't do
- // caching. For this reason we draw using an NSImage if available. Once
- // 10.5 is no longer supported we can drop this and always use NSImageRep.
if (image) {
[image drawInRect:drawRect
fromRect:NSZeroRect
operation:NSCompositeCopy
fraction:1.0];
} else {
- // Use NSCompositeCopy if available, it's slightly faster.
- if ([image_rep respondsToSelector:@selector(
- drawInRect:fromRect:operation:fraction:respectFlipped:hints:)]) {
- [image_rep drawInRect:drawRect
- fromRect:NSZeroRect
- operation:NSCompositeCopy
- fraction:1.0
- respectFlipped:NO
- hints:NO];
- } else {
- [image_rep drawInRect:drawRect];
- }
+ [image_rep drawInRect:drawRect
+ fromRect:NSZeroRect
+ operation:NSCompositeCopy
+ fraction:1.0
+ respectFlipped:NO
+ hints:NO];
}
[NSGraphicsContext restoreGraphicsState];
- if (!old_context && base::mac::IsOSLeopardOrEarlier())
- [NSGraphicsContext setCurrentContext:nil];
return bitmap;
}
@@ -224,8 +206,9 @@ SkBitmap NSImageToSkBitmap(NSImage* image, NSSize size, bool is_opaque) {
return NSImageOrNSImageRepToSkBitmap(image, nil, size, is_opaque);
}
-SkBitmap NSImageRepToSkBitmap(NSImageRep* image, NSSize size, bool is_opaque) {
- return NSImageOrNSImageRepToSkBitmap(nil, image, size, is_opaque);
+SkBitmap NSImageRepToSkBitmap(
+ NSImageRep* image_rep, NSSize size, bool is_opaque) {
+ return NSImageOrNSImageRepToSkBitmap(nil, image_rep, size, is_opaque);
}
NSBitmapImageRep* SkBitmapToNSBitmapImageRep(const SkBitmap& skiaBitmap) {
diff --git a/ui/gfx/scoped_ns_graphics_context_save_gstate_mac.mm b/ui/gfx/scoped_ns_graphics_context_save_gstate_mac.mm
index 9dca120..6b19d8c 100644
--- a/ui/gfx/scoped_ns_graphics_context_save_gstate_mac.mm
+++ b/ui/gfx/scoped_ns_graphics_context_save_gstate_mac.mm
@@ -7,7 +7,6 @@
#import <AppKit/AppKit.h>
#include "base/logging.h"
-#include "base/mac/mac_util.h"
namespace gfx {
@@ -18,16 +17,6 @@ ScopedNSGraphicsContextSaveGState::ScopedNSGraphicsContextSaveGState()
ScopedNSGraphicsContextSaveGState::~ScopedNSGraphicsContextSaveGState() {
[NSGraphicsContext restoreGraphicsState];
- if (!context_ && base::mac::IsOSLeopardOrEarlier()) {
- // On 10.5 and earlier, there is a bug. If the current graphics context was
- // nil when +[NSGraphicsContext saveGraphicsState] was called, then calling
- // +[NSGraphicsContext restoreGraphicsState] will not restore a nil current
- // context, but will leave the current context in place. Because allowing
- // that stale context (which will be deallocated soon) to remain current
- // will only lead to heartache and pain, the current context must be
- // manually nilled out.
- [NSGraphicsContext setCurrentContext:nil];
- }
DCHECK_EQ(context_, [NSGraphicsContext currentContext]);
}
diff --git a/ui/gfx/video_decode_acceleration_support_mac_unittest.mm b/ui/gfx/video_decode_acceleration_support_mac_unittest.mm
index fa73b83..bcc0623 100644
--- a/ui/gfx/video_decode_acceleration_support_mac_unittest.mm
+++ b/ui/gfx/video_decode_acceleration_support_mac_unittest.mm
@@ -7,7 +7,6 @@
#import "base/bind.h"
#include "base/location.h"
#import "base/mac/foundation_util.h"
-#import "base/mac/mac_util.h"
#include "base/mac/scoped_nsautorelease_pool.h"
#include "base/message_loop.h"
#import "base/sys_info.h"
@@ -36,10 +35,9 @@ const uint8_t kSampleAVCData[] = {
// Check to see if the OS we're running on should have
// VideoDecodeAcceleration.framework installed.
bool OSShouldHaveFramework() {
- if (base::mac::IsOSLeopardOrEarlier())
- return false;
-
// 10.6.2 and earlier doesn't have the framework.
+ // If we ever drop 10.6 support and clean up IsOSSnowLeopard() calls, this
+ // can be removed too.
int32 major, minor, bugfix;
base::SysInfo::OperatingSystemVersionNumbers(&major, &minor, &bugfix);
if (major == 10 && minor == 6 && bugfix <= 2)
diff --git a/webkit/plugins/npapi/plugin_host.cc b/webkit/plugins/npapi/plugin_host.cc
index 0025890..61d8e16 100644
--- a/webkit/plugins/npapi/plugin_host.cc
+++ b/webkit/plugins/npapi/plugin_host.cc
@@ -58,8 +58,6 @@ static PluginInstance* FindInstance(NPP id) {
// OS supports shared accelerated surfaces via IOSurface. This is true on Snow
// Leopard and higher.
static bool SupportsCoreAnimationPlugins() {
- if (base::mac::IsOSLeopardOrEarlier())
- return false;
if (CommandLine::ForCurrentProcess()->HasSwitch(
switches::kDisableCoreAnimationPlugins))
return false;
diff --git a/webkit/plugins/npapi/plugin_list_mac.mm b/webkit/plugins/npapi/plugin_list_mac.mm
index a1c91bb..199c8cf 100644
--- a/webkit/plugins/npapi/plugin_list_mac.mm
+++ b/webkit/plugins/npapi/plugin_list_mac.mm
@@ -74,14 +74,6 @@ void PluginList::GetPluginDirectories(std::vector<FilePath>* plugin_dirs) {
// Load from the machine-wide area
GetPluginCommonDirectory(plugin_dirs, false);
-
- // 10.5 includes the Java2 plugin, but as of Java for Mac OS X 10.5 Update 10
- // no longer has a symlink to it in the Internet Plug-Ins directory.
- // Manually include it since there's no other way to support Java.
- if (base::mac::IsOSLeopard()) {
- plugin_dirs->push_back(FilePath(
- "/System/Library/Java/Support/Deploy.bundle/Contents/Resources"));
- }
}
void PluginList::GetPluginsInDir(
diff --git a/webkit/plugins/npapi/webplugin_delegate_impl_mac.mm b/webkit/plugins/npapi/webplugin_delegate_impl_mac.mm
index 35d3f71..797d96b 100644
--- a/webkit/plugins/npapi/webplugin_delegate_impl_mac.mm
+++ b/webkit/plugins/npapi/webplugin_delegate_impl_mac.mm
@@ -959,11 +959,8 @@ void WebPluginDelegateImpl::PluginVisibilityChanged() {
}
void WebPluginDelegateImpl::StartIme() {
- // Currently the plugin IME implementation only works on 10.6.
- if (instance()->event_model() != NPEventModelCocoa ||
- base::mac::IsOSLeopardOrEarlier()) {
+ if (instance()->event_model() != NPEventModelCocoa)
return;
- }
if (ime_enabled_)
return;
ime_enabled_ = true;