summaryrefslogtreecommitdiffstats
path: root/mojo/common
diff options
context:
space:
mode:
authorben <ben@chromium.org>2016-02-02 11:51:28 -0800
committerCommit bot <commit-bot@chromium.org>2016-02-02 19:53:48 +0000
commit3aeb0b84598e215c9ff270785b1250854b6bd8a0 (patch)
tree71b8ab8a46904bb17ed8e5479ee67945dd268a7b /mojo/common
parentaf2c8dd14b11ade2cde6a389b20eb20cab5eee62 (diff)
downloadchromium_src-3aeb0b84598e215c9ff270785b1250854b6bd8a0.zip
chromium_src-3aeb0b84598e215c9ff270785b1250854b6bd8a0.tar.gz
chromium_src-3aeb0b84598e215c9ff270785b1250854b6bd8a0.tar.bz2
Make Screenlock observe shell screenlock state.
R=sky@chromium.org BUG=none Review URL: https://codereview.chromium.org/1648423002 Cr-Commit-Position: refs/heads/master@{#373008}
Diffstat (limited to 'mojo/common')
-rw-r--r--mojo/common/weak_binding_set.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/mojo/common/weak_binding_set.h b/mojo/common/weak_binding_set.h
index 10d7ee0..6485c4f 100644
--- a/mojo/common/weak_binding_set.h
+++ b/mojo/common/weak_binding_set.h
@@ -39,6 +39,14 @@ class WeakBindingSet {
bindings_.push_back(binding->GetWeakPtr());
}
+ // Returns an InterfacePtr bound to one end of a pipe whose other end is
+ // bound to |this|.
+ InterfacePtr<Interface> CreateInterfacePtrAndBind(Interface* impl) {
+ InterfacePtr<Interface> interface_ptr;
+ AddBinding(impl, GetProxy(&interface_ptr));
+ return interface_ptr;
+ }
+
void CloseAllBindings() {
for (const auto& it : bindings_) {
if (it) {