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

Unified Diff: media/remoting/remoting_sink_observer.h

Issue 2643253003: Media Remoting Clean-up: Less-redundant naming, style consistency, etc. (Closed)
Patch Set: REBASE Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/remoting/remoting_renderer_factory.cc ('k') | media/remoting/remoting_sink_observer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/remoting/remoting_sink_observer.h
diff --git a/media/remoting/remoting_sink_observer.h b/media/remoting/remoting_sink_observer.h
deleted file mode 100644
index dd4df28535fcd07d148b56e8ff2bdc0e8e792749..0000000000000000000000000000000000000000
--- a/media/remoting/remoting_sink_observer.h
+++ /dev/null
@@ -1,52 +0,0 @@
-// Copyright 2016 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef MEDIA_REMOTING_REMOTING_SINK_OBSERVER_H_
-#define MEDIA_REMOTING_REMOTING_SINK_OBSERVER_H_
-
-#include "media/mojo/interfaces/remoting.mojom.h"
-#include "mojo/public/cpp/bindings/binding.h"
-
-namespace media {
-
-// This calss is a pure observer of remoting sink availability to indicate
-// whether a remoting session can be started.
-class RemotingSinkObserver final : public mojom::RemotingSource {
- public:
- RemotingSinkObserver(mojom::RemotingSourceRequest source_request,
- mojom::RemoterPtr remoter);
- ~RemotingSinkObserver() override;
-
- mojom::RemotingSinkCapabilities sink_capabilities() const {
- return sink_capabilities_;
- }
-
- bool is_remote_decryption_available() const {
- return sink_capabilities_ ==
- mojom::RemotingSinkCapabilities::CONTENT_DECRYPTION_AND_RENDERING;
- }
-
- // RemotingSource implementations.
- void OnSinkAvailable(mojom::RemotingSinkCapabilities capabilities) override;
- void OnSinkGone() override;
- void OnStarted() override {}
- void OnStartFailed(mojom::RemotingStartFailReason reason) override {}
- void OnMessageFromSink(const std::vector<uint8_t>& message) override {}
- void OnStopped(mojom::RemotingStopReason reason) override {}
-
- private:
- const mojo::Binding<mojom::RemotingSource> binding_;
- const mojom::RemoterPtr remoter_;
-
- // When the sink is available, this describes its capabilities. When not
- // available, this is always NONE. Updated by OnSinkAvailable/Gone().
- mojom::RemotingSinkCapabilities sink_capabilities_ =
- mojom::RemotingSinkCapabilities::NONE;
-
- DISALLOW_COPY_AND_ASSIGN(RemotingSinkObserver);
-};
-
-} // namespace media
-
-#endif // MEDIA_REMOTING_REMOTING_SINK_OBSERVER_H_
« no previous file with comments | « media/remoting/remoting_renderer_factory.cc ('k') | media/remoting/remoting_sink_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698