diff options
author | Steve Block <steveblock@google.com> | 2011-02-18 10:17:30 +0000 |
---|---|---|
committer | Steve Block <steveblock@google.com> | 2011-02-18 11:15:27 +0000 |
commit | 9d6f8a4fbbdbaf61802f8e41de8afb692a0e3408 (patch) | |
tree | 107e562d88608f6f1592d85567445109ff5066f5 /chrome | |
parent | 10943605487833f68a0e9429c8c18735cdf6a963 (diff) | |
download | external_chromium-9d6f8a4fbbdbaf61802f8e41de8afb692a0e3408.zip external_chromium-9d6f8a4fbbdbaf61802f8e41de8afb692a0e3408.tar.gz external_chromium-9d6f8a4fbbdbaf61802f8e41de8afb692a0e3408.tar.bz2 |
Merge Chromium at 9.0.597.106
This is branches/597 at r74919.
Change-Id: Iab4795189c52e254b04051b05cbceda407afb0b6
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/browser/browser_main.cc | 2 | ||||
-rw-r--r-- | chrome/browser/extensions/crx_installer.cc | 3 | ||||
-rw-r--r-- | chrome/browser/in_process_webkit/browser_webkitclient_impl.cc | 4 | ||||
-rw-r--r-- | chrome/browser/js_modal_dialog.cc | 47 | ||||
-rw-r--r-- | chrome/browser/js_modal_dialog.h | 8 | ||||
-rw-r--r-- | chrome/browser/renderer_host/resource_message_filter.cc | 4 | ||||
-rw-r--r-- | chrome/browser/resources/gpu_blacklist.json | 46 | ||||
-rw-r--r-- | chrome/browser/tabs/tab_strip_model.cc | 16 | ||||
-rw-r--r-- | chrome/browser/tabs/tab_strip_model.h | 3 | ||||
-rw-r--r-- | chrome/common/extensions/docs/static/whats_new.html | 60 | ||||
-rw-r--r-- | chrome/common/extensions/docs/whats_new.html | 82 |
11 files changed, 198 insertions, 77 deletions
diff --git a/chrome/browser/browser_main.cc b/chrome/browser/browser_main.cc index 866f897..0e5d339 100644 --- a/chrome/browser/browser_main.cc +++ b/chrome/browser/browser_main.cc @@ -398,7 +398,7 @@ void BrowserMainParts::PrefetchFieldTrial() { ResourceDispatcherHost::set_is_prefetch_enabled(false); } else { const base::FieldTrial::Probability kPrefetchDivisor = 1000; - const base::FieldTrial::Probability no_prefetch_probability = 500; + const base::FieldTrial::Probability no_prefetch_probability = 970; scoped_refptr<base::FieldTrial> trial( new base::FieldTrial("Prefetch", kPrefetchDivisor)); trial->AppendGroup("ContentPrefetchDisabled", no_prefetch_probability); diff --git a/chrome/browser/extensions/crx_installer.cc b/chrome/browser/extensions/crx_installer.cc index e002314..8441baa 100644 --- a/chrome/browser/extensions/crx_installer.cc +++ b/chrome/browser/extensions/crx_installer.cc @@ -308,7 +308,8 @@ void CrxInstaller::ConfirmInstall() { GURL overlapping_url; const Extension* overlapping_extension = frontend_->GetExtensionByOverlappingWebExtent(extension_->web_extent()); - if (overlapping_extension) { + if (overlapping_extension && + overlapping_extension->id() != extension_->id()) { ReportFailureFromUIThread(l10n_util::GetStringFUTF8( IDS_EXTENSION_OVERLAPPING_WEB_EXTENT, UTF8ToUTF16(overlapping_extension->name()))); diff --git a/chrome/browser/in_process_webkit/browser_webkitclient_impl.cc b/chrome/browser/in_process_webkit/browser_webkitclient_impl.cc index df541e8..afe12ca 100644 --- a/chrome/browser/in_process_webkit/browser_webkitclient_impl.cc +++ b/chrome/browser/in_process_webkit/browser_webkitclient_impl.cc @@ -148,8 +148,10 @@ int BrowserWebKitClientImpl::databaseDeleteFile( } void BrowserWebKitClientImpl::idbShutdown() { - if (indexed_db_key_utility_client_.get()) + if (indexed_db_key_utility_client_.get()) { indexed_db_key_utility_client_->EndUtilityProcess(); + indexed_db_key_utility_client_ = NULL; + } } void BrowserWebKitClientImpl::createIDBKeysFromSerializedValuesAndKeyPath( diff --git a/chrome/browser/js_modal_dialog.cc b/chrome/browser/js_modal_dialog.cc index 32d35b1..4cfe4ae 100644 --- a/chrome/browser/js_modal_dialog.cc +++ b/chrome/browser/js_modal_dialog.cc @@ -110,46 +110,29 @@ void JavaScriptAppModalDialog::OnCancel(bool suppress_js_messages) { // is a temporary workaround. CompleteDialog(); - if (!skip_this_dialog_) { - delegate_->OnMessageBoxClosed(reply_msg_, false, std::wstring()); - if (suppress_js_messages) - delegate_->SetSuppressMessageBoxes(true); - } - - Cleanup(); + UpdateDelegate(false, L"", suppress_js_messages); } void JavaScriptAppModalDialog::OnAccept(const std::wstring& prompt_text, bool suppress_js_messages) { CompleteDialog(); - - if (!skip_this_dialog_) { - delegate_->OnMessageBoxClosed(reply_msg_, true, prompt_text); - if (suppress_js_messages) - delegate_->SetSuppressMessageBoxes(true); - } - - Cleanup(); + UpdateDelegate(true, prompt_text, suppress_js_messages); } void JavaScriptAppModalDialog::OnClose() { - Cleanup(); + // Should we be handling suppress here too? See crbug.com/65008. + UpdateDelegate(false, L"", false); } -void JavaScriptAppModalDialog::Cleanup() { - if (skip_this_dialog_) { - // We can't use the |delegate_|, because we might be in the process of - // destroying it. - if (tab_contents_) - tab_contents_->OnMessageBoxClosed(reply_msg_, false, L""); -// The extension_host_ will always be a dirty pointer on OS X because the alert -// window will cause the extension popup to close since it is resigning its key -// state, destroying the host. http://crbug.com/29355 -#if !defined(OS_MACOSX) - else if (extension_host_) - extension_host_->OnMessageBoxClosed(reply_msg_, false, L""); - else - NOTREACHED(); -#endif - } +void JavaScriptAppModalDialog::UpdateDelegate(bool success, + const std::wstring& prompt_text, + bool suppress_js_messages) { + if (skip_this_dialog_) + return; + + delegate_->OnMessageBoxClosed(reply_msg_, success, prompt_text); + if (suppress_js_messages) + delegate_->SetSuppressMessageBoxes(true); + + skip_this_dialog_ = true; } diff --git a/chrome/browser/js_modal_dialog.h b/chrome/browser/js_modal_dialog.h index 440633f..c531352 100644 --- a/chrome/browser/js_modal_dialog.h +++ b/chrome/browser/js_modal_dialog.h @@ -78,10 +78,6 @@ class JavaScriptAppModalDialog : public AppModalDialog, bool display_suppress_checkbox() const { return display_suppress_checkbox_; } bool is_before_unload_dialog() const { return is_before_unload_dialog_; } - protected: - // Overridden from AppModalDialog: - virtual void Cleanup(); - private: // Overridden from NotificationObserver: virtual void Observe(NotificationType type, @@ -91,6 +87,10 @@ class JavaScriptAppModalDialog : public AppModalDialog, // Initializes for notifications to listen. void InitNotifications(); + // Updates the delegate with the result of the dialog. + void UpdateDelegate(bool success, const std::wstring& prompt_text, + bool suppress_js_messages); + NotificationRegistrar registrar_; // An implementation of the client interface to provide supporting methods diff --git a/chrome/browser/renderer_host/resource_message_filter.cc b/chrome/browser/renderer_host/resource_message_filter.cc index bece8f1..a9c8c79 100644 --- a/chrome/browser/renderer_host/resource_message_filter.cc +++ b/chrome/browser/renderer_host/resource_message_filter.cc @@ -877,8 +877,8 @@ void ResourceMessageFilter::OnGotPluginInfo(bool found, const GURL& policy_url, IPC::Message* reply_msg) { ContentSetting setting = CONTENT_SETTING_DEFAULT; + WebPluginInfo info_copy = info; if (found) { - WebPluginInfo info_copy = info; info_copy.enabled = info_copy.enabled && plugin_service_->PrivatePluginAllowedForURL(info_copy.path, policy_url); HostContentSettingsMap* map = profile_->GetHostContentSettingsMap(); @@ -891,7 +891,7 @@ void ResourceMessageFilter::OnGotPluginInfo(bool found, } ViewHostMsg_GetPluginInfo::WriteReplyParams( - reply_msg, found, info, setting, actual_mime_type); + reply_msg, found, info_copy, setting, actual_mime_type); Send(reply_msg); } diff --git a/chrome/browser/resources/gpu_blacklist.json b/chrome/browser/resources/gpu_blacklist.json index f211db2..2720a6d 100644 --- a/chrome/browser/resources/gpu_blacklist.json +++ b/chrome/browser/resources/gpu_blacklist.json @@ -1,6 +1,6 @@ { "name": "gpu blacklist", - "version": "0.2", + "version": "0.7", "entries": [ { // ATI Radeon X1900 on Mac, BUGWEBKIT=47028 "os": { @@ -31,6 +31,50 @@ "blacklist": [ "webgl" ] + }, + { // Intel Mobile 945 Express Chipset Family + "os": { + "type": "any" + }, + "vendor_id": "0x8086", + "device_id": "0x27AE", + "blacklist": [ + "webgl" + ] + }, + { // All ATI cards in linux, BUG=71381 + "id": "5", + "os": { + "type": "linux" + }, + "vendor_id": "0x1002", + "blacklist": [ + "webgl" + ] + }, + { // ATI Radeon HD2600 on Mac, BUG=68859 + "id": "6", + "os": { + "type": "macosx" + }, + "vendor_id": "0x1002", + "device_id": "0x9583", + "blacklist": [ + "webgl", + "accelerated_compositing" + ] + }, + { // ATI Radeon HD2400 on Mac, BUG=68859 + "id": "7", + "os": { + "type": "macosx" + }, + "vendor_id": "0x1002", + "device_id": "0x94c8", + "blacklist": [ + "webgl", + "accelerated_compositing" + ] } ] } diff --git a/chrome/browser/tabs/tab_strip_model.cc b/chrome/browser/tabs/tab_strip_model.cc index 98316e9..a16d250 100644 --- a/chrome/browser/tabs/tab_strip_model.cc +++ b/chrome/browser/tabs/tab_strip_model.cc @@ -168,11 +168,11 @@ void TabStripModel::InsertTabContentsAt(int index, TabContentsWrapper* TabStripModel::ReplaceTabContentsAt( int index, TabContentsWrapper* new_contents) { - // TODO: this should reset group/opener of any tabs that point at - // old_contents. DCHECK(ContainsIndex(index)); TabContentsWrapper* old_contents = GetContentsAt(index); + ForgetOpenersAndGroupsReferencing(&(old_contents->controller())); + contents_data_[index]->contents = new_contents; FOR_EACH_OBSERVER(TabStripModelObserver, observers_, @@ -212,6 +212,7 @@ TabContentsWrapper* TabStripModel::DetachTabContentsAt(int index) { int next_selected_index = order_controller_->DetermineNewSelectedIndex(index); delete contents_data_.at(index); contents_data_.erase(contents_data_.begin() + index); + ForgetOpenersAndGroupsReferencing(&(removed_contents->controller())); if (empty()) closing_all_ = true; FOR_EACH_OBSERVER(TabStripModelObserver, observers_, @@ -1010,3 +1011,14 @@ bool TabStripModel::OpenerMatches(const TabContentsData* data, bool use_group) { return data->opener == opener || (use_group && data->group == opener); } + +void TabStripModel::ForgetOpenersAndGroupsReferencing( + const NavigationController* tab) { + for (TabContentsDataVector::const_iterator i = contents_data_.begin(); + i != contents_data_.end(); ++i) { + if ((*i)->group == tab) + (*i)->group = NULL; + if ((*i)->opener == tab) + (*i)->opener = NULL; + } +} diff --git a/chrome/browser/tabs/tab_strip_model.h b/chrome/browser/tabs/tab_strip_model.h index 7a3c8d9..7ed42f1 100644 --- a/chrome/browser/tabs/tab_strip_model.h +++ b/chrome/browser/tabs/tab_strip_model.h @@ -480,6 +480,9 @@ class TabStripModel : public NotificationObserver { const NavigationController* opener, bool use_group); + // Sets the group/opener of any tabs that reference |tab| to NULL. + void ForgetOpenersAndGroupsReferencing(const NavigationController* tab); + // Our delegate. TabStripModelDelegate* delegate_; diff --git a/chrome/common/extensions/docs/static/whats_new.html b/chrome/common/extensions/docs/static/whats_new.html index 9896ce7..9bf0393 100644 --- a/chrome/common/extensions/docs/static/whats_new.html +++ b/chrome/common/extensions/docs/static/whats_new.html @@ -7,12 +7,50 @@ made in recent releases. </p> <ul> + <li> <a href="#9">Google Chrome 9</a> </li> <li> <a href="#8">Google Chrome 8</a> </li> <li> <a href="#7">Google Chrome 7</a> </li> <li> <a href="#6">Google Chrome 6</a> </li> </ul> +<h2 id="9"> Google Chrome 9 </h2> + +<h4> New APIs </h4> + <ul> + <li>The <a href="omnibox.html">omnibox API</a> allows you to + register a keyword with Chrome's address bar. </li> + </ul> + +<h4> Manifest changes </h4> + <ul> + <li> The <a href="manifest.html#homepage_url">homepage_url</a> field + lets you specify the extension or app's homepage. </li> + </ul> +</h4> + +<!-- <h4> New experimental APIs </h4> --> + +<h4> Additions to existing APIs </h4> + <ul> + <li> The <a href="tabs.html#type-Tab">Tab</a> object + now has a <code>pinned</code> property + that's reflected in various <code>chrome.tabs</code> methods. + For example, + you can <a href="tabs.html#method-create">create</a> + a pinned tab. </li> + <li> The <a href="windows.html#method-create">chrome.windows.create()</a> + method's first parameter can now be an array of strings, + letting you create an array of tabs. </li> + <li> The <a href="windows.html#method-create">chrome.windows.create()</a> + method now has a <code>tabId</code> parameter. + You can use it to move a tab or panel into a new window. </li> + <li> The new + <a href="management.html#method-get">chrome.management.get()</a> method + lets you get information about the specified extension or app. </li> + </ul> + + <h2 id="8"> Google Chrome 8 </h2> <p> @@ -65,42 +103,42 @@ No API or manifest changes worth noting. <h4> New APIs </h4> <ul> <li>The <a href="contextMenus.html">context menus API</a> allows you to - add context menus to pages or specific objects on a page + add context menus to pages or specific objects on a page </li> <li>The <a href="cookies.html">cookies API</a> allows you to manage the - browser's cookie system + browser's cookie system </li> <li>The <a href="idle.html">idle API</a> allows you to detect when the - machine's idle state changes + machine's idle state changes </li> </ul> <h4> New experimental APIs </h4> <ul> <li>The <a href="experimental.omnibox.html">omnibox API</a> allows you to - add functionality to the browser's address bar + add functionality to the browser's address bar </li> <li>The <a href="experimental.infobars.html">infobars API</a> allows you - to add a UI panel across the top of a tab + to add a UI panel across the top of a tab </li> </ul> <h4> Additions to existing APIs </h4> <ul> <li>The <a href="extension.html#method-getViews">chrome.extension.getViews()</a> - method can now return popup views + method can now return popup views </li> <li>A new <a href="windows.html#property-WINDOW_ID_NONE">WINDOW_ID_NONE</a> constant - identifies when focus shifts away from the browser + identifies when focus shifts away from the browser </li> <li>The new <a href="tabs.html#method-getCurrent">chrome.tabs.getCurrent()</a> method - returns the tab associated with the currently executing script + returns the tab associated with the currently executing script </li> </ul> <h4> Manifest changes </h4> <ul> <li>The <a href="manifest.html#geolocation">geolocation</a> permission - gives an extension access to the user's physical location + gives an extension access to the user's physical location </li> <li><a href="match_patterns.html">Match patterns</a> can now select all - schemes or all URLs + schemes or all URLs </li> <li>Access to file:/// URLs no longer triggers the "access to your machine" security warning, but now requires user opt-in from the extensions - management page + management page </li> </ul> diff --git a/chrome/common/extensions/docs/whats_new.html b/chrome/common/extensions/docs/whats_new.html index 2449352..9e2b8ed 100644 --- a/chrome/common/extensions/docs/whats_new.html +++ b/chrome/common/extensions/docs/whats_new.html @@ -311,12 +311,50 @@ made in recent releases. </p> <ul> + <li> <a href="#9">Google Chrome 9</a> </li> <li> <a href="#8">Google Chrome 8</a> </li> <li> <a href="#7">Google Chrome 7</a> </li> <li> <a href="#6">Google Chrome 6</a> </li> </ul> +<h2 id="9"> Google Chrome 9 </h2> + +<h4> New APIs </h4> + <ul> + <li>The <a href="omnibox.html">omnibox API</a> allows you to + register a keyword with Chrome's address bar. </li> + </ul> + +<h4> Manifest changes </h4> + <ul> + <li> The <a href="manifest.html#homepage_url">homepage_url</a> field + lets you specify the extension or app's homepage. </li> + </ul> + + +<!-- <h4> New experimental APIs </h4> --> + +<h4> Additions to existing APIs </h4> + <ul> + <li> The <a href="tabs.html#type-Tab">Tab</a> object + now has a <code>pinned</code> property + that's reflected in various <code>chrome.tabs</code> methods. + For example, + you can <a href="tabs.html#method-create">create</a> + a pinned tab. </li> + <li> The <a href="windows.html#method-create">chrome.windows.create()</a> + method's first parameter can now be an array of strings, + letting you create an array of tabs. </li> + <li> The <a href="windows.html#method-create">chrome.windows.create()</a> + method now has a <code>tabId</code> parameter. + You can use it to move a tab or panel into a new window. </li> + <li> The new + <a href="management.html#method-get">chrome.management.get()</a> method + lets you get information about the specified extension or app. </li> + </ul> + + <h2 id="8"> Google Chrome 8 </h2> <p> @@ -369,41 +407,41 @@ No API or manifest changes worth noting. <h4> New APIs </h4> <ul> <li>The <a href="contextMenus.html">context menus API</a> allows you to - add context menus to pages or specific objects on a page - </li><li>The <a href="cookies.html">cookies API</a> allows you to manage the - browser's cookie system - </li><li>The <a href="idle.html">idle API</a> allows you to detect when the - machine's idle state changes - </li></ul> + add context menus to pages or specific objects on a page </li> + <li>The <a href="cookies.html">cookies API</a> allows you to manage the + browser's cookie system </li> + <li>The <a href="idle.html">idle API</a> allows you to detect when the + machine's idle state changes </li> + </ul> <h4> New experimental APIs </h4> <ul> <li>The <a href="experimental.omnibox.html">omnibox API</a> allows you to - add functionality to the browser's address bar - </li><li>The <a href="experimental.infobars.html">infobars API</a> allows you - to add a UI panel across the top of a tab - </li></ul> + add functionality to the browser's address bar </li> + <li>The <a href="experimental.infobars.html">infobars API</a> allows you + to add a UI panel across the top of a tab </li> + </ul> <h4> Additions to existing APIs </h4> <ul> <li>The <a href="extension.html#method-getViews">chrome.extension.getViews()</a> - method can now return popup views - </li><li>A new <a href="windows.html#property-WINDOW_ID_NONE">WINDOW_ID_NONE</a> constant - identifies when focus shifts away from the browser - </li><li>The new <a href="tabs.html#method-getCurrent">chrome.tabs.getCurrent()</a> method - returns the tab associated with the currently executing script - </li></ul> + method can now return popup views </li> + <li>A new <a href="windows.html#property-WINDOW_ID_NONE">WINDOW_ID_NONE</a> constant + identifies when focus shifts away from the browser </li> + <li>The new <a href="tabs.html#method-getCurrent">chrome.tabs.getCurrent()</a> method + returns the tab associated with the currently executing script </li> + </ul> <h4> Manifest changes </h4> <ul> <li>The <a href="manifest.html#geolocation">geolocation</a> permission - gives an extension access to the user's physical location - </li><li><a href="match_patterns.html">Match patterns</a> can now select all - schemes or all URLs - </li><li>Access to file:/// URLs no longer triggers the "access to your machine" + gives an extension access to the user's physical location </li> + <li><a href="match_patterns.html">Match patterns</a> can now select all + schemes or all URLs </li> + <li>Access to file:/// URLs no longer triggers the "access to your machine" security warning, but now requires user opt-in from the extensions - management page - </li></ul> + management page </li> + </ul> </div> |