Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(537)

Issue 2894483003: Initialize ios/web_view translate with a system-wide URLRequestContext. (Closed)

Created:
3 years, 7 months ago by michaeldo
Modified:
3 years, 6 months ago
CC:
chromium-reviews, ios-reviews+web_chromium.org, ios-reviews_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Initialize ios/web_view translate with a system-wide URLRequestContext. Add WebViewIOThread and ApplicationContext singleton which manage global application state and WebViewTranslateService which manages the translate lifecycle. BUG=679895, 710948 Review-Url: https://codereview.chromium.org/2894483003 Cr-Commit-Position: refs/heads/master@{#476700} Committed: https://chromium.googlesource.com/chromium/src/+/6c4f1da164a4c4450a9ff9d5ede739bd6f28eef5

Patch Set 1 #

Total comments: 46

Patch Set 2 : Respond to comments. #

Total comments: 1

Patch Set 3 : Respond to comments. #

Patch Set 4 : Move WebViewIOThread to ios/components. #

Patch Set 5 : Remove unneeded deps. #

Total comments: 4

Patch Set 6 : Rebase and respond to comments. #

Patch Set 7 : Add namespace around WebViewIOThread. #

Patch Set 8 : Rebase and add WebViewTranslateService #

Patch Set 9 : Cleanup DEPS and old io_thread class. #

Patch Set 10 : Cleanup. #

Total comments: 31

Patch Set 11 : Respond to comments. #

Total comments: 8

Patch Set 12 : Rebase. #

Patch Set 13 : Respond to comments. #

Total comments: 6

Patch Set 14 : Respond to comments. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+483 lines, -18 lines) Patch
M ios/web_view/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +12 lines, -0 lines 0 comments Download
M ios/web_view/internal/DEPS View 1 2 3 4 5 6 7 8 1 chunk +6 lines, -0 lines 0 comments Download
A ios/web_view/internal/app/application_context.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +94 lines, -0 lines 0 comments Download
A ios/web_view/internal/app/application_context.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +137 lines, -0 lines 0 comments Download
A ios/web_view/internal/app/web_view_io_thread.h View 1 2 3 4 5 6 7 1 chunk +38 lines, -0 lines 0 comments Download
A ios/web_view/internal/app/web_view_io_thread.mm View 1 2 3 4 5 6 7 1 chunk +31 lines, -0 lines 0 comments Download
M ios/web_view/internal/cwv_web_view_configuration.mm View 1 2 3 4 5 6 7 2 chunks +1 line, -10 lines 0 comments Download
A ios/web_view/internal/translate/web_view_translate_service.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +67 lines, -0 lines 0 comments Download
A ios/web_view/internal/translate/web_view_translate_service.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +63 lines, -0 lines 0 comments Download
M ios/web_view/internal/web_view_web_main_parts.h View 1 2 3 4 5 6 7 2 chunks +9 lines, -3 lines 0 comments Download
M ios/web_view/internal/web_view_web_main_parts.mm View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +25 lines, -5 lines 0 comments Download

Messages

