[Mac]Port browser_keyevents_browsertest.cc and browser_focus_uitest.cc to Mac.

This CL includes:
1. Implementation of ui_test_utils_mac.mm
2. Fix for ui_controls_mac.mm
3. Port browser_keyevents_browsertest.cc to Mac and add some new tests for Mac.
4. Partially port browser_focus_uitest.cc to Mac, now can be compiled and run
on Mac but some tests fail.
5. Add two functions into ui_test_utils.h: HideNativeWindow() and
ShowAndFocusNativeWindow(). The latter one shows a window and grabs the input
focus, which is useful for tests depending on fake keyboard/mouse events.

Because browser_keyevents_browsertests.cc and browser_focus_uitest.cc
belong to interactive_ui_tests, which is not available on Mac (see
http://crbug.com/21276), in order to test them on Mac, you may want to
move them into browser_tests locally. But it won't work on build and try
bots, because these tests must be run with screen unlocked.

This CL depends on CL: http://codereview.chromium.org/2973004
and http://codereview.chromium.org/2805075

BUG=22515 Keyboard handling needs unit tests
BUG=48671 interactive_ui_test: BrowserKeyEventsTest.NormalKeyEvents is flaky
BUG=48936 Browser window is opened inactivated when running an InProcessBrowserTest.
TEST=none

Review URL: http://codereview.chromium.org/2986004

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53840 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/base/base.gypi b/base/base.gypi
index ff05d2ae..2553ab5 100644
--- a/base/base.gypi
+++ b/base/base.gypi
@@ -421,6 +421,8 @@
           'json/string_escape.h',
           'keyboard_code_conversion_gtk.cc',
           'keyboard_code_conversion_gtk.h',
+          'keyboard_code_conversion_mac.mm',
+          'keyboard_code_conversion_mac.h',
           'keyboard_codes.h',
           'keyboard_codes_win.h',
           'keyboard_codes_posix.h',