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

Issue 7397021: Re-land r93365 - add RefCountedString (Closed)

Created:
9 years, 5 months ago by joth
Modified:
9 years, 5 months ago
CC:
chromium-reviews, hclam+watch_chromium.org, sjl, ddorwin+watch_chromium.org, fischman+watch_chromium.org, jam, Erik does not do reviews, Paweł Hajdan Jr., acolwell+watch_chromium.org, annacc+watch_chromium.org, joi+watch-content_chromium.org, Aaron Boodman, ajwong+watch_chromium.org, vrk (LEFT CHROMIUM), brettw-cc_chromium.org, estade+watch_chromium.org, scherkus (not reviewing)
Visibility:
Public.

Description

Re-land r93365 - add RefCountedString Added RefCountedString, as this is what many RefCountedMemory users seem to want Made data member of RefCountedBytes private, as per style guide Changed base64 APIs to accept StringPiece, as it's sometimes better and never worse than string. Fix chromeos build; additional files updated comapred to previous patch: chrome/browser/ui/login/login_prompt_ui.cc chrome/browser/ui/webui/active_downloads_ui.cc chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.cc chrome/browser/ui/webui/chromeos/enterprise_enrollment_ui.cc chrome/browser/ui/webui/chromeos/imageburner/imageburner_ui.cc chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc chrome/browser/ui/webui/chromeos/login/login_ui.cc chrome/browser/ui/webui/chromeos/login/login_ui_helpers.cc chrome/browser/ui/webui/chromeos/login/login_ui_helpers.h chrome/browser/ui/webui/chromeos/login/mock_login_ui_helpers.h chrome/browser/ui/webui/chromeos/login/oobe_ui.cc chrome/browser/ui/webui/chromeos/mobile_setup_ui.cc chrome/browser/ui/webui/chromeos/proxy_settings_ui.cc chrome/browser/ui/webui/chromeos/register_page_ui.cc chrome/browser/ui/webui/chromeos/sim_unlock_ui.cc chrome/browser/ui/webui/chromeos/system_info_ui.cc chrome/browser/ui/webui/collected_cookies_ui_delegate.cc BUG=None TEST=All existing tests pass. Extended ref_counted_memory_unittests Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=93617

Patch Set 1 #

Patch Set 2 : tidy #

Patch Set 3 : rebase to trunk #

Patch Set 4 : Fix unit_tests #

Total comments: 3

Patch Set 5 : erg comments #

Total comments: 6

Patch Set 6 : rebase + brettw comments #

Patch Set 7 : fix tests #

Patch Set 8 : rebase #

Patch Set 9 : Fixed ChromeOS to reland #

Patch Set 10 : Add missing ref_counted_memory_unittest.cc file #

Patch Set 11 : Fix TraceEvent after rebase #

Patch Set 12 : rebased onto r93582 #

Total comments: 2

Patch Set 13 : bulach comments #

Patch Set 14 : rebase again #

Unified diffs Side-by-side diffs Delta from patch set Stats (+246 lines, -298 lines) Patch
M base/base.gyp View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M base/base64.h View 1 2 3 4 5 1 chunk +3 lines, -2 lines 0 comments Download
M base/base64.cc View 2 chunks +2 lines, -2 lines 0 comments Download
M base/debug/trace_event.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +3 lines, -3 lines 0 comments Download
M base/debug/trace_event.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +4 lines, -3 lines 0 comments Download
M base/memory/ref_counted_memory.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +45 lines, -10 lines 0 comments Download
M base/memory/ref_counted_memory.cc View 1 2 3 4 5 6 2 chunks +30 lines, -4 lines 0 comments Download
A base/memory/ref_counted_memory_unittest.cc View 1 2 3 4 5 9 1 chunk +45 lines, -0 lines 0 comments Download
M chrome/browser/browser_about_handler.cc View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -4 lines 0 comments Download
M chrome/browser/browser_signin.cc View 2 chunks +1 line, -5 lines 0 comments Download
M chrome/browser/extensions/extension_tabs_module.cc View 1 2 3 4 5 6 7 8 9 10 11 4 chunks +6 lines, -8 lines 0 comments Download
M chrome/browser/favicon/favicon_handler_unittest.cc View 1 2 3 4 5 6 5 chunks +5 lines, -5 lines 0 comments Download
M chrome/browser/history/history_backend.cc View 1 2 3 4 5 3 chunks +5 lines, -5 lines 0 comments Download
M chrome/browser/history/top_sites.cc View 1 2 3 4 5 1 chunk +3 lines, -2 lines 0 comments Download
M chrome/browser/history/top_sites_unittest.cc View 1 2 3 4 5 6 2 chunks +5 lines, -5 lines 0 comments Download
M chrome/browser/printing/cloud_print/cloud_print_setup_source.cc View 2 chunks +2 lines, -7 lines 0 comments Download
M chrome/browser/printing/print_preview_message_handler.cc View 1 2 3 4 5 1 chunk +6 lines, -5 lines 0 comments Download
M chrome/browser/ui/login/login_prompt_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +1 line, -5 lines 0 comments Download
M chrome/browser/ui/webui/active_downloads_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -6 lines 0 comments Download
M chrome/browser/ui/webui/bug_report_ui.cc View 2 chunks +2 lines, -7 lines 0 comments Download
M chrome/browser/ui/webui/chrome_web_ui_data_source.cc View 1 chunk +1 line, -4 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +3 lines, -7 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/enterprise_enrollment_ui.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -5 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/imageburner/imageburner_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -6 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -6 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/login/login_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +1 line, -4 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/login/login_ui_helpers.h View 1 2 3 4 5 6 7 8 2 chunks +1 line, -2 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/login/login_ui_helpers.cc View 1 2 3 4 5 6 7 8 1 chunk +0 lines, -10 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/login/mock_login_ui_helpers.h View 1 2 3 4 5 6 7 8 1 chunk +0 lines, -2 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/login/oobe_ui.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -5 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/mobile_setup_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +3 lines, -7 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/proxy_settings_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -6 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/register_page_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -8 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/sim_unlock_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +3 lines, -7 lines 0 comments Download
M chrome/browser/ui/webui/chromeos/system_info_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -6 lines 0 comments Download
M chrome/browser/ui/webui/collected_cookies_ui_delegate.cc View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -6 lines 0 comments Download
M chrome/browser/ui/webui/extension_icon_source.cc View 1 2 3 4 5 1 chunk +2 lines, -6 lines 0 comments Download
M chrome/browser/ui/webui/fileicon_source.cc View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/webui/gpu_internals_ui.cc View 1 2 3 4 5 1 chunk +1 line, -5 lines 0 comments Download
M chrome/browser/ui/webui/history2_ui.cc View 2 chunks +2 lines, -7 lines 0 comments Download
M chrome/browser/ui/webui/media/media_internals_ui.cc View 1 chunk +1 line, -5 lines 0 comments Download
M chrome/browser/ui/webui/net_internals_ui.cc View 1 2 3 4 5 1 chunk +3 lines, -9 lines 0 comments Download
M chrome/browser/ui/webui/ntp/new_tab_ui.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/webui/ntp/ntp_resource_cache.h View 3 chunks +7 lines, -7 lines 0 comments Download
M chrome/browser/ui/webui/ntp/ntp_resource_cache.cc View 1 2 3 4 5 6 7 8 9 10 11 6 chunks +6 lines, -17 lines 0 comments Download
M chrome/browser/ui/webui/options/options_ui.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +8 lines, -21 lines 0 comments Download
M chrome/browser/ui/webui/print_preview_data_source.cc View 1 chunk +2 lines, -6 lines 0 comments Download
M chrome/browser/ui/webui/sessions_ui.cc View 1 2 3 4 5 2 chunks +3 lines, -5 lines 0 comments Download
M chrome/browser/ui/webui/sync_internals_html_source.cc View 2 chunks +1 line, -6 lines 0 comments Download
M chrome/browser/ui/webui/task_manager_ui.cc View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -6 lines 0 comments Download
M chrome/browser/ui/webui/textfields_ui.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +2 lines, -8 lines 0 comments Download
M chrome/browser/ui/webui/theme_source.h View 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/webui/workers_ui.cc View 1 chunk +1 line, -5 lines 0 comments Download
M content/renderer/render_widget_browsertest.cc View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 16 (0 generated)
joth
[many cc: watches left in, by popular request] Elliot, Brett, could you take a first ...
9 years, 5 months ago (2011-07-19 14:51:01 UTC) #1
Ami GONE FROM CHROMIUM
> (And is easier to read, to boot) Drive-by: would it be even easier to ...
9 years, 5 months ago (2011-07-19 16:58:08 UTC) #2
joth
On 19 July 2011 17:58, <fischman@chromium.org> wrote: > (And is easier to read, to boot) ...
9 years, 5 months ago (2011-07-19 17:18:08 UTC) #3
Elliot Glaysher
On 2011/07/19 14:51:01, joth wrote: > std::string response = .... > SendResponse(request_id, base::RefCountedString::TakeString(&response)); The idea ...
9 years, 5 months ago (2011-07-19 17:59:02 UTC) #4
joth
On 19 July 2011 18:59, <erg@chromium.org> wrote: > On 2011/07/19 14:51:01, joth wrote: > >> ...
9 years, 5 months ago (2011-07-19 19:25:22 UTC) #5
Elliot Glaysher
LGTM
9 years, 5 months ago (2011-07-19 19:30:10 UTC) #6
brettw
http://codereview.chromium.org/7397021/diff/5001/base/memory/ref_counted_memory.h File base/memory/ref_counted_memory.h (right): http://codereview.chromium.org/7397021/diff/5001/base/memory/ref_counted_memory.h#newcode103 base/memory/ref_counted_memory.h:103: std::string* data() { return &data_; } Is there any ...
9 years, 5 months ago (2011-07-19 19:58:44 UTC) #7
joth
Thanks Brett, comments addressed. I'm now looking for OWNER approvals (and drive-by reviews from those ...
9 years, 5 months ago (2011-07-20 12:53:02 UTC) #8
brettw
base/content LGTM
9 years, 5 months ago (2011-07-20 17:10:22 UTC) #9
joth
+pkasting (forgot to add to reviewer list on previous mail). Could you check the chrome/browser/ui ...
9 years, 5 months ago (2011-07-20 17:52:18 UTC) #10
Peter Kasting
On 2011/07/20 17:52:18, joth wrote: > +pkasting (forgot to add to reviewer list on previous ...
9 years, 5 months ago (2011-07-20 17:57:39 UTC) #11
joth
estade: could you rubber stamp the chrome/browser/ui/webui/.. changes? Thanks!
9 years, 5 months ago (2011-07-20 18:42:01 UTC) #12
Evan Stade
rs lgtm
9 years, 5 months ago (2011-07-20 18:51:25 UTC) #13
joth
Updated patch with ChromeOS files (as mentioned in the CL description) in order to re-land. ...
9 years, 5 months ago (2011-07-21 11:47:23 UTC) #14
commit-bot: I haz the power
Try job failure for 7397021-20003 (retry) on win for step "compile" (clobber build). It's a ...
9 years, 5 months ago (2011-07-21 13:14:36 UTC) #15
bulach
9 years, 5 months ago (2011-07-22 11:16:53 UTC) #16
LGTM

two nits below, hopefully the try bots will be happier next cycle..

http://codereview.chromium.org/7397021/diff/26001/base/memory/ref_counted_mem...
File base/memory/ref_counted_memory.h (right):

http://codereview.chromium.org/7397021/diff/26001/base/memory/ref_counted_mem...
base/memory/ref_counted_memory.h:48: virtual const unsigned char* front() const;
nit: OVERRIDE here and below

http://codereview.chromium.org/7397021/diff/26001/chrome/browser/ui/webui/tex...
File chrome/browser/ui/webui/textfields_ui.cc (right):

http://codereview.chromium.org/7397021/diff/26001/chrome/browser/ui/webui/tex...
chrome/browser/ui/webui/textfields_ui.cc:33:
.GetRawDataResource(IDR_TEXTFIELDS_HTML).as_string();
use LoadDataResourceBytes as options_ui.cc instead..

Powered by Google App Engine
This is Rietveld 408576698