1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
android_webview / browser / permission / simple_permission_request.cc [blame]
// Copyright 2014 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "android_webview/browser/permission/simple_permission_request.h"
#include "android_webview/browser/permission/aw_permission_request.h"
#include "base/functional/callback.h"
namespace android_webview {
SimplePermissionRequest::SimplePermissionRequest(const GURL& origin,
int64_t resources,
PermissionCallback callback)
: origin_(origin), resources_(resources), callback_(std::move(callback)) {}
SimplePermissionRequest::~SimplePermissionRequest() {}
void SimplePermissionRequest::NotifyRequestResult(bool allowed) {
std::move(callback_).Run(allowed);
}
const GURL& SimplePermissionRequest::GetOrigin() {
return origin_;
}
int64_t SimplePermissionRequest::GetResources() {
return resources_;
}
} // namespace android_webview