[ekiga] CallCore/CallManager: Removed message method.



commit 9b11080ad3fb6baaa1d173108a75c81cb26cdfb2
Author: Damien Sandras <dsandras seconix com>
Date:   Tue Jan 13 22:10:08 2015 +0100

    CallCore/CallManager: Removed message method.
    
    This should not be part of the Call API. Julien is designing something
    new for this.

 lib/engine/components/opal/opal-call-manager.cpp |   13 -------------
 lib/engine/components/opal/opal-call-manager.h   |    2 --
 lib/engine/components/opal/sip-endpoint.cpp      |   11 -----------
 lib/engine/components/opal/sip-endpoint.h        |    2 --
 lib/engine/protocol/call-core.cpp                |   14 --------------
 lib/engine/protocol/call-core.h                  |   10 ----------
 lib/engine/protocol/call-manager.h               |   16 +++-------------
 lib/engine/protocol/call-protocol-manager.h      |   12 +-----------
 8 files changed, 4 insertions(+), 76 deletions(-)
---
diff --git a/lib/engine/components/opal/opal-call-manager.cpp 
b/lib/engine/components/opal/opal-call-manager.cpp
index 1fb0971..92d7979 100644
--- a/lib/engine/components/opal/opal-call-manager.cpp
+++ b/lib/engine/components/opal/opal-call-manager.cpp
@@ -571,19 +571,6 @@ bool CallManager::transfer (const std::string & uri,
 }
 
 
-bool CallManager::message (const Ekiga::ContactPtr & contact,
-                           const std::string & uri)
-{
-  for (Ekiga::CallManager::iterator iter = Ekiga::CallManager::begin ();
-       iter != Ekiga::CallManager::end ();
-       iter++)
-    if ((*iter)->message (contact, uri))
-      return true;
-
-  return false;
-}
-
-
 bool CallManager::is_supported_uri (const std::string & uri)
 {
   for (Ekiga::CallManager::iterator iter = Ekiga::CallManager::begin ();
diff --git a/lib/engine/components/opal/opal-call-manager.h b/lib/engine/components/opal/opal-call-manager.h
index dbe5de2..2108cd0 100644
--- a/lib/engine/components/opal/opal-call-manager.h
+++ b/lib/engine/components/opal/opal-call-manager.h
@@ -108,8 +108,6 @@ public:
     void hang_up ();
     bool transfer (const std::string & uri,
                    bool attended);
-    bool message (const Ekiga::ContactPtr & contact,
-                  const std::string & uri);
     bool is_supported_uri (const std::string & uri);
 
     void set_display_name (const std::string & name);
diff --git a/lib/engine/components/opal/sip-endpoint.cpp b/lib/engine/components/opal/sip-endpoint.cpp
index 97017e3..3c1df70 100644
--- a/lib/engine/components/opal/sip-endpoint.cpp
+++ b/lib/engine/components/opal/sip-endpoint.cpp
@@ -175,17 +175,6 @@ Opal::Sip::EndPoint::transfer (const std::string & uri,
 }
 
 
-bool
-Opal::Sip::EndPoint::message (const Ekiga::ContactPtr & contact,
-                              const std::string & uri)
-{
-  if (!is_supported_uri (uri))
-    return false;
-
-  dialect->start_chat_with (uri, contact->get_name ());
-  return true;
-}
-
 
 bool
 Opal::Sip::EndPoint::is_supported_uri (const std::string & uri)
diff --git a/lib/engine/components/opal/sip-endpoint.h b/lib/engine/components/opal/sip-endpoint.h
index 4c2fc3c..8888205 100644
--- a/lib/engine/components/opal/sip-endpoint.h
+++ b/lib/engine/components/opal/sip-endpoint.h
@@ -93,8 +93,6 @@ namespace Opal {
       bool dial (const std::string & uri);
       bool transfer (const std::string & uri,
                      bool attended);
-      bool message (const Ekiga::ContactPtr & contact,
-                    const std::string & uri);
       bool is_supported_uri (const std::string & uri);
 
 
diff --git a/lib/engine/protocol/call-core.cpp b/lib/engine/protocol/call-core.cpp
index 52a9565..817caab 100644
--- a/lib/engine/protocol/call-core.cpp
+++ b/lib/engine/protocol/call-core.cpp
@@ -120,20 +120,6 @@ bool CallCore::transfer (const std::string & uri,
 }
 
 
-bool CallCore::message (const ContactPtr & contact,
-                        const std::string & uri)
-{
-  for (std::set<boost::shared_ptr<CallManager> >::iterator iter = managers.begin ();
-       iter != managers.end ();
-       iter++) {
-    if ((*iter)->message (contact, uri))
-      return true;
-  }
-
-  return false;
-}
-
-
 bool CallCore::is_supported_uri (const std::string & uri)
 {
   for (std::set<boost::shared_ptr<CallManager> >::iterator iter = managers.begin ();
diff --git a/lib/engine/protocol/call-core.h b/lib/engine/protocol/call-core.h
index b62a643..0eabff0 100644
--- a/lib/engine/protocol/call-core.h
+++ b/lib/engine/protocol/call-core.h
@@ -147,16 +147,6 @@ namespace Ekiga
       bool transfer (const std::string & uri,
                      bool attended);
 
-      /** Sends an instant message to the given contact
-       * @param the destination contact
-       * @param the destination uri
-       * @return true if the message transmission could be attempted,
-       *         false otherwise. Returning true does not mean the
-       *         message was sent, it simply means it could be handled.
-       */
-      bool message (const ContactPtr & contact,
-                    const std::string & uri);
-
       /** Hang up all active calls (if any).
        */
       void hang_up ();
diff --git a/lib/engine/protocol/call-manager.h b/lib/engine/protocol/call-manager.h
index 076a69f..a135f92 100644
--- a/lib/engine/protocol/call-manager.h
+++ b/lib/engine/protocol/call-manager.h
@@ -47,7 +47,6 @@
 
 #include "call-protocol-manager.h"
 #include "codec-description.h"
-#include "contact-core.h" // FIXME: required for 'message'. Should disappear.
 
 namespace Ekiga
 {
@@ -127,15 +126,6 @@ namespace Ekiga
     virtual bool transfer (const std::string & uri,
                            bool attended) = 0;
 
-    /** Sends an instant message to the given contact
-     * @param the destination contact
-     * @param the destination uri
-     * @return true if the message transmission could be attempted,
-     *         false otherwise. Returning true does not mean the
-     *         message was sent, it simply means it could be handled.
-     */
-    virtual bool message (const ContactPtr & contact,
-                          const std::string & uri) = 0;
 
     /* Return true if URI can be handled by the CallCore,
      * false otherwise.
@@ -209,17 +199,17 @@ namespace Ekiga
      */
     virtual bool get_silence_detection () const = 0;
 
-    /** Set maximum jitter 
+    /** Set maximum jitter
      * @param max_val is the maximum jitter for calls in seconds.
      */
     virtual void set_maximum_jitter (unsigned max_val) = 0;
 
-    /** Get maximum jitter 
+    /** Get maximum jitter
      * @return the maximum jitter for calls in seconds.
      */
     virtual unsigned get_maximum_jitter () const = 0;
 
-    /** Set delay before dropping an incoming call 
+    /** Set delay before dropping an incoming call
      * @param delay is the delay after which the call should be rejected
      * (or forwarded if supported by the CallManager).
      */
diff --git a/lib/engine/protocol/call-protocol-manager.h b/lib/engine/protocol/call-protocol-manager.h
index 14e61bb..5dda398 100644
--- a/lib/engine/protocol/call-protocol-manager.h
+++ b/lib/engine/protocol/call-protocol-manager.h
@@ -27,7 +27,7 @@
 /*
  *                         call-protocol-manager.h  -  description
  *                         ------------------------------------------
- *   begin                : written in 2008 by Damien Sandras 
+ *   begin                : written in 2008 by Damien Sandras
  *   copyright            : (c) 2008 by Damien Sandras
  *   description          : Declaration of the interface of a call protocol manager
  *                          implementation backend. A call manager handles calls
@@ -98,16 +98,6 @@ namespace Ekiga
     virtual bool transfer (const std::string & uri,
                            bool attended) = 0;
 
-    /** Sends an instant message to the given contact
-     * @param the destination contact
-     * @param the destination uri
-     * @return true if the message transmission could be attempted,
-     *         false otherwise. Returning true does not mean the
-     *         message was sent, it simply means it could be handled.
-     */
-    virtual bool message (const ContactPtr & contact,
-                          const std::string & uri) = 0;
-
     /* Return true if URI can be handled by the CallCore,
      * false otherwise.
      * @param the URI to test


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]