summaryrefslogtreecommitdiffstats
path: root/remoting/client
diff options
context:
space:
mode:
Diffstat (limited to 'remoting/client')
-rw-r--r--remoting/client/chromoting_client.cc12
-rw-r--r--remoting/client/chromoting_client.h8
-rw-r--r--remoting/client/chromoting_view.cc2
-rw-r--r--remoting/client/chromoting_view.h8
-rw-r--r--remoting/client/chromoting_view_unittest.cc10
-rw-r--r--remoting/client/plugin/pepper_view.cc10
-rw-r--r--remoting/client/plugin/pepper_view.h6
-rw-r--r--remoting/client/x11_input_handler.cc4
-rw-r--r--remoting/client/x11_view.cc10
-rw-r--r--remoting/client/x11_view.h6
10 files changed, 38 insertions, 38 deletions
diff --git a/remoting/client/chromoting_client.cc b/remoting/client/chromoting_client.cc
index 76f5b0c8..9226186 100644
--- a/remoting/client/chromoting_client.cc
+++ b/remoting/client/chromoting_client.cc
@@ -105,7 +105,7 @@ void ChromotingClient::HandleMessages(HostConnection* conn,
}
for (size_t i = 0; i < messages->size(); ++i) {
- HostMessage* msg = (*messages)[i];
+ ChromotingHostMessage* msg = (*messages)[i];
// TODO(ajwong): Consider creating a macro similar to the IPC message
// mappings. Also reconsider the lifetime of the message object.
if (msg->has_init_client()) {
@@ -175,10 +175,10 @@ void ChromotingClient::SetState(State s) {
Repaint();
}
-void ChromotingClient::InitClient(HostMessage* msg) {
+void ChromotingClient::InitClient(ChromotingHostMessage* msg) {
DCHECK_EQ(message_loop(), MessageLoop::current());
DCHECK(msg->has_init_client());
- scoped_ptr<HostMessage> deleter(msg);
+ scoped_ptr<ChromotingHostMessage> deleter(msg);
// Resize the window.
int width = msg->init_client().width();
@@ -191,21 +191,21 @@ void ChromotingClient::InitClient(HostMessage* msg) {
input_handler_->Initialize();
}
-void ChromotingClient::BeginUpdate(HostMessage* msg) {
+void ChromotingClient::BeginUpdate(ChromotingHostMessage* msg) {
DCHECK_EQ(message_loop(), MessageLoop::current());
DCHECK(msg->has_begin_update_stream());
view_->HandleBeginUpdateStream(msg);
}
-void ChromotingClient::HandleUpdate(HostMessage* msg) {
+void ChromotingClient::HandleUpdate(ChromotingHostMessage* msg) {
DCHECK_EQ(message_loop(), MessageLoop::current());
DCHECK(msg->has_update_stream_packet());
view_->HandleUpdateStreamPacket(msg);
}
-void ChromotingClient::EndUpdate(HostMessage* msg) {
+void ChromotingClient::EndUpdate(ChromotingHostMessage* msg) {
DCHECK_EQ(message_loop(), MessageLoop::current());
DCHECK(msg->has_end_update_stream());
diff --git a/remoting/client/chromoting_client.h b/remoting/client/chromoting_client.h
index bdc2e26..c7026e3 100644
--- a/remoting/client/chromoting_client.h
+++ b/remoting/client/chromoting_client.h
@@ -65,10 +65,10 @@ class ChromotingClient : public HostConnection::HostEventCallback {
void SetState(State s);
// Handles for chromotocol messages.
- void InitClient(HostMessage* msg);
- void BeginUpdate(HostMessage* msg);
- void HandleUpdate(HostMessage* msg);
- void EndUpdate(HostMessage* msg);
+ void InitClient(ChromotingHostMessage* msg);
+ void BeginUpdate(ChromotingHostMessage* msg);
+ void HandleUpdate(ChromotingHostMessage* msg);
+ void EndUpdate(ChromotingHostMessage* msg);
// The following are not owned by this class.
ClientConfig config_;
diff --git a/remoting/client/chromoting_view.cc b/remoting/client/chromoting_view.cc
index 9bc1a8a..f985669 100644
--- a/remoting/client/chromoting_view.cc
+++ b/remoting/client/chromoting_view.cc
@@ -75,7 +75,7 @@ bool ChromotingView::BeginDecoding(Task* partial_decode_done,
return true;
}
-bool ChromotingView::Decode(HostMessage* msg) {
+bool ChromotingView::Decode(ChromotingHostMessage* msg) {
if (!decoder_->IsStarted()) {
LOG(ERROR) << "Attempt to decode payload before calling BeginDecode.";
return false;
diff --git a/remoting/client/chromoting_view.h b/remoting/client/chromoting_view.h
index 051fd7b..0f19c09 100644
--- a/remoting/client/chromoting_view.h
+++ b/remoting/client/chromoting_view.h
@@ -51,7 +51,7 @@ class ChromotingView {
// (1) Perform any platform-specific tasks for start of update stream.
// (2) Make sure the |frame_| has been initialized.
// (3) Delete the HostMessage.
- virtual void HandleBeginUpdateStream(HostMessage* msg) = 0;
+ virtual void HandleBeginUpdateStream(ChromotingHostMessage* msg) = 0;
// Handle the UpdateStreamPacket message.
// This method should perform the following tasks:
@@ -66,14 +66,14 @@ class ChromotingView {
// * For a given begin/end update stream, the encodings specified in the
// update packets must all match. We may revisit this constraint at a
// later date.
- virtual void HandleUpdateStreamPacket(HostMessage* msg) = 0;
+ virtual void HandleUpdateStreamPacket(ChromotingHostMessage* msg) = 0;
// Handle the EndUpdateStream message.
// This method should perform the following tasks:
// (1) Call EndDecoding().
// (2) Perform any platform-specific tasks for end of update stream.
// (3) Delete the HostMessage.
- virtual void HandleEndUpdateStream(HostMessage* msg) = 0;
+ virtual void HandleEndUpdateStream(ChromotingHostMessage* msg) = 0;
protected:
// Setup the decoder based on the given encoding.
@@ -87,7 +87,7 @@ class ChromotingView {
// Decode the given message.
// BeginDecoding() must be called before any calls to Decode().
- bool Decode(HostMessage* msg);
+ bool Decode(ChromotingHostMessage* msg);
// Finish decoding and send notifications to update the view.
bool EndDecoding();
diff --git a/remoting/client/chromoting_view_unittest.cc b/remoting/client/chromoting_view_unittest.cc
index 96d97ed..1856891 100644
--- a/remoting/client/chromoting_view_unittest.cc
+++ b/remoting/client/chromoting_view_unittest.cc
@@ -22,7 +22,7 @@ class MockDecoder : public Decoder {
UpdatedRects* updated_rects,
Task* partial_decode_done,
Task* decode_done));
- MOCK_METHOD1(PartialDecode, bool(HostMessage* message));
+ MOCK_METHOD1(PartialDecode, bool(ChromotingHostMessage* message));
MOCK_METHOD0(EndDecode, void());
MOCK_METHOD0(Encoding, UpdateStreamEncoding());
@@ -46,9 +46,9 @@ class FakeView : public ChromotingView {
frame_height_ = height;
}
void SetHostScreenSize(int width, int height) {}
- void HandleBeginUpdateStream(HostMessage* msg) {}
- void HandleUpdateStreamPacket(HostMessage* msg) {}
- void HandleEndUpdateStream(HostMessage* msg) {}
+ void HandleBeginUpdateStream(ChromotingHostMessage* msg) {}
+ void HandleUpdateStreamPacket(ChromotingHostMessage* msg) {}
+ void HandleEndUpdateStream(ChromotingHostMessage* msg) {}
public:
// Testing accessors.
@@ -68,7 +68,7 @@ class FakeView : public ChromotingView {
bool begin_decoding(Task* partial_decode_done, Task* decode_done) {
return BeginDecoding(partial_decode_done, decode_done);
}
- bool decode(HostMessage* msg) {
+ bool decode(ChromotingHostMessage* msg) {
return Decode(msg);
}
bool end_decoding() {
diff --git a/remoting/client/plugin/pepper_view.cc b/remoting/client/plugin/pepper_view.cc
index 86b70fc..ab631a8 100644
--- a/remoting/client/plugin/pepper_view.cc
+++ b/remoting/client/plugin/pepper_view.cc
@@ -139,7 +139,7 @@ void PepperView::SetHostScreenSize(int width, int height) {
frame_ = NULL;
}
-void PepperView::HandleBeginUpdateStream(HostMessage* msg) {
+void PepperView::HandleBeginUpdateStream(ChromotingHostMessage* msg) {
if (!instance_->CurrentlyOnPluginThread()) {
RunTaskOnPluginThread(
NewRunnableMethod(this, &PepperView::HandleBeginUpdateStream,
@@ -147,7 +147,7 @@ void PepperView::HandleBeginUpdateStream(HostMessage* msg) {
return;
}
- scoped_ptr<HostMessage> deleter(msg);
+ scoped_ptr<ChromotingHostMessage> deleter(msg);
// Make sure the |frame_| is initialized.
if (!frame_) {
@@ -159,7 +159,7 @@ void PepperView::HandleBeginUpdateStream(HostMessage* msg) {
}
}
-void PepperView::HandleUpdateStreamPacket(HostMessage* msg) {
+void PepperView::HandleUpdateStreamPacket(ChromotingHostMessage* msg) {
if (!instance_->CurrentlyOnPluginThread()) {
RunTaskOnPluginThread(
NewRunnableMethod(this, &PepperView::HandleUpdateStreamPacket,
@@ -177,7 +177,7 @@ void PepperView::HandleUpdateStreamPacket(HostMessage* msg) {
Decode(msg);
}
-void PepperView::HandleEndUpdateStream(HostMessage* msg) {
+void PepperView::HandleEndUpdateStream(ChromotingHostMessage* msg) {
if (!instance_->CurrentlyOnPluginThread()) {
RunTaskOnPluginThread(
NewRunnableMethod(this, &PepperView::HandleEndUpdateStream,
@@ -185,7 +185,7 @@ void PepperView::HandleEndUpdateStream(HostMessage* msg) {
return;
}
- scoped_ptr<HostMessage> deleter(msg);
+ scoped_ptr<ChromotingHostMessage> deleter(msg);
EndDecoding();
}
diff --git a/remoting/client/plugin/pepper_view.h b/remoting/client/plugin/pepper_view.h
index d134207..5e12dce 100644
--- a/remoting/client/plugin/pepper_view.h
+++ b/remoting/client/plugin/pepper_view.h
@@ -42,9 +42,9 @@ class PepperView : public ChromotingView {
virtual void UnsetSolidFill();
virtual void SetViewport(int x, int y, int width, int height);
virtual void SetHostScreenSize(int width, int height);
- virtual void HandleBeginUpdateStream(HostMessage* msg);
- virtual void HandleUpdateStreamPacket(HostMessage* msg);
- virtual void HandleEndUpdateStream(HostMessage* msg);
+ virtual void HandleBeginUpdateStream(ChromotingHostMessage* msg);
+ virtual void HandleUpdateStreamPacket(ChromotingHostMessage* msg);
+ virtual void HandleEndUpdateStream(ChromotingHostMessage* msg);
private:
void OnPaintDone();
diff --git a/remoting/client/x11_input_handler.cc b/remoting/client/x11_input_handler.cc
index 455ff61..887862c 100644
--- a/remoting/client/x11_input_handler.cc
+++ b/remoting/client/x11_input_handler.cc
@@ -9,8 +9,8 @@
#include "remoting/client/x11_view.h"
#include "remoting/jingle_glue/jingle_thread.h"
-// Include Xlib at the end because it clashes with ClientMessage defined in
-// the protocol buffer.
+// Include Xlib at the end because it clashes with Status in
+// base/tracked_objects.h.
#include <X11/Xlib.h>
namespace remoting {
diff --git a/remoting/client/x11_view.cc b/remoting/client/x11_view.cc
index 267ae336..e40891a 100644
--- a/remoting/client/x11_view.cc
+++ b/remoting/client/x11_view.cc
@@ -157,8 +157,8 @@ void X11View::InitPaintTarget() {
CHECK(picture_) << "Backing picture not created";
}
-void X11View::HandleBeginUpdateStream(HostMessage* msg) {
- scoped_ptr<HostMessage> deleter(msg);
+void X11View::HandleBeginUpdateStream(ChromotingHostMessage* msg) {
+ scoped_ptr<ChromotingHostMessage> deleter(msg);
// Make sure the |frame_| is initialized.
if (!frame_) {
@@ -170,7 +170,7 @@ void X11View::HandleBeginUpdateStream(HostMessage* msg) {
}
}
-void X11View::HandleUpdateStreamPacket(HostMessage* msg) {
+void X11View::HandleUpdateStreamPacket(ChromotingHostMessage* msg) {
// Lazily initialize the decoder.
SetupDecoder(msg->update_stream_packet().begin_rect().encoding());
if (!decoder_->IsStarted()) {
@@ -181,8 +181,8 @@ void X11View::HandleUpdateStreamPacket(HostMessage* msg) {
Decode(msg);
}
-void X11View::HandleEndUpdateStream(HostMessage* msg) {
- scoped_ptr<HostMessage> deleter(msg);
+void X11View::HandleEndUpdateStream(ChromotingHostMessage* msg) {
+ scoped_ptr<ChromotingHostMessage> deleter(msg);
EndDecoding();
}
diff --git a/remoting/client/x11_view.h b/remoting/client/x11_view.h
index d2a52d5..3ae7f2a 100644
--- a/remoting/client/x11_view.h
+++ b/remoting/client/x11_view.h
@@ -29,9 +29,9 @@ class X11View : public ChromotingView {
virtual void UnsetSolidFill();
virtual void SetViewport(int x, int y, int width, int height);
virtual void SetHostScreenSize(int width, int height);
- virtual void HandleBeginUpdateStream(HostMessage* msg);
- virtual void HandleUpdateStreamPacket(HostMessage* msg);
- virtual void HandleEndUpdateStream(HostMessage* msg);
+ virtual void HandleBeginUpdateStream(ChromotingHostMessage* msg);
+ virtual void HandleUpdateStreamPacket(ChromotingHostMessage* msg);
+ virtual void HandleEndUpdateStream(ChromotingHostMessage* msg);
Display* display() { return display_; }