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

Issue 2801813003: Omnibox - ClipboardRecentContent - Make Proper Singleton (Closed)

Created:
3 years, 8 months ago by Mark P
Modified:
3 years, 8 months ago
Reviewers:
jif, Peter Kasting
CC:
chromium-reviews, jdonnelly+watch_chromium.org, dcheng
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Omnibox - ClipboardRecentContent - Make Proper Singleton This is a follow-up from https://codereview.chromium.org/2790993003 in particular https://codereview.chromium.org/2790993003#msg61 with its concerns about the lifetime of this object. TBR=jif BUG=682446

Patch Set 1 #

Patch Set 2 : restore field trial state #

Total comments: 10

Patch Set 3 : pkasting's comments #

Total comments: 2

Patch Set 4 : typo #

Patch Set 5 : jif@'s suggestion #

Total comments: 6

Patch Set 6 : pkasting comments #

Patch Set 7 : latest pkasting suggestion #

Patch Set 8 : fix iOS #

Unified diffs Side-by-side diffs Delta from patch set Stats (+13 lines, -16 lines) Patch
M components/omnibox/browser/autocomplete_controller.h View 2 chunks +0 lines, -4 lines 0 comments Download
M components/omnibox/browser/autocomplete_controller.cc View 1 2 3 4 5 6 2 chunks +6 lines, -6 lines 0 comments Download
M components/open_from_clipboard/clipboard_recent_content.h View 1 2 3 4 5 6 2 chunks +2 lines, -1 line 0 comments Download
M components/open_from_clipboard/clipboard_recent_content.cc View 1 2 3 4 5 6 2 chunks +4 lines, -3 lines 0 comments Download
M ios/chrome/browser/ios_chrome_main_parts.mm View 1 2 3 4 5 6 7 1 chunk +1 line, -2 lines 0 comments Download

Messages

Total messages: 44 (27 generated)
Mark P
Since it's okay to leak on process exit, this code suffices. (It passes the tests ...
3 years, 8 months ago (2017-04-05 19:40:18 UTC) #7
Peter Kasting
https://codereview.chromium.org/2801813003/diff/20001/components/omnibox/browser/autocomplete_controller.cc File components/omnibox/browser/autocomplete_controller.cc (right): https://codereview.chromium.org/2801813003/diff/20001/components/omnibox/browser/autocomplete_controller.cc#newcode245 components/omnibox/browser/autocomplete_controller.cc:245: ClipboardRecentContent::SetInstance(new ClipboardRecentContentGeneric()); Nit: Might want a comment like "This ...
3 years, 8 months ago (2017-04-05 23:23:51 UTC) #8
Mark P
https://codereview.chromium.org/2801813003/diff/20001/components/omnibox/browser/autocomplete_controller.cc File components/omnibox/browser/autocomplete_controller.cc (right): https://codereview.chromium.org/2801813003/diff/20001/components/omnibox/browser/autocomplete_controller.cc#newcode245 components/omnibox/browser/autocomplete_controller.cc:245: ClipboardRecentContent::SetInstance(new ClipboardRecentContentGeneric()); On 2017/04/05 23:23:51, Peter Kasting wrote: > ...
3 years, 8 months ago (2017-04-06 17:58:00 UTC) #9
Peter Kasting
I don't think the debates below are worth holding this up over. LGTM, do what ...
3 years, 8 months ago (2017-04-06 19:35:41 UTC) #10
Mark P
jif@, Can you please review this slight refactoring? thanks, mark https://codereview.chromium.org/2801813003/diff/20001/components/open_from_clipboard/clipboard_recent_content.cc File components/open_from_clipboard/clipboard_recent_content.cc (left): https://codereview.chromium.org/2801813003/diff/20001/components/open_from_clipboard/clipboard_recent_content.cc#oldcode27 ...
3 years, 8 months ago (2017-04-06 23:25:27 UTC) #12
jif
Should we consider having the instance be in a unique_ptr? This would make it impossible ...
3 years, 8 months ago (2017-04-07 09:28:05 UTC) #13
Mark P
jif@, Please take another look. On 2017/04/07 09:28:05, jif wrote: > Should we consider having ...
3 years, 8 months ago (2017-04-10 21:53:55 UTC) #14
Peter Kasting
https://codereview.chromium.org/2801813003/diff/80001/components/omnibox/browser/autocomplete_controller.cc File components/omnibox/browser/autocomplete_controller.cc (right): https://codereview.chromium.org/2801813003/diff/80001/components/omnibox/browser/autocomplete_controller.cc#newcode247 components/omnibox/browser/autocomplete_controller.cc:247: std::unique_ptr<ClipboardRecentContentGeneric>()); Doesn't this fail to actually create the underlying ...
3 years, 8 months ago (2017-04-10 21:59:22 UTC) #17
Mark P
https://codereview.chromium.org/2801813003/diff/80001/components/omnibox/browser/autocomplete_controller.cc File components/omnibox/browser/autocomplete_controller.cc (right): https://codereview.chromium.org/2801813003/diff/80001/components/omnibox/browser/autocomplete_controller.cc#newcode247 components/omnibox/browser/autocomplete_controller.cc:247: std::unique_ptr<ClipboardRecentContentGeneric>()); On 2017/04/10 21:59:22, Peter Kasting wrote: > Doesn't ...
3 years, 8 months ago (2017-04-10 22:05:22 UTC) #18
Peter Kasting
https://codereview.chromium.org/2801813003/diff/80001/components/open_from_clipboard/clipboard_recent_content.cc File components/open_from_clipboard/clipboard_recent_content.cc (right): https://codereview.chromium.org/2801813003/diff/80001/components/open_from_clipboard/clipboard_recent_content.cc#newcode52 components/open_from_clipboard/clipboard_recent_content.cc:52: ClipboardRecentContent::UniquePtrToInstance() { On 2017/04/10 22:05:22, Mark P wrote: > ...
3 years, 8 months ago (2017-04-10 22:18:34 UTC) #19
Mark P
https://codereview.chromium.org/2801813003/diff/80001/components/open_from_clipboard/clipboard_recent_content.cc File components/open_from_clipboard/clipboard_recent_content.cc (right): https://codereview.chromium.org/2801813003/diff/80001/components/open_from_clipboard/clipboard_recent_content.cc#newcode52 components/open_from_clipboard/clipboard_recent_content.cc:52: ClipboardRecentContent::UniquePtrToInstance() { On 2017/04/10 22:18:34, Peter Kasting wrote: > ...
3 years, 8 months ago (2017-04-10 23:10:14 UTC) #21
Peter Kasting
LGTM
3 years, 8 months ago (2017-04-10 23:11:26 UTC) #23
Mark P
If jif@ approves, I may need to add someone for the ios/chrome/browser/ios_chrome_main_parts.mm change. --mark
3 years, 8 months ago (2017-04-10 23:29:16 UTC) #28
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/2801813003/140001
3 years, 8 months ago (2017-04-12 19:32:44 UTC) #35
commit-bot: I haz the power
Failed to commit the patch.
3 years, 8 months ago (2017-04-12 21:26:59 UTC) #40
Mark P
On 2017/04/12 21:26:59, commit-bot: I haz the power wrote: > Failed to commit the patch. ...
3 years, 8 months ago (2017-04-12 21:36:04 UTC) #43
jif
3 years, 8 months ago (2017-04-18 16:21:16 UTC) #44
Message was sent while issue was closed.
On 2017/04/12 21:36:04, Mark P (away Mon Apr 17) wrote:
> On 2017/04/12 21:26:59, commit-bot: I haz the power wrote:
> > Failed to commit the patch.
> 
> Despite this message, the associated bug has a message posted to it about the
> change being committed.
>
https://chromium.googlesource.com/chromium/src.git/+/03a5e89da19258391f9b0f06...
> 
> --mark

lgtm

Powered by Google App Engine
This is Rietveld 408576698