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

Side by Side Diff: chrome/browser/chrome_site_per_process_browsertest.cc

Issue 2825003002: Rewrite base::Bind to base::BindOnce with base_bind_rewriters in //chrome/browser/{a,b,c,d,e,f,g}* (Closed)
Patch Set: split rest of changes to 3 CLs Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/files/file_path.h" 6 #include "base/files/file_path.h"
7 #include "base/macros.h" 7 #include "base/macros.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "base/strings/stringprintf.h" 9 #include "base/strings/stringprintf.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 535 matching lines...) Expand 10 before | Expand all | Expand 10 after
546 } 546 }
547 547
548 content::RenderProcessHost* process() const { return process_host_; } 548 content::RenderProcessHost* process() const { return process_host_; }
549 549
550 private: 550 private:
551 ~TestSpellCheckMessageFilter() override {} 551 ~TestSpellCheckMessageFilter() override {}
552 552
553 void HandleMessage(int, int, const base::string16& text) { 553 void HandleMessage(int, int, const base::string16& text) {
554 content::BrowserThread::PostTask( 554 content::BrowserThread::PostTask(
555 content::BrowserThread::UI, FROM_HERE, 555 content::BrowserThread::UI, FROM_HERE,
556 base::Bind(&TestSpellCheckMessageFilter::HandleMessageOnUI, this, 556 base::BindOnce(&TestSpellCheckMessageFilter::HandleMessageOnUI, this,
557 text)); 557 text));
558 } 558 }
559 559
560 void HandleMessageOnUI(const base::string16& text) { 560 void HandleMessageOnUI(const base::string16& text) {
561 last_text_ = text; 561 last_text_ = text;
562 if (!text_received_) { 562 if (!text_received_) {
563 text_received_ = true; 563 text_received_ = true;
564 message_loop_runner_->Quit(); 564 message_loop_runner_->Quit();
565 } 565 }
566 } 566 }
567 567
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
623 scoped_refptr<TestSpellCheckMessageFilter> filter = 623 scoped_refptr<TestSpellCheckMessageFilter> filter =
624 browser_client.GetSpellCheckMessageFilterForProcess( 624 browser_client.GetSpellCheckMessageFilterForProcess(
625 subframe->GetProcess()); 625 subframe->GetProcess());
626 filter->Wait(); 626 filter->Wait();
627 627
628 EXPECT_EQ(base::ASCIIToUTF16("zz."), filter->last_text()); 628 EXPECT_EQ(base::ASCIIToUTF16("zz."), filter->last_text());
629 629
630 content::SetBrowserClientForTesting(old_browser_client); 630 content::SetBrowserClientForTesting(old_browser_client);
631 } 631 }
632 #endif // BUILDFLAG(ENABLE_SPELLCHECK) 632 #endif // BUILDFLAG(ENABLE_SPELLCHECK)
OLDNEW
« no previous file with comments | « chrome/browser/chrome_quota_permission_context.cc ('k') | chrome/browser/content_settings/content_settings_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698