Thread safety in SpellcheckHunspellDictionary

SpellcheckHunspellDictionary posts file read and write tasks to the FILE thread
with unretained pointers to the instance. Chrome crashes if the caller deletes
that instance prior to the task being called. This CL converts these tasks from
SpellcheckHunspellDictionary methods to functions that pass data between
threads.

BUG=174676

Review URL: https://chromiumcodereview.appspot.com/12211055

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182599 0039d316-1c4b-4281-b951-d872f2087c98
Fix an AURA browser crash which occurs at times when the browser window is being closed.

The crash occurs in the newly added helper function chrome::ShouldUseNativeFrame which
checks whether the browser view passed in is a normal tabbed browser. 

This function in AURA can get called during the window destruction sequence i.e in the
context of the BrowserView destructor where we NULL out the browser_ pointer maintained
in the BrowserView class.

This crash has not been seen on non AURA chrome.

Fix for aura chrome is to check whether the browser in the BrowserView class is valid
in the BrowserDesktopRootWindowHostWin::ShouldUseNativeFrame function.

TBR'ing sky as this seems to be a frequent crash. Will address comments in a follow up.

BUG=176418
TBR=sky
Review URL: https://codereview.chromium.org/12252056

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182600 0039d316-1c4b-4281-b951-d872f2087c98
Prevent bindings escalation on an existing NavigationEntry (attempt 2).

BUG=173672
TEST=See bug for repro steps.

Review URL: https://codereview.chromium.org/12210048

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182602 0039d316-1c4b-4281-b951-d872f2087c98
Revert 182241

This seems to have broken the Mac ASAN LKGR builders.  For example:
http://build.chromium.org/p/chromium.lkgr/builders/Mac%20ASAN%20Release/builds/1188/steps/compile/logs/stdio

> Roll Clang r170392:r174491.
> 
> BUG=174873, 170629
> 
> Review URL: https://codereview.chromium.org/12220089

TBR=hans@chromium.org
Review URL: https://codereview.chromium.org/12256052

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182603 0039d316-1c4b-4281-b951-d872f2087c98
Fix VirtualPath::GetComponents to handle drive letter string as usual path component

Also fix the function comment as the existing code seems to handle the '.' component correctly (and so does the new code).

BUG=none
TEST=FileSystemUtilTest.VirtualPathGetComponents

Review URL: https://codereview.chromium.org/12253006

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182604 0039d316-1c4b-4281-b951-d872f2087c98
split test_registrar target into a new win8_tests.gyp.

r171366 introduced a new 'test_registrar' binary that depends on chrome
into the win8.gyp file; unfortunately, the win8.gyp file is needed by
printing.gyp, which is needed by webkit_support, making the webkit files
now have a circular dependency on chrome, and breaking the webkit.org
win builds, which don't check out chrome/ at all.

This change fixes this temporarily (?) by moving the test binary into
a separate gyp file, but we probably need to do something else to avoid
making ash and win8 depend on chrome.

R=ananta@chromium.org, sky@chromium.org

Review URL: https://codereview.chromium.org/12207186

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182605 0039d316-1c4b-4281-b951-d872f2087c98
views: Dispatch key, touch, scroll and gesture events using the EventDispatch interface.

BUG=173235, 159632

Review URL: https://codereview.chromium.org/12207092

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182609 0039d316-1c4b-4281-b951-d872f2087c98
Revert 176828
> Fix for Web Popup menus.
> 
> Bugs: Web Popups neglected to get mouse capture which they need for proper behavior including dismissal. The Popup would stay up (when clicking outside of browser window or in caption area) or underlying web content may change table row highlighing if the mouse is moved over it (which should not happen while the Web Popup is up).
> 
> Solution: Give web popups mouse capture. Clicking anywhere dismisses them. Underlying web content does not get mouse events. Care has to be taken to get capture after the web popup is visible otherwise "get capture" will not succeed. Also, we must prevent the parent from grabbing and holding onto mouse capture leaving the Web Popup unusable.
> 
> BUG=169245
> TEST=manual
> 
> Scenario:
> Navigate to crbug.com, click the Pulldown menu behind "Search", click at various locations, try to drag the browser window. Observe that Web Popup is dismissed.
> 
> Scenario:
> navigate to
> http://www.w3schools.com/tags/tryit.asp?filename=tryhtml_select
> Click on the "car name" to bring up the pop-up, click at various locations, try to drag the browser window. Observe that Web Popup is dismissed.
> 
> Scenario:
> OOBE screen on Chromebox; keyboard pulldown, click ... (as above)
> 
> Review URL: https://chromiumcodereview.appspot.com/11854002

BUG=174247
TEST=manual
TBR=sky@chromium.org


Review URL: https://chromiumcodereview.appspot.com/12255019

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182610 0039d316-1c4b-4281-b951-d872f2087c98
Remove SpdySettingsControlFrame struct. Useful for Spdy 4 Development.

This lands server change 42145783.

Review URL: https://codereview.chromium.org/12230032

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182611 0039d316-1c4b-4281-b951-d872f2087c98
searchbox -> embeddedsearch API, part 1.


BUG=


Review URL: https://chromiumcodereview.appspot.com/12248005

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182612 0039d316-1c4b-4281-b951-d872f2087c98
Files.app: Enable presubmit error checker with jslint under file_manager/ directory.

We've just cleaned up the code under C/B/resources/file_manager. So we add the directory to the list of cleaned directories.

BUG=175657
TEST=none
R=dbeam@chromium.org

Review URL: https://codereview.chromium.org/12254034

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182613 0039d316-1c4b-4281-b951-d872f2087c98
Add ability to draw only the selected portion of text in RenderText so that we
can provide a drag image when the user tries to drag selected text.

BUG=115237


Review URL: https://chromiumcodereview.appspot.com/12262043

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182614 0039d316-1c4b-4281-b951-d872f2087c98
Fix a bug where extensions created with locale info from the command line is broken.

Register the ManifestHandler for default_locale

BUG=176187
TEST=1. Unzip the test.zip attachment from issue 176187.
2. Use chrome to pack it as an extension (chrome --pack-extension=test).
test.crx should be created successfully.

Review URL: https://chromiumcodereview.appspot.com/12256041

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182615 0039d316-1c4b-4281-b951-d872f2087c98
[Mac] Fix background apps dock menu.

BUG=175113


Review URL: https://chromiumcodereview.appspot.com/12259032

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182616 0039d316-1c4b-4281-b951-d872f2087c98
move --aura-host-window-size to --ash-host-window-bounds 
remove --use-fullscreen-window as this is no longer necessary.

BUG=none
TEST=none


Review URL: https://chromiumcodereview.appspot.com/12261018

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182617 0039d316-1c4b-4281-b951-d872f2087c98
Alter the ActivityLog db table schemas. 
Remove some arguments from LogDOMAction. 
Rename URIAction to DOMAction. 
Make sure db operations will be OK if we add new columns to tables.

Review URL: https://chromiumcodereview.appspot.com/12262025

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182618 0039d316-1c4b-4281-b951-d872f2087c98
chromeos: Add tests for drive::DriveDownloadHandler

Add tests for SubstituteDriveDownloadPath as the first step.

BUG=161181
TEST=unit_tests --gtest_filter="DriveDownloadHandlerTest.*"

Review URL: https://codereview.chromium.org/12261033

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182621 0039d316-1c4b-4281-b951-d872f2087c98
Translate: Ignore Content-Language value if it is mal-formed code.

If server or page provided Content-Language value contains mal-formed
language code, Chrome should ignore it, then rely on CLD detected one.

BUG=167748
TEST=browser_tests --gtest_filter='TranslateHelperTest.ResetInvalidLanguageCode'

Review URL: https://codereview.chromium.org/12221084

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182624 0039d316-1c4b-4281-b951-d872f2087c98
Fix a bug where an extension's icon wasn't being properly reloaded if it
changes

A query string, which is incremented whenever the extension
Reload button is clicked, is appended to the end of the
extension icon url in order to prevent caching.

Patch from Evan Peterson <evan.peterson.ep@gmail.com>
BUG=159302

Review URL: https://chromiumcodereview.appspot.com/12225147

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182625 0039d316-1c4b-4281-b951-d872f2087c98
Add an outdated upgrade bubble view.

Show a new bubble when the current install is more than on major revision away from what's available.

BUG=151996


Review URL: https://chromiumcodereview.appspot.com/11440020

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@182626 0039d316-1c4b-4281-b951-d872f2087c98