Index: content/public/browser/presentation_service_delegate.h |
diff --git a/content/public/browser/presentation_service_delegate.h b/content/public/browser/presentation_service_delegate.h |
index fd82045e669888a756a16a85336eed7f723fb7fd..4841a67d23f0ff74eab59565f263424a1d1cdd56 100644 |
--- a/content/public/browser/presentation_service_delegate.h |
+++ b/content/public/browser/presentation_service_delegate.h |
@@ -7,6 +7,7 @@ |
#include "base/callback.h" |
#include "content/common/content_export.h" |
+#include "content/public/browser/presentation_message.h" |
#include "content/public/browser/presentation_session.h" |
namespace content { |
@@ -38,6 +39,7 @@ class CONTENT_EXPORT PresentationServiceDelegate { |
base::Callback<void(const PresentationSessionInfo&)>; |
using PresentationSessionErrorCallback = |
base::Callback<void(const PresentationError&)>; |
+ using SendMessageCallback = base::Callback<void()>; |
imcheng (use chromium acct)
2015/04/30 20:11:30
using SendMessageCallback = base::Closure;
USE s.singapati at gmail.com
2015/05/04 16:40:28
Done.
|
virtual ~PresentationServiceDelegate() {} |
@@ -129,6 +131,16 @@ class CONTENT_EXPORT PresentationServiceDelegate { |
const std::string& presentation_id, |
const PresentationSessionSuccessCallback& success_cb, |
const PresentationSessionErrorCallback& error_cb) = 0; |
+ |
+ // Sends a message (string or binary data) to a presentation session. |
+ // |render_process_id|, |render_frame_id|: ID of originating frame. |
+ // |message_request|: Contains Presentation URL, ID and message to be sent |
+ // and delegate is responsible for deallocating the message_request. |
imcheng (use chromium acct)
2015/04/30 20:11:30
Please also document |send_message_cb|.
USE s.singapati at gmail.com
2015/05/04 16:40:28
Done.
|
+ virtual void SendMessage( |
+ int render_process_id, |
+ int render_frame_id, |
+ PresentationMessageRequest* message_request, |
imcheng (use chromium acct)
2015/04/30 20:11:30
Can this be a scoped_ptr so it's less error prone
USE s.singapati at gmail.com
2015/05/01 10:30:25
Ok, I will check this one.
USE s.singapati at gmail.com
2015/05/04 16:40:28
sending scoped_ptr to delegate is fine. But mockin
USE s.singapati at gmail.com
2015/05/05 14:26:36
Done.
|
+ const SendMessageCallback& send_message_cb) = 0; |
}; |
} // namespace content |