Cast icon should show in sync with media controls

Created a listener in ContentVideoViewLegacy that interested classes can
use to listen for changes in the media controls visibility. Also changed
the touch listener to listen to the whole screen instead of just the
surface view for toggling the media controls visibility.

The corresponding downstream CL:
https://chrome-internal-review.googlesource.com/#/c/155197/

The original CL by maybelle@:
https://codereview.chromium.org/164273002/

BUG=341498
NOTRY=true

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252195 0039d316-1c4b-4281-b951-d872f2087c98
Avoid stack overflow write 1 in ipc fuzzer.

Since IPC fuzzer compiles outside of the normal chromium build,
there can be some symbols which we don't properly get defined,
so define them locally for now.

TBR=aedla@chromium.org

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252196 0039d316-1c4b-4281-b951-d872f2087c98
Refactor Windows MessageBox fallback code.

Inline the Windows-specific NativeShowMessageBox.
Pass the parent HWND argument to the underlying call.
Use MB_ICONQUESTION for MESSAGE_BOX_TYPE_QUESTION.

BUG=NONE
TEST=No Win MessageBox regressions; better icon for any fallback question MessageBox.
R=sky@chromium.org

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252197 0039d316-1c4b-4281-b951-d872f2087c98
Added NULL pointer check for DEVMODE.

BUG=344982
NOTRY=true

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252198 0039d316-1c4b-4281-b951-d872f2087c98
Remove --disable-fullscreen switch

BUG=343996

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252200 0039d316-1c4b-4281-b951-d872f2087c98
Avoids releasing pointer grab prematurely

BUG=338247
TEST=
1.Launch chrome://settings..ctrl+D,save the Bookmark in Bookmark Bar.
2.Open 3 to 4 new Tabs via ctrl+T,in chrome://settings page Drag the Bookmark from the Bookmark Bar.
3.Hover the Dragged Bookmark over the second New-Tab and Release the Bookmark over the New-Tab.
4.Hover the Dragged Bookmark over the third New-Tab (the tab gets activated) and Release the Bookmark over the New-Tab.
5.Close browser - should not crash.

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252201 0039d316-1c4b-4281-b951-d872f2087c98
[cc] cleanup: remove useless comments in UpdateStateOnActivation()

BUG=None
TEST=None, no functional changes.
R=brianderson@chromium.org

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252203 0039d316-1c4b-4281-b951-d872f2087c98
Update OWNERS file for IPC fuzzer.

NOTRY=true
TBR=mbarbella@chromium.org
TBR=inferno@chromium.org

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252204 0039d316-1c4b-4281-b951-d872f2087c98
Added early out for pinch to prevent crash when no inner scroll layer.

The layer tree seems to receive gesture events before it's initialized
(or while being destroyed). This means the pinch events get executed
while InnerViewportScrollLayer() == NULL, which was assumed to be non
NULL. The event handler should probably not be sending events to an
uninitialized layer tree but in the mean time I've disabled the
DCHECK and added an early out to prevent crashes.

BUG=340303

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252205 0039d316-1c4b-4281-b951-d872f2087c98
Part 6 of search provider refactoring.

Makes changes to how the state is recorded in zero_suggest_provider
to facilitate moving out ParseSuggestResults into super class.

Replaces navigation_results_, query_matches_map_, and
verbatim_relevance_ objects with a Results results_ instance. The latter
keeps track of navigation_results_ and query_results_ and constructs
the query matches map on when it's needed.

verbatim_relevance_ in the old code is only used to see the current url
match (based on the server relevance returned in the previous request
or a static value). The new code keeps track of the server verbatim
relevance in results_ and uses an accessor to get either server results
or a constant value if no server results are available, matching the
old semantics.

Merged FillResults with ParseSuggestResults function and moved match
map creation code into ConvertResultsToAutocompleteMatches where it's
used.

BUG=338955
TBR=mpearson

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252206 0039d316-1c4b-4281-b951-d872f2087c98
Only run Java checkstyle on Upload and not Submit.

BUG=None
NOTRY=true

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252207 0039d316-1c4b-4281-b951-d872f2087c98
Fix encoding of UTF-8 characters sent to Google speech server.

BUG=333515

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252208 0039d316-1c4b-4281-b951-d872f2087c98
TSan v2 suppressions:
  - race on WTF::s_shutdown (issue 345240)
  - races in WebRtcBrowserTest.CallWithDataAndMedia (issue 345245)
  - race on cc::s_next_layer_id (issue 345251)

BUG=345240,345245,345251
TBR=earthdok@chromium.org

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252209 0039d316-1c4b-4281-b951-d872f2087c98
[invalidations] Added table with registered objectsIds

This patch is a follow-up to issue 147353011.

The patch adds a display mechanism for the about:invalidations page
that shows a table with every implementer of InvalidationHandler that
has registered for at least one ObjectId for invalidations. The table
also registers for every ObjectId how many invalidations were received
of that kind, the last time one of those arrived and what was the
payload it contained, in case there were any.

There are minimal modifications to every file that implemented
InvalidationHandler because there was a small change in the interface,
in order to be able to return a string stating who is the owner of the
InvalidationHandler without passing raw pointers around.

BUG=263863

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252210 0039d316-1c4b-4281-b951-d872f2087c98
Adding new always maximized mode

This is (at this time) not complete. There are some outstanding issues to be resolved marked with TODO(skuhne) which I will address before submitting. This is meant to be a "preview".

What does it do?

It tracks the creation of all browsers / V1 / V2 applications and maximizes them automatically. Non maximizable windows will get centered and a layer will be put behind them. Note that not all windows can be maximized. Dialogs, tray, .. will remain in their window state.

The missing things:
- Background cover layer
- Removing of the restore button from the caption (different CL)
- Suppression of restore / fullscreen request events of any of the tracked windows.

BUG=337563
TEST=unit tests

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252211 0039d316-1c4b-4281-b951-d872f2087c98
Update ASAn/Android runtime and enable stack overflow detection.

LLVM r201571.

AddressSanitizer now prints "stack-overflow" report with all the stack
traces when it catches a SEGV caused by stack overflow.

BUG=263749
R=bulach@chromium.org

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252212 0039d316-1c4b-4281-b951-d872f2087c98
Fix a compilation issue when building with VS2013 and optimization set to "max".

For some reasons (I'm still trying to find them) those 2 DCHECKs make the link step to fail when building nacl64.exe (and maybe some other target) with VS2013 and optimization set to 'max'

Here's the error that I get:
[1537/6627] LINK_EMBED nacl64.exe
FAILED: D:\src\depot_tools\python276_bin\python.exe gyp-win-tool link-with-manifests environment.x64 True nacl64.exe "D:\src\depot_tools\python276_bin\python.exe gyp-win-tool link-wrapper environment.x64 False link.exe /nologo /OUT:nacl64.exe @nacl64
.exe.rsp" 1 mt.exe rc.exe "obj\chrome\chrome_nacl_win64.nacl64.exe.intermediate.manifest" obj\chrome\chrome_nacl_win64.nacl64.exe.generated.manifest ..\..\build\win\compatibility.manifest
LibDef: Total time = 0.015s
  OptRef: Total time = 0.000s
Generating code
d:\src\chrome\src\sandbox\win\src\sharedmem_ipc_client.cc(34) : fatal error C1001: An internal error has occurred in the compiler.
(compiler file 'f:\dd\vctools\compiler\utc\src\p2\main.c', line 227)
 To work around this problem, try simplifying or changing the program near the locations listed above.
Please choose the Technical Support command on the Visual C++
 Help menu, or open the Technical Support help file for more information
INTERNAL COMPILER ERROR in 'C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\BIN\amd64\link.exe'
    Please choose the Technical Support command on the Visual C++
    Help menu, or open the Technical Support help file for more information
Final: Total time = 27.940s
Traceback (most recent call last):
  File "gyp-win-tool", line 293, in <module>
    sys.exit(main(sys.argv[1:]))
  File "gyp-win-tool", line 28, in main
    exit_code = executor.Dispatch(args)
  File "gyp-win-tool", line 70, in Dispatch
    return getattr(self, method)(*args[1:])
  File "gyp-win-tool", line 158, in ExecLinkWithManifests
    subprocess.check_call(ldcmd + add_to_ld)
  File "D:\src\depot_tools\python276_bin\lib\subprocess.py", line 540, in check_call
    raise CalledProcessError(retcode, cmd)

This CL fix this, for the first dcheck it might be because we're comparing a LONG to a ChannelState (and the linker he's unhappy when looking for the conversion routine), but for the second one I have really no idea what's happening, all I know is that using DCHECK_LE instead of DCHECK shouldn't change anything here, and that it fix the build.


R=cpu@chromium.org
CC=scottmg@chromium.org

BUG=344980

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252213 0039d316-1c4b-4281-b951-d872f2087c98
Fix crash which occurs when a widget destroys itself as a result of ET_GESTURE_TAP_DOWN 

BUG=342867
TEST=WidgetTest.WidgetDeleted_InDispatchGestureEvent

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252214 0039d316-1c4b-4281-b951-d872f2087c98
Add Locale Request Support to Chrome Now

BUG=164227

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252215 0039d316-1c4b-4281-b951-d872f2087c98
Refactor to support default Bluetooth pairing delegate

In order to support a default pairing delegate we need to move the agent
service provider delegate implementation from BluetoothDevice to
BluetoothAdapter while retaining the existing API.

BUG=338492
TEST=device_unittests, unit_tests, browser_tests

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

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