Bug 983347 - Need different paths for displaying to the screen and sending over the wire, purple part. r=florian,clokep
authorArlo Breault <arlolra@gmail.com>
Thu, 11 Sep 2014 12:11:48 -0700
changeset 750 d971cac153eee1e43be74ccd844e1e8ffb513309
parent 749 ff0c1a9ea8eb1b65c56b9e46f7fd739e8916f7cb
child 751 ecb887e33c3395414037709cf07c5231e4941808
push id30
push userclokep@gmail.com
push dateSun, 14 Sep 2014 20:51:18 +0000
reviewersflorian, clokep
bugs983347
Bug 983347 - Need different paths for displaying to the screen and sending over the wire, purple part. r=florian,clokep
purplexpcom/src/purpleConvChat.h
purplexpcom/src/purpleConvIM.h
purplexpcom/src/purpleConversation.cpp
--- a/purplexpcom/src/purpleConvChat.h
+++ b/purplexpcom/src/purpleConvChat.h
@@ -55,16 +55,19 @@ public:
     return purpleConversation::Close();
   }
   NS_IMETHOD AddObserver(nsIObserver *aObserver) {
     return purpleConversation::AddObserver(aObserver);
   }
   NS_IMETHOD RemoveObserver(nsIObserver *aObserver) {
     return purpleConversation::RemoveObserver(aObserver);
   }
+  NS_IMETHOD PrepareForSending(imIOutgoingMessage *message, uint32_t *messageCount, char16_t * **messages) {
+    return purpleConversation::PrepareForSending(message, messageCount, messages);
+  }
 
   // Keep the SendMsg method here
   NS_IMETHOD SendMsg(const nsACString & aMsg);
 
   purpleConvChat();
 
 private:
   ~purpleConvChat();
--- a/purplexpcom/src/purpleConvIM.h
+++ b/purplexpcom/src/purpleConvIM.h
@@ -50,16 +50,19 @@ public:
     return purpleConversation::Close();
   }
   NS_IMETHOD AddObserver(nsIObserver *aObserver) {
     return purpleConversation::AddObserver(aObserver);
   }
   NS_IMETHOD RemoveObserver(nsIObserver *aObserver) {
     return purpleConversation::RemoveObserver(aObserver);
   }
+  NS_IMETHOD PrepareForSending(imIOutgoingMessage *message, uint32_t *messageCount, char16_t * **messages) {
+    return purpleConversation::PrepareForSending(message, messageCount, messages);
+  }
 
   // Keep the SendMsg and SendTyping methods here.
   NS_IMETHOD SendMsg(const nsACString & aMsg);
   NS_IMETHODIMP SendTyping(const nsACString & aString, int32_t *_retval);
 
   purpleConvIM();
 
 private:
--- a/purplexpcom/src/purpleConversation.cpp
+++ b/purplexpcom/src/purpleConversation.cpp
@@ -146,16 +146,23 @@ NS_IMETHODIMP purpleConversation::SetId(
 }
 
 /* void sendMsg (in AUTF8String aMsg); */
 NS_IMETHODIMP purpleConversation::SendMsg(const nsACString& aMsg)
 {
   return NS_ERROR_NOT_IMPLEMENTED;
 }
 
+/* void prepareForSending (in imIOutgoingMessage message, [optional] out unsigned long messageCount, [array, size_is (messageCount), retval] out wstring messages); */
+NS_IMETHODIMP purpleConversation::PrepareForSending(imIOutgoingMessage *message, uint32_t *messageCount, char16_t * **messages)
+{
+  messages = NULL;
+  return NS_OK;
+}
+
 /* void sendTyping (in unsigned long aLength); */
 NS_IMETHODIMP purpleConversation::SendTyping(const nsACString & aString, int32_t *_retval)
 {
   *_retval = purpleConversation::NO_TYPING_LIMIT;
   return NS_OK;
 }
 
 /* void close (); */