summaryrefslogtreecommitdiffstats
path: root/components/translate
Commit message (Collapse)AuthorAgeFilesLines
* Complete WebStateObserverBridge and follow Cocoa naming style.jyquinn2015-04-152-2/+2
| | | | | | | | | | Adds remaining WebStateObserver methods to WebStateObserverBridge and updates CRWWebStateObserver protocol methods to follow Cocoa style guidelines for naming delegate methods. Review URL: https://codereview.chromium.org/1079693002 Cr-Commit-Position: refs/heads/master@{#325277}
* Change CompareString16WithCollator to take const ref collator.estade2015-04-111-2/+2
| | | | | | | | BUG=none Review URL: https://codereview.chromium.org/1078983003 Cr-Commit-Position: refs/heads/master@{#324774}
* Removed dependencies to CRWJSEarlyScriptManager.eugenebut2015-04-011-5/+0
| | | | | | | | | | | | | All JS Managers implicitly depend on CRWJSEarlyScriptManager since CRWWebController always inject early scipts first. CRWJSEarlyScriptManager will be removed from web/ public interface. BUG=449203 Review URL: https://codereview.chromium.org/1046273002 Cr-Commit-Position: refs/heads/master@{#323247}
* Fix uninit memory access in TranslateManagerRenderViewHostTests.thestig2015-03-091-1/+3
| | | | | | | | BUG=464837 Review URL: https://codereview.chromium.org/983283002 Cr-Commit-Position: refs/heads/master@{#319614}
* Fixed dependencies for JsLanguageDetectionManager.eugenebut2015-03-051-3/+2
| | | | | | | | | | | | | | | | Made JsLanguageDetectionManager depend on CRWJSEarlyScriptManager, instead of CRWJSBaseManager and CRWJSMessageManager. Embedded's JS managers should not depend any other managers except CRWJSEarlyScriptManager. Also upstreamed modified CRWJSEarlyScriptManager. BUG=449203 Review URL: https://codereview.chromium.org/981673002 Cr-Commit-Position: refs/heads/master@{#319310}
* [iOS] Fix DCHECK in ShouldShowAlwaysTranslateShortcut()droger2015-03-031-0/+6
| | | | | | | | | This CL upstreams a small fork in ShouldShowAlwaysTranslateShortcut on iOS, which is caused by a different UX on this platform. Review URL: https://codereview.chromium.org/972123002 Cr-Commit-Position: refs/heads/master@{#318864}
* Minor infobar cleanup.pkasting2015-02-242-22/+22
| | | | | | | | | | | | | | | | | | * Stop calling GetIconID() as a proxy for having RTTI to detect ThreeDAPIInfoBarDelegates. Just add a downcast function. * Slightly more reasonable base class function order. * Fix declaration/definition orders to match base class (and each other) in other instances where it was noticeably wrong. * Keep infobar code consistent about not inlining method definitions in class declarations, and making overridden functions private unless otherwise necessary. BUG=none TEST=none Review URL: https://codereview.chromium.org/922953002 Cr-Commit-Position: refs/heads/master@{#317685}
* Sort GN files under componentssatorux2015-02-162-4/+4
| | | | | | | | | | | | For tools/sort_sources.py to be useful, existing GN files should be sorted. BUG=456014 TEST=everything should build as before Review URL: https://codereview.chromium.org/934483002 Cr-Commit-Position: refs/heads/master@{#316447}
* Make DataFileRendererCldDataProvider's LoadCldData method public.andrewhayden2015-01-121-3/+10
| | | | | | | | | | | | There's no reason that it needs to be private, and if another class wants to compose this with additional functionality, it makes sense for it to be public. BUG=367239 TBR=toyoshim Review URL: https://codereview.chromium.org/845263002 Cr-Commit-Position: refs/heads/master@{#311039}
* Upstream //ios/chrome/browser/translatedroger2015-01-083-0/+16
| | | | | | | | | | | This CL upstreams the iOS translate client code, and the iOS resources infrastructure. TBR=asvitkine Review URL: https://codereview.chromium.org/809333003 Cr-Commit-Position: refs/heads/master@{#310513}
* Added |load_completion_status| to WebStateObserver's |PageLoaded|.kkhorimoto2015-01-072-3/+6
| | | | | | | | | | | | This CL also introduces the web::PageLoadCompletionStatus enum. This was done to support future WebStateObserver subclasses that require notifications of failed page loads. BUG=none Review URL: https://codereview.chromium.org/835203002 Cr-Commit-Position: refs/heads/master@{#310188}
* Standardize usage of virtual/override/final specifiers in components/.dcheng2014-12-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Google C++ style guide states: Explicitly annotate overrides of virtual functions or virtual destructors with an override or (less frequently) final specifier. Older (pre-C++11) code will use the virtual keyword as an inferior alternative annotation. For clarity, use exactly one of override, final, or virtual when declaring an override. To better conform to these guidelines, the following constructs have been rewritten: - if a base class has a virtual destructor, then: virtual ~Foo(); -> ~Foo() override; - virtual void Foo() override; -> void Foo() override; - virtual void Foo() override final; -> void Foo() final; This patch was automatically generated. The clang plugin can generate fixit hints, which are suggested edits when it is 100% sure it knows how to fix a problem. The hints from the clang plugin were applied to the source tree using the tool in https://codereview.chromium.org/598073004. Several formatting edits by clang-format were manually reverted, due to mangling of some of the more complicate IPC macros. BUG=417463 TBR=blundell@chromium.org Review URL: https://codereview.chromium.org/824513003 Cr-Commit-Position: refs/heads/master@{#309781}
* Make callers of CommandLine use it via the base:: namespace.avi2014-12-226-6/+7
| | | | | | | | | | | | Covers cloud_print/ and components/. BUG=422426 TEST=none TBR=ben@chromium.org Review URL: https://codereview.chromium.org/818103002 Cr-Commit-Position: refs/heads/master@{#309475}
* replace COMPILE_ASSERT with static_assert in components/mostynb2014-12-222-4/+4
| | | | | | | | BUG=442514 Review URL: https://codereview.chromium.org/794683005 Cr-Commit-Position: refs/heads/master@{#309464}
* Use an exponential timeout falloff for translate CLD requestsjdduke2014-12-171-1/+11
| | | | | | | | | | | | | | The TranslateHelper kicks off a (potentially non-termiting) series of requests for CLD data until it gets a valid response. As there are (currently) no guarantees that a valid response will be received, change the repeat timeout from a fixed 1s delay to a delay that decays gracefully over time. BUG=437869 Review URL: https://codereview.chromium.org/793643004 Cr-Commit-Position: refs/heads/master@{#308799}
* Upstream components/translate/iosdroger2014-12-1616-0/+1666
| | | | | | Review URL: https://codereview.chromium.org/809693003 Cr-Commit-Position: refs/heads/master@{#308676}
* gn format //componentsscottmg2014-12-033-3/+0
| | | | | | | | | | | No intended functionality change. R=brettw@chromium.org BUG=348474 Review URL: https://codereview.chromium.org/780633002 Cr-Commit-Position: refs/heads/master@{#306640}
* remove some calls to to-be-deprecated v8::Value::To* functionsdcarney2014-11-211-1/+1
| | | | | | | | | | R=jochen@chromium.org TBR=kalman@chromium.org BUG= Review URL: https://codereview.chromium.org/753523002 Cr-Commit-Position: refs/heads/master@{#305209}
* Cleanup: Use http/https constants in components.thestig2014-11-191-5/+3
| | | | | | Review URL: https://codereview.chromium.org/726923004 Cr-Commit-Position: refs/heads/master@{#304851}
* Hopefully final set of changes needed to make it possible for embedders toandrewhayden2014-11-1811-83/+164
| | | | | | | | | | | | | | | | | customize the CLD data source. Introduces a RendererCldDataProviderFactory that is analogous to the BrowserCldDataProviderFactory; it was initially thought that this would not be needed, but it allows embedders to statically configure the factory anywhere on the render thread - by far the easiest way for the embedder to integrate the desired implementation. Also adds a bit of DVLOG to help runtime debugging of the data source. No other significant changes. BUG= Review URL: https://codereview.chromium.org/728413002 Cr-Commit-Position: refs/heads/master@{#304581}
* Convert Chinese lang codes with a region code to a compatible lang codehajimehoshi2014-11-137-65/+43
| | | | | | | | | | | | | Convert zh-HK, zh-MO, zh-SG to their compatible language codes such as zh-CN and zh-TW. This will help to show Translate UI on websites in the Chinese langs with the region codes. BUG=409606 TEST=components_unittests --gtest_filter=Language*:Translate*, unit_tests --gtest_filter=Translate*, browser_tests --gtest_filter=ChromeRenderViewTest.LanguageCommonMistakesAreCorrected Review URL: https://codereview.chromium.org/715593002 Cr-Commit-Position: refs/heads/master@{#303981}
* Refactor language detection logic to allow non-static CLD data sources.andrewhayden2014-11-1128-369/+692
| | | | | | | | | | | | | | | | | This change further refines the approach taken in setting the implementation used for accessing compact language detector at runtime. It is based upon the pattern used in content_client.h, though adapted for this specific use case. Fundamentally, there is a switch from having exactly one linked-in class define a global method to instead having the high-level targets (like the content shell, chrome shell, and so on) be responsible for setting the implementation that is desired. This eliminates a lot of the ugly GYP/GN logic, but requires work for each high-level target. BUG=367239 Review URL: https://codereview.chromium.org/461633002 Cr-Commit-Position: refs/heads/master@{#303669}
* Cleanup: Remove unneeded path_service.h includes.thestig2014-11-061-1/+0
| | | | | | Review URL: https://codereview.chromium.org/689563002 Cr-Commit-Position: refs/heads/master@{#303095}
* Removing instrumentations for task URLFetcherCore::OnCompletedURLRequestvadimt2014-11-043-37/+0
| | | | | | | | | | | | The jank almost disappeared, either because it was fixed, or its numbers were absorbed by other instrumentations. At the current moment in Win, instrumentation for OAuth2AccessTokenFetcherImpl::OnURLFetchComplete shown 1.65 118ms jph, and remaining own jankiness of URLFetcherCore::OnCompletedURLRequest is 2.87. BUG=422577 TBR=toyoshim@chromium.org, dconnelly@chromium.org, pkasting@chromium.org, zea@chromium.org, yoz@chromium.org, mmenke@chromium.org, dcheng@chromium.org, mattm@chromium.org, jhawkins@chromium.org, rogerta@chromium.org Review URL: https://codereview.chromium.org/701463004 Cr-Commit-Position: refs/heads/master@{#302620}
* Switching profiler instrumentations from ScopedProfile to ScopedTracker. ↵vadimt2014-10-293-17/+17
| | | | | | | | | | | | This will disable the instrumentations in all channels except Canary, and developer build. Instrumentations are only enabled in Browser process. This will prevent Stable from sending increased amounts of UMA logs. Also, this will let us observe "true" (untouched by instrumentations) jankiness numbers every week in Dev channel. BUG=401560 Review URL: https://codereview.chromium.org/686963002 Cr-Commit-Position: refs/heads/master@{#301950}
* Standardize usage of virtual/override/final specifiers.dcheng2014-10-291-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Google C++ style guide states: Explicitly annotate overrides of virtual functions or virtual destructors with an override or (less frequently) final specifier. Older (pre-C++11) code will use the virtual keyword as an inferior alternative annotation. For clarity, use exactly one of override, final, or virtual when declaring an override. To better conform to these guidelines, the following constructs have been rewritten: - if a base class has a virtual destructor, then: virtual ~Foo(); -> ~Foo() override; - virtual void Foo() override; -> void Foo() override; - virtual void Foo() override final; -> void Foo() final; This patch was automatically generated. The clang plugin can generate fixit hints, which are suggested edits when it is 100% sure it knows how to fix a problem. The hints from the clang plugin were applied to the source tree using the tool in https://codereview.chromium.org/598073004. BUG=417463 R=caitkp@chromium.org Review URL: https://codereview.chromium.org/684513002 Cr-Commit-Position: refs/heads/master@{#301931}
* Add a few missing overrides found by a new clang warning.thakis2014-10-291-1/+1
| | | | | | | | | | | Namely, -Winconsistent-missing-override. No behavior change. BUG=428099 TBR=blundell Review URL: https://codereview.chromium.org/652233006 Cr-Commit-Position: refs/heads/master@{#301761}
* Adding instrumentation to locate the source of jankiness.vadimt2014-10-231-0/+22
| | | | | | | | | | | | | Mechanical change that adds instrumentation required to locate the source of jankiness (i.e. a long-running fragment of code executed as a part of the task that causes jank) in the code. See the bug for details on what kind of jank we are after. A number of similar CLs were landed, and none of them caused issues. They've helped to find and fix janky code. The code of the instrumentation is highly optimized and is not expected to affect performance. The code simply creates a diagnostic task which is identical to ones created by PostTask or IPC message handlers. Landing as TBR since this is a mechanical, safe and temporary change. BUG=422577 TBR=toyoshim@chromium.org Review URL: https://codereview.chromium.org/670243003 Cr-Commit-Position: refs/heads/master@{#300812}
* Standardize usage of virtual/override/final in components/dcheng2014-10-2110-71/+63
| | | | | | | | | BUG=417463 TBR=blundell@chromium.org Review URL: https://codereview.chromium.org/666133002 Cr-Commit-Position: refs/heads/master@{#300456}
* Type conversion fixes, components/ edition.pkasting2014-10-171-3/+6
| | | | | | | | | | | This is mostly to fix MSVC warnings about possible value truncation. BUG=81439 TEST=none Review URL: https://codereview.chromium.org/656363002 Cr-Commit-Position: refs/heads/master@{#300134}
* Adding instrumentation to locate the source of jankiness.vadimt2014-10-162-0/+12
| | | | | | | | | | | | | | | | | Mechanical change that adds instrumentation required to locate the source of jankiness (i.e. a long-running fragment of code executed as a part of the task that causes jank) in the code. See the bug for details on what kind of jank we are after. A number of similar CLs were landed, and none of them caused issues. The code of the instrumentation is highly optimized and is not expected to affect performance. The code simply creates a diagnostic task which is identical to ones created by PostTask or IPC message handlers. Landing as TBR since this is a mechanical, safe and temporary change. This CL instruments callbacks of TranslateURLFetcher::OnURLFetchComplete: 1. TranslateLanguageList::OnLanguageListFetchComplete 2. TranslateScript::OnScriptFetchComplete BUG=422577 TBR=andrewhayden@chromium.org Review URL: https://codereview.chromium.org/656183002 Cr-Commit-Position: refs/heads/master@{#299805}
* Adding instrumentation to locate the source of jankiness.vadimt2014-10-111-0/+6
| | | | | | | | | | | | | | | Mechanical change that adds instrumentation required to locate the source of jankiness (i.e. a long-running fragment of code executed as a part of the task that causes jank) in the code. See the bug for details on what kind of jank we are after. A number of similar CLs were landed, and none of them caused issues. The code of the instrumentation is highly optimized and is not expected to affect performance. The code simply creates a diagnostic task which is identical to ones created by PostTask or IPC message handlers. Landing as TBR since this is a mechanical, safe and temporary change. This CL instruments a part of overloads of URLFetcherDelegate::OnURLFetchComplete. More overloads will be instrumented if the source of the jank is not in one of instrumented methods. BUG=422577 TBR=mek@chromium.org, toyoshim@chromium.org, dconnelly@chromium.org, pkasting@chromium.org, mmenke@chromium.org, zea@chromium.org, dcheng@chromium.org, noelutz@google.com, thestig@chromium.org, zelidrag@chromium.org Review URL: https://codereview.chromium.org/648873003 Cr-Commit-Position: refs/heads/master@{#299230}
* [components] Apply automatic range checks to content enum types across IPCanujk.sharma2014-10-092-1/+3
| | | | | | | | | | | This is part of a long-running background task to remove the remaining uses of the unchecked IPC_ENUM_TRAITS() macro. BUG= 246708 Review URL: https://codereview.chromium.org/646543003 Cr-Commit-Position: refs/heads/master@{#298915}
* Add render_frame_host to WebContentsObserver::DidNavigateAnyFrame().mlamouri2014-10-082-0/+2
| | | | | | | | | | | This will allow WebContentsObserver implementations to be aware if a frame hase been navigated without having to worry about provisional load. BUG=304341,421085 Review URL: https://codereview.chromium.org/600043004 Cr-Commit-Position: refs/heads/master@{#298722}
* replace OVERRIDE and FINAL with override and final in components/mostynb2014-10-0610-52/+52
| | | | | | | | BUG=417463 Review URL: https://codereview.chromium.org/623133002 Cr-Commit-Position: refs/heads/master@{#298237}
* Rename component_resources.h to components_resources.hhashimoto2014-09-251-1/+1
| | | | | | | | | | | So no need to remember the correct header name for one for string resources and one for image resources. BUG=416395 TBR=jochen@chromium.org for name fix under chrome Review URL: https://codereview.chromium.org/601733002 Cr-Commit-Position: refs/heads/master@{#296673}
* Move PageTransition from //content/public/common to //ui/baseSylvain Defresne2014-09-191-4/+4
| | | | | | | | | | | | | Move PageTransition enumeration from //content/public/common to //ui/base so that it can be used by iOS and layered components that are used on iOS. BUG=372373 R=avi@chromium.org, ben@chromium.org, wfh@chromium.org TBR=ben, nasko Review URL: https://codereview.chromium.org/562603002 Cr-Commit-Position: refs/heads/master@{#295686}
* Move TranslateHelper to the translate component.droger2014-09-174-0/+933
| | | | | | | | | | | | | | | This CL moves TranslateHelper to the translate component. A couple dependencies had to be injected, through the constructor: - extensions (group and scheme) - isolated world id BUG=335087 TBR=jochen Review URL: https://codereview.chromium.org/564793003 Cr-Commit-Position: refs/heads/master@{#295276}
* Move Translate browser-side IPC handling to the component.droger2014-09-162-14/+83
| | | | | | | | | | | | | | | | | | | | | This CL moves a bit of translate logic from chrome/ to the translate component. Some IPC messages are still forwarded to chrome (through ContentTranslateDriver::Observer) because of translate notifications. This is temporary though, because once translate notifications are removed, ChromeTranslateClient will no longer need to be an Observer. Another motivation for this change is that the renderer-side of translate IPC (TranslateHelper) is moving to the component (in another CL), and thus the browser-side has to move too for consistency (this CL). BUG=335087 TBR=msw Review URL: https://codereview.chromium.org/564743002 Cr-Commit-Position: refs/heads/master@{#295073}
* Move navigation handling code from TranslateClient to TranslateDriverdroger2014-09-102-3/+139
| | | | | | | | | | | This CL moves code from chrome/ (ChromeTranslateClient) to the translate component (ContentTranslateDriver). BUG=331509 Review URL: https://codereview.chromium.org/558663003 Cr-Commit-Position: refs/heads/master@{#294157}
* Remove implicit conversions from scoped_refptr to T* in components/dcheng2014-08-261-1/+3
| | | | | | | | | | | This patch was generated by running the rewrite_scoped_refptr clang tool on a Linux build. BUG=110610 Review URL: https://codereview.chromium.org/500383003 Cr-Commit-Position: refs/heads/master@{#291964}
* Work on GN build of Chrome.Brett Wilson2014-08-261-0/+9
| | | | | | | | | | | Fixes the rest of the non-rtc and non-vpx linker errors for the chrome target. BUG= R=ajwong@chromium.org Review URL: https://codereview.chromium.org/505853003 Cr-Commit-Position: refs/heads/master@{#291952}
* Add some remoting targets to GN build.Brett Wilson2014-08-251-0/+2
| | | | | | | | | | | | | | | Since GN runs its scripts in a different current directory than GYP, I had to update the remoting html template script to be able to handle this situation. Also includes many misc linking fixes: - Sets enable_nacl to false. - Add renderer context menu component - Adds many missing files R=sergeyu@chromium.org Review URL: https://codereview.chromium.org/498773005 Cr-Commit-Position: refs/heads/master@{#291731}
* Revert 289312 "Move StringToUpperASCII and LowerCaseEqualsASCII ..."brettw@chromium.org2014-08-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | > Move StringToUpperASCII and LowerCaseEqualsASCII to the base namespace > > Convert LowerCaseEqualsASCII to take StringPiece. In the current patch this is > generally a NOP but will allow me to delete the other 4 variants in a followup > (wanted to do that separately since that will require more review, since > callsites will be changed in nontrivial ways). > > In some cases, LowerCaseEqualsASCII is called with a WebString, which no > longer is implicitly converted. I added base::string16(...) around such > calls to force the right conversion. It happened in these files: > window_container_type.cc > savable_resources.cc > render_view_impl.cc > blink_ax_tree_source.cc > password_form_conversion_utils.cc > translate_helper.cc > chrome_render_view_observer.cc > dom_serializer_browsertest.cc > > R=jamesr@chromium.org > > Review URL: https://codereview.chromium.org/448143008 TBR=brettw@chromium.org Review URL: https://codereview.chromium.org/474483002 Cr-Commit-Position: refs/heads/master@{#289320} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@289320 0039d316-1c4b-4281-b951-d872f2087c98
* Move StringToUpperASCII and LowerCaseEqualsASCII to the base namespacebrettw@chromium.org2014-08-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Convert LowerCaseEqualsASCII to take StringPiece. In the current patch this is generally a NOP but will allow me to delete the other 4 variants in a followup (wanted to do that separately since that will require more review, since callsites will be changed in nontrivial ways). In some cases, LowerCaseEqualsASCII is called with a WebString, which no longer is implicitly converted. I added base::string16(...) around such calls to force the right conversion. It happened in these files: window_container_type.cc savable_resources.cc render_view_impl.cc blink_ax_tree_source.cc password_form_conversion_utils.cc translate_helper.cc chrome_render_view_observer.cc dom_serializer_browsertest.cc R=jamesr@chromium.org Review URL: https://codereview.chromium.org/448143008 Cr-Commit-Position: refs/heads/master@{#289312} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@289312 0039d316-1c4b-4281-b951-d872f2087c98
* Move StringToLowerASCII to base namespacebrettw@chromium.org2014-08-071-2/+2
| | | | | | | | TBR=sky Review URL: https://codereview.chromium.org/448853002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@288085 0039d316-1c4b-4281-b951-d872f2087c98
* Replace the use of CLD_DATA_FROM* and CLD-related ifdefs with runtime checks.andrewhayden@chromium.org2014-07-304-10/+49
| | | | | | | | | | | | | | This, along with other changes described in crbug/367239, allows refactoring of the build logic to allow per-target customization of the CLD data source. This, in turn, allows chrome_shell to be built with statically-linked CLD even if other things (such as the full browser) are not. BUG=367239 TBR=toyoshim@chromium.org Review URL: https://codereview.chromium.org/424123003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@286487 0039d316-1c4b-4281-b951-d872f2087c98
* Add a new "Configure" mechanism to CLD browser-side data interfaces.andrewhayden@chromium.org2014-07-304-17/+34
| | | | | | | | | | | | | | | | | This allows test code to be included all the time, regardless of whether a non-static CLD build is in use. It also decouples sources from needing to include an implementation-specific header to configure CLD, which eliminates much of the need for the "#if defined" statements in code. Coupled with the new CldDataSource (see related bug), this will allow a significant refactoring of the build logic which will make it possible to build chrome_shell and other targets with target-specific CLD configurations. BUG=367239 TBR=toyoshim@chromium.org Review URL: https://codereview.chromium.org/424053002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@286430 0039d316-1c4b-4281-b951-d872f2087c98
* Add a new CldDataSource class that can be queried at runtime.andrewhayden@chromium.org2014-07-295-0/+82
| | | | | | | | | | | | | | This will allow several "#if defined" statements to be replaced with runtime checks, simplifying the build process and eliminating the need to generate multiple libraries for several targets when building Android's chrome_shell in the presence of non-static CLD data sources. BUG=367239 TBR=toyoshim Review URL: https://codereview.chromium.org/422843009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@286177 0039d316-1c4b-4281-b951-d872f2087c98
* Fix translate namespacenaiem.shaik@gmail.com2014-07-2243-89/+269
| | | | | | | | | | | | | Translate is turned into a component, classes and functions have to be moved to the translate:: namespace. BUG=331782 TEST=components_unittests:unit_tests --gtest_filter=Translate* TBR=thakis Review URL: https://codereview.chromium.org/378253002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@284742 0039d316-1c4b-4281-b951-d872f2087c98