Avoid unnecessary copy of parameters.
This commit is contained in:
parent
99293dd57f
commit
5f724e57bc
8 changed files with 8 additions and 8 deletions
|
@ -233,7 +233,7 @@ class ResolveProxyHelper {
|
||||||
public:
|
public:
|
||||||
ResolveProxyHelper(AtomBrowserContext* browser_context,
|
ResolveProxyHelper(AtomBrowserContext* browser_context,
|
||||||
const GURL& url,
|
const GURL& url,
|
||||||
Session::ResolveProxyCallback callback)
|
const Session::ResolveProxyCallback& callback)
|
||||||
: callback_(callback),
|
: callback_(callback),
|
||||||
original_thread_(base::ThreadTaskRunnerHandle::Get()) {
|
original_thread_(base::ThreadTaskRunnerHandle::Get()) {
|
||||||
scoped_refptr<net::URLRequestContextGetter> context_getter =
|
scoped_refptr<net::URLRequestContextGetter> context_getter =
|
||||||
|
|
|
@ -240,7 +240,7 @@ content::ServiceWorkerContext* GetServiceWorkerContext(
|
||||||
}
|
}
|
||||||
|
|
||||||
// Called when CapturePage is done.
|
// Called when CapturePage is done.
|
||||||
void OnCapturePageDone(base::Callback<void(const gfx::Image&)> callback,
|
void OnCapturePageDone(const base::Callback<void(const gfx::Image&)>& callback,
|
||||||
const SkBitmap& bitmap,
|
const SkBitmap& bitmap,
|
||||||
content::ReadbackResponse response) {
|
content::ReadbackResponse response) {
|
||||||
callback.Run(gfx::Image::CreateFrom1xBitmap(bitmap));
|
callback.Run(gfx::Image::CreateFrom1xBitmap(bitmap));
|
||||||
|
|
|
@ -102,7 +102,7 @@ class Browser : public WindowListObserver {
|
||||||
std::vector<base::string16> args;
|
std::vector<base::string16> args;
|
||||||
};
|
};
|
||||||
void SetLoginItemSettings(LoginItemSettings settings);
|
void SetLoginItemSettings(LoginItemSettings settings);
|
||||||
LoginItemSettings GetLoginItemSettings(LoginItemSettings options);
|
LoginItemSettings GetLoginItemSettings(const LoginItemSettings& options);
|
||||||
|
|
||||||
#if defined(OS_MACOSX)
|
#if defined(OS_MACOSX)
|
||||||
// Hide the application.
|
// Hide the application.
|
||||||
|
|
|
@ -64,7 +64,7 @@ void Browser::SetLoginItemSettings(LoginItemSettings settings) {
|
||||||
}
|
}
|
||||||
|
|
||||||
Browser::LoginItemSettings Browser::GetLoginItemSettings(
|
Browser::LoginItemSettings Browser::GetLoginItemSettings(
|
||||||
LoginItemSettings options) {
|
const LoginItemSettings& options) {
|
||||||
return LoginItemSettings();
|
return LoginItemSettings();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -152,7 +152,7 @@ bool Browser::ContinueUserActivity(const std::string& type,
|
||||||
}
|
}
|
||||||
|
|
||||||
Browser::LoginItemSettings Browser::GetLoginItemSettings(
|
Browser::LoginItemSettings Browser::GetLoginItemSettings(
|
||||||
LoginItemSettings options) {
|
const LoginItemSettings& options) {
|
||||||
LoginItemSettings settings;
|
LoginItemSettings settings;
|
||||||
settings.open_at_login = base::mac::CheckLoginItemStatus(
|
settings.open_at_login = base::mac::CheckLoginItemStatus(
|
||||||
&settings.open_as_hidden);
|
&settings.open_as_hidden);
|
||||||
|
|
|
@ -287,7 +287,7 @@ void Browser::SetLoginItemSettings(LoginItemSettings settings) {
|
||||||
}
|
}
|
||||||
|
|
||||||
Browser::LoginItemSettings Browser::GetLoginItemSettings(
|
Browser::LoginItemSettings Browser::GetLoginItemSettings(
|
||||||
LoginItemSettings options) {
|
const LoginItemSettings& options) {
|
||||||
LoginItemSettings settings;
|
LoginItemSettings settings;
|
||||||
base::string16 keyPath = L"Software\\Microsoft\\Windows\\CurrentVersion\\Run";
|
base::string16 keyPath = L"Software\\Microsoft\\Windows\\CurrentVersion\\Run";
|
||||||
base::win::RegKey key(HKEY_CURRENT_USER, keyPath.c_str(), KEY_ALL_ACCESS);
|
base::win::RegKey key(HKEY_CURRENT_USER, keyPath.c_str(), KEY_ALL_ACCESS);
|
||||||
|
|
|
@ -236,7 +236,7 @@ void AtomSandboxedRendererClient::WillReleaseScriptContext(
|
||||||
|
|
||||||
void AtomSandboxedRendererClient::InvokeIpcCallback(
|
void AtomSandboxedRendererClient::InvokeIpcCallback(
|
||||||
v8::Handle<v8::Context> context,
|
v8::Handle<v8::Context> context,
|
||||||
std::string callback_name,
|
const std::string& callback_name,
|
||||||
std::vector<v8::Handle<v8::Value>> args) {
|
std::vector<v8::Handle<v8::Value>> args) {
|
||||||
auto isolate = context->GetIsolate();
|
auto isolate = context->GetIsolate();
|
||||||
auto binding_key = mate::ConvertToV8(isolate, kIpcKey)->ToString();
|
auto binding_key = mate::ConvertToV8(isolate, kIpcKey)->ToString();
|
||||||
|
|
|
@ -22,7 +22,7 @@ class AtomSandboxedRendererClient : public content::ContentRendererClient {
|
||||||
void WillReleaseScriptContext(
|
void WillReleaseScriptContext(
|
||||||
v8::Handle<v8::Context> context, content::RenderFrame* render_frame);
|
v8::Handle<v8::Context> context, content::RenderFrame* render_frame);
|
||||||
void InvokeIpcCallback(v8::Handle<v8::Context> context,
|
void InvokeIpcCallback(v8::Handle<v8::Context> context,
|
||||||
std::string callback_name,
|
const std::string& callback_name,
|
||||||
std::vector<v8::Handle<v8::Value>> args);
|
std::vector<v8::Handle<v8::Value>> args);
|
||||||
// content::ContentRendererClient:
|
// content::ContentRendererClient:
|
||||||
void RenderFrameCreated(content::RenderFrame*) override;
|
void RenderFrameCreated(content::RenderFrame*) override;
|
||||||
|
|
Loading…
Reference in a new issue