Total messages: 41 (11 generated)
michaeldo
This is a first pass at adding the system wide request context. The logic here ...
3 years, 7 months ago (2017-05-18 23:19:16 UTC) #2
Eugene But (OOO till 7-30)
I think someone from net folks should take a look. https://codereview.chromium.org/2894483003/diff/1/ios/web_view/internal/app/application_context.h File ios/web_view/internal/app/application_context.h (right): https://codereview.chromium.org/2894483003/diff/1/ios/web_view/internal/app/application_context.h#newcode25 ...
3 years, 7 months ago (2017-05-18 23:54:55 UTC) #3
Hiroshi Ichikawa
https://codereview.chromium.org/2894483003/diff/1/ios/web_view/internal/app/application_context.h File ios/web_view/internal/app/application_context.h (right): https://codereview.chromium.org/2894483003/diff/1/ios/web_view/internal/app/application_context.h#newcode27 ios/web_view/internal/app/application_context.h:27: class ApplicationContext { Shouldn't this class be inside a ...
3 years, 7 months ago (2017-05-19 02:37:51 UTC) #4
michaeldo
+ sdefresne@ as components owner. I also agree about someone from net looking. + mmenke@, ...
3 years, 7 months ago (2017-05-19 22:02:36 UTC) #6
Eugene But (OOO till 7-30)
https://codereview.chromium.org/2894483003/diff/1/ios/web_view/internal/app/application_context.h File ios/web_view/internal/app/application_context.h (right): https://codereview.chromium.org/2894483003/diff/1/ios/web_view/internal/app/application_context.h#newcode25 ios/web_view/internal/app/application_context.h:25: ApplicationContext* GetApplicationContext(); On 2017/05/19 22:02:35, michaeldo wrote: > On ...
3 years, 7 months ago (2017-05-19 23:32:05 UTC) #7
mmenke
https://codereview.chromium.org/2894483003/diff/20001/ios/web_view/internal/app/web_view_io_thread.mm File ios/web_view/internal/app/web_view_io_thread.mm (right): https://codereview.chromium.org/2894483003/diff/20001/ios/web_view/internal/app/web_view_io_thread.mm#newcode371 ios/web_view/internal/app/web_view_io_thread.mm:371: /*is_quic_force_enabled=*/false, quic_user_agent_id, &params_); I guess this is modelled after ...
3 years, 7 months ago (2017-05-22 17:14:58 UTC) #8
michaeldo
https://codereview.chromium.org/2894483003/diff/1/ios/web_view/internal/app/application_context.h File ios/web_view/internal/app/application_context.h (right): https://codereview.chromium.org/2894483003/diff/1/ios/web_view/internal/app/application_context.h#newcode25 ios/web_view/internal/app/application_context.h:25: ApplicationContext* GetApplicationContext(); On 2017/05/19 23:32:05, Eugene But wrote: > ...
3 years, 7 months ago (2017-05-23 22:38:37 UTC) #9
michaeldo
On 2017/05/22 17:14:58, mmenke wrote: > https://codereview.chromium.org/2894483003/diff/20001/ios/web_view/internal/app/web_view_io_thread.mm > File ios/web_view/internal/app/web_view_io_thread.mm (right): > > https://codereview.chromium.org/2894483003/diff/20001/ios/web_view/internal/app/web_view_io_thread.mm#newcode371 > ...
3 years, 7 months ago (2017-05-23 22:48:44 UTC) #11
Hiroshi Ichikawa
https://codereview.chromium.org/2894483003/diff/1/ios/web_view/internal/app/application_context_impl.cc File ios/web_view/internal/app/application_context_impl.cc (right): https://codereview.chromium.org/2894483003/diff/1/ios/web_view/internal/app/application_context_impl.cc#newcode51 ios/web_view/internal/app/application_context_impl.cc:51: tracked_objects::ThreadData::EnsureCleanupWasCalled(4); On 2017/05/23 22:38:36, michaeldo wrote: > On 2017/05/19 ...
3 years, 7 months ago (2017-05-24 07:25:46 UTC) #13
mmenke
On 2017/05/23 22:48:44, michaeldo wrote: > On 2017/05/22 17:14:58, mmenke wrote: > > > https://codereview.chromium.org/2894483003/diff/20001/ios/web_view/internal/app/web_view_io_thread.mm ...
3 years, 7 months ago (2017-05-24 15:13:01 UTC) #14
michaeldo
On 2017/05/24 15:13:01, mmenke wrote: > On 2017/05/23 22:48:44, michaeldo wrote: > > On 2017/05/22 ...
3 years, 7 months ago (2017-05-24 15:19:36 UTC) #15
michaeldo
I've moved IOThread to components/ios in this CL. However, I'm creating a separate CL to ...
3 years, 7 months ago (2017-05-25 00:18:10 UTC) #16
Eugene But (OOO till 7-30)
https://codereview.chromium.org/2894483003/diff/80001/ios/web_view/internal/app/application_context_impl.cc File ios/web_view/internal/app/application_context_impl.cc (right): https://codereview.chromium.org/2894483003/diff/80001/ios/web_view/internal/app/application_context_impl.cc#newcode139 ios/web_view/internal/app/application_context_impl.cc:139: std::max(std::min<int>(net::kDefaultMaxSocketsPerProxyServer, 99), Do you want to use local variables ...
3 years, 7 months ago (2017-05-25 00:39:11 UTC) #17
michaeldo
PTAL now at the latest patch as well as the dependent CL! https://codereview.chromium.org/2894483003/diff/80001/ios/web_view/internal/app/application_context_impl.cc File ios/web_view/internal/app/application_context_impl.cc ...
3 years, 7 months ago (2017-05-25 21:49:55 UTC) #18
michaeldo
One note: I may also be able to move application_context to ios/componenets so please stand ...
3 years, 7 months ago (2017-05-25 22:06:07 UTC) #19
michaeldo
On 2017/05/25 22:06:07, michaeldo wrote: > One note: I may also be able to move ...
3 years, 7 months ago (2017-05-26 16:30:15 UTC) #20
Eugene But (OOO till 7-30)
On 2017/05/26 16:30:15, michaeldo wrote: > On 2017/05/25 22:06:07, michaeldo wrote: > > One note: ...
3 years, 7 months ago (2017-05-26 17:03:56 UTC) #21
michaeldo
PTAL at this CL now. I've rebased it on top of the ios/components/io_thread CL and ...
3 years, 6 months ago (2017-05-30 22:17:26 UTC) #23
sdefresne
https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/translate/web_view_translate_service.cc File ios/web_view/internal/translate/web_view_translate_service.cc (right): https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/translate/web_view_translate_service.cc#newcode22 ios/web_view/internal/translate/web_view_translate_service.cc:22: ~TranslateRequestsAllowedListener(){}; Remove trailing semi-colon. https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/translate/web_view_translate_service.cc#newcode43 ios/web_view/internal/translate/web_view_translate_service.cc:43: new TranslateRequestsAllowedListener()){}; Use ...
3 years, 6 months ago (2017-05-31 08:52:46 UTC) #25
Eugene But (OOO till 7-30)
lgtm https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/app/application_context.cc File ios/web_view/internal/app/application_context.cc (right): https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/app/application_context.cc#newcode46 ios/web_view/internal/app/application_context.cc:46: tracked_objects::ThreadData::EnsureCleanupWasCalled(4); Could you please create a constant for ...
3 years, 6 months ago (2017-05-31 16:25:34 UTC) #26
mmenke
I don't think you need me on this one any more, removing myself as a ...
3 years, 6 months ago (2017-05-31 19:33:33 UTC) #27
michaeldo
https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/app/application_context.cc File ios/web_view/internal/app/application_context.cc (right): https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/app/application_context.cc#newcode46 ios/web_view/internal/app/application_context.cc:46: tracked_objects::ThreadData::EnsureCleanupWasCalled(4); On 2017/05/31 16:25:33, Eugene But wrote: > Could ...
3 years, 6 months ago (2017-05-31 21:03:43 UTC) #29
michaeldo
On 2017/05/31 19:33:33, mmenke wrote: > I don't think you need me on this one ...
3 years, 6 months ago (2017-05-31 21:35:40 UTC) #30
Hiroshi Ichikawa
lgtm https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/app/application_context.cc File ios/web_view/internal/app/application_context.cc (right): https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/app/application_context.cc#newcode95 ios/web_view/internal/app/application_context.cc:95: std::max(std::min<int>(net::kDefaultMaxSocketsPerProxyServer, 99), On 2017/05/31 21:03:42, michaeldo wrote: > ...
3 years, 6 months ago (2017-06-01 02:25:59 UTC) #31
sdefresne
https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/translate/web_view_translate_service.h File ios/web_view/internal/translate/web_view_translate_service.h (right): https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/translate/web_view_translate_service.h#newcode34 ios/web_view/internal/translate/web_view_translate_service.h:34: // base/memory/singleton.h won't see that the OnResourceRequestsAllowed On 2017/05/31 ...
3 years, 6 months ago (2017-06-01 08:36:53 UTC) #32
michaeldo
https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/app/application_context.cc File ios/web_view/internal/app/application_context.cc (right): https://codereview.chromium.org/2894483003/diff/170001/ios/web_view/internal/app/application_context.cc#newcode95 ios/web_view/internal/app/application_context.cc:95: std::max(std::min<int>(net::kDefaultMaxSocketsPerProxyServer, 99), On 2017/06/01 02:25:59, Hiroshi Ichikawa wrote: > ...
3 years, 6 months ago (2017-06-01 21:20:38 UTC) #33
sdefresne
lgtm https://codereview.chromium.org/2894483003/diff/230001/ios/web_view/internal/app/application_context.h File ios/web_view/internal/app/application_context.h (right): https://codereview.chromium.org/2894483003/diff/230001/ios/web_view/internal/app/application_context.h#newcode54 ios/web_view/internal/app/application_context.h:54: // Saves applicaiton context state if |local_state_| exists. ...
3 years, 6 months ago (2017-06-02 09:03:51 UTC) #34
michaeldo
https://codereview.chromium.org/2894483003/diff/230001/ios/web_view/internal/app/application_context.h File ios/web_view/internal/app/application_context.h (right): https://codereview.chromium.org/2894483003/diff/230001/ios/web_view/internal/app/application_context.h#newcode54 ios/web_view/internal/app/application_context.h:54: // Saves applicaiton context state if |local_state_| exists. This ...
3 years, 6 months ago (2017-06-02 15:46:57 UTC) #35
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2894483003/250001
3 years, 6 months ago (2017-06-02 15:47:35 UTC) #38
commit-bot: I haz the power
3 years, 6 months ago (2017-06-02 17:14:37 UTC) #41
Message was sent while issue was closed.
Committed patchset #14 (id:250001) as
https://chromium.googlesource.com/chromium/src/+/6c4f1da164a4c4450a9ff9d5ede7...

Powered by Google App Engine
This is Rietveld 408576698