Skip to content

Commit d395131

Browse files
committed
fixup! rebase to Chromium 75
1 parent 381b357 commit d395131

File tree

6 files changed

+14
-15
lines changed

6 files changed

+14
-15
lines changed

src/browser/menubar_view.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,9 +96,9 @@ bool MenuBarView::GetMenuButtonAtLocation(const gfx::Point& loc, ui::MenuModel**
9696
return false;
9797
}
9898

99-
void MenuBarView::OnMenuButtonClicked(views::MenuButton* view,
100-
const gfx::Point& point,
101-
const ui::Event* event) {
99+
void MenuBarView::OnMenuButtonClicked(views::Button* view,
100+
const gfx::Point& point,
101+
const ui::Event* event) {
102102
int button_index = GetIndexOf(view);
103103
DCHECK_NE(-1, button_index);
104104
ui::MenuModel::ItemType type = model_->GetTypeAt(button_index);

src/browser/menubar_view.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ class MenuBarView :
4949
bool GetMenuButtonAtLocation(const gfx::Point& loc, ui::MenuModel** model, views::MenuButton** button);
5050

5151
// views::MenuButtonListener:
52-
void OnMenuButtonClicked(views::MenuButton* source,
52+
void OnMenuButtonClicked(views::Button* source,
5353
const gfx::Point& point,
5454
const ui::Event* event) override;
5555

src/browser/nw_extensions_browser_hooks.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ void LoadNWAppAsExtensionHook(base::DictionaryValue* manifest,
266266
if (GetPackageImage(package, base::FilePath::FromUTF8Unsafe(icon_path), &app_icon)) {
267267
SetAppIcon(app_icon);
268268
int width = app_icon.Width();
269-
std::string key = "icons." + base::IntToString(width);
269+
std::string key = "icons." + base::NumberToString(width);
270270
manifest->SetString(key, icon_path);
271271
#if defined(OS_WIN)
272272
SetWindowHIcon((IconUtil::CreateHICONFromSkBitmapSizedTo(*app_icon.AsImageSkia().bitmap(),

src/nwjs_browsertest.cc

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -394,11 +394,11 @@ class MockDownloadWebContentsDelegate : public content::WebContentsDelegate {
394394

395395
void CanDownload(const GURL& url,
396396
const std::string& request_method,
397-
const base::Callback<void(bool)>& callback) override {
397+
base::OnceCallback<void(bool)> callback) override {
398398
orig_delegate_->CanDownload(
399399
url, request_method,
400-
base::Bind(&MockDownloadWebContentsDelegate::DownloadDecided,
401-
base::Unretained(this), callback));
400+
base::BindOnce(&MockDownloadWebContentsDelegate::DownloadDecided,
401+
base::Unretained(this), std::move(callback)));
402402
}
403403

404404
void WaitForCanDownload(bool expect_allow) {
@@ -415,19 +415,19 @@ class MockDownloadWebContentsDelegate : public content::WebContentsDelegate {
415415
message_loop_runner_->Run();
416416
}
417417

418-
void DownloadDecided(const base::Callback<void(bool)>& callback, bool allow) {
418+
void DownloadDecided(base::OnceCallback<void(bool)> callback, bool allow) {
419419
EXPECT_FALSE(decision_made_);
420420
decision_made_ = true;
421421

422422
if (waiting_for_decision_) {
423423
EXPECT_EQ(expect_allow_, allow);
424424
if (message_loop_runner_.get())
425425
message_loop_runner_->Quit();
426-
callback.Run(allow);
426+
std::move(callback).Run(allow);
427427
return;
428428
}
429429
last_download_allowed_ = allow;
430-
callback.Run(allow);
430+
std::move(callback).Run(allow);
431431
}
432432

433433
void Reset() {
@@ -1212,7 +1212,7 @@ class NWJSDesktopCaptureApiTest : public NWAppTest {
12121212

12131213
protected:
12141214
GURL GetURLForPath(const std::string& host, const std::string& path) {
1215-
std::string port = base::UintToString(embedded_test_server()->port());
1215+
std::string port = base::NumberToString(embedded_test_server()->port());
12161216
GURL::Replacements replacements;
12171217
replacements.SetHostStr(host);
12181218
replacements.SetPortStr(port);

src/policy_cert_verifier.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
#include "base/compiler_specific.h"
1313
#include "base/macros.h"
1414
#include "base/memory/ref_counted.h"
15-
#include "net/base/completion_callback.h"
1615
#include "net/cert/cert_verifier.h"
1716

1817
namespace net {

src/renderer/nw_extensions_renderer_hooks.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,13 +129,13 @@ const char* GetChromiumVersion();
129129

130130
// renderer
131131

132-
void WebWorkerNewThreadHook(const char* name, base::Thread::Options* options) {
132+
void WebWorkerNewThreadHook(const char* name, bool* is_node) {
133133
const base::CommandLine& command_line =
134134
*base::CommandLine::ForCurrentProcess();
135135
if (!command_line.HasSwitch(switches::kEnableNodeWorker))
136136
return;
137137
if (!strcmp(name, "DedicatedWorker thread") || !strcmp(name, "SharedWorker thread"))
138-
options->message_loop_type = base::MessageLoop::TYPE_NODE;
138+
*is_node = true;
139139
}
140140

141141
void WebWorkerStartThreadHook(blink::Frame* frame, const char* path, std::string* script, bool* isNodeJS) {

0 commit comments

Comments
 (0)