diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index ae0eb17f17f4001237e6fea70b61a68d833d172e..6934d5c505d0a4e8a7dab567ff7dbc039e2809a4 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -7,19 +7,16 @@ endif(POLICY CMP0022) INCLUDE(GNUInstallDirs) ADD_DEFINITIONS("-std=c++0x") -# ADD_DEFINITIONS("-std=c++0x") ADD_DEFINITIONS( - ${QT_DEFINITIONS} - -fexceptions + ${QT_DEFINITIONS} + -fexceptions ) -PROJECT(qtsflphone) +PROJECT(ringclient) SET(CMAKE_AUTOMOC TRUE) -#target_link_libraries(qtsflphone ${QT_QTCORE_LIBRARY} ${KDE4_KDEUI_LIBS}) - SET(LOCAL_CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/") SET(CMAKE_MODULE_PATH "${LOCAL_CMAKE_MODULE_PATH}") @@ -47,7 +44,7 @@ INCLUDE_DIRECTORIES ( ${CMAKE_CURRENT_BINARY_DIR}) SET ( dbus_xml_introspecs_path ${CMAKE_CURRENT_SOURCE_DIR}/dbus/) #File to compile -set( qtsflphone_LIB_SRCS +set( libringclient_LIB_SRCS #Data objects call.cpp uri.cpp @@ -121,7 +118,6 @@ set( qtsflphone_LIB_SRCS visitors/itemmodelstateserializationvisitor.cpp #Other - sflphone_const.h categorizedcompositenode.cpp hookmanager.cpp @@ -129,7 +125,7 @@ set( qtsflphone_LIB_SRCS extensions/presenceitembackendmodelextension.cpp ) -set( qtsflphone_LIB_HDRS +set( libringclient_LIB_HDRS account.h accountmodel.h call.h @@ -163,6 +159,7 @@ set( qtsflphone_LIB_HDRS itembackendmodel.h hookmanager.h uri.h + mime.h abstractitembackendmodelextension.h video/device.h video/devicemodel.h @@ -186,9 +183,8 @@ set( qtsflphone_LIB_HDRS #commonbackendmanagerinterface.h ) -set( qtsflphone_extra_LIB_HDRS +set( libringclient_extra_LIB_HDRS typedefs.h - sflphone_const.h visitors/accountlistcolorvisitor.h visitors/phonenumberselector.h visitors/presenceserializationvisitor.h @@ -206,13 +202,13 @@ SET_SOURCE_FILES_PROPERTIES( IF(${ENABLE_QT5} MATCHES true) QT5_ADD_DBUS_INTERFACE( - qtsflphone_LIB_SRCS + libringclient_LIB_SRCS ${presencemanager_xml} presencemanager_dbus_interface ) ELSE() QT4_ADD_DBUS_INTERFACE( - qtsflphone_LIB_SRCS + libringclient_LIB_SRCS ${presencemanager_xml} presencemanager_dbus_interface ) @@ -230,13 +226,13 @@ SET_SOURCE_FILES_PROPERTIES( IF(${ENABLE_QT5} MATCHES true) QT5_ADD_DBUS_INTERFACE( - qtsflphone_LIB_SRCS + libringclient_LIB_SRCS ${configurationmanager_xml} configurationmanager_dbus_interface ) ELSE() QT4_ADD_DBUS_INTERFACE( - qtsflphone_LIB_SRCS + libringclient_LIB_SRCS ${configurationmanager_xml} configurationmanager_dbus_interface ) @@ -254,13 +250,13 @@ SET_SOURCE_FILES_PROPERTIES( IF(${ENABLE_QT5} MATCHES true) QT5_ADD_DBUS_INTERFACE( - qtsflphone_LIB_SRCS + libringclient_LIB_SRCS ${callmanager_xml} callmanager_dbus_interface ) ELSE() QT4_ADD_DBUS_INTERFACE( - qtsflphone_LIB_SRCS + libringclient_LIB_SRCS ${callmanager_xml} callmanager_dbus_interface ) @@ -278,13 +274,13 @@ SET_SOURCE_FILES_PROPERTIES( IF(${ENABLE_QT5} MATCHES true) QT5_ADD_DBUS_INTERFACE( - qtsflphone_LIB_SRCS + libringclient_LIB_SRCS ${video_xml} video_dbus_interface ) ELSE() QT4_ADD_DBUS_INTERFACE( - qtsflphone_LIB_SRCS + libringclient_LIB_SRCS ${video_xml} video_dbus_interface ) @@ -302,67 +298,68 @@ SET_SOURCE_FILES_PROPERTIES( IF(${ENABLE_QT5} MATCHES true) QT5_ADD_DBUS_INTERFACE( - qtsflphone_LIB_SRCS + libringclient_LIB_SRCS ${instance_xml} instance_dbus_interface ) ELSE() QT4_ADD_DBUS_INTERFACE( - qtsflphone_LIB_SRCS + libringclient_LIB_SRCS ${instance_xml} instance_dbus_interface ) ENDIF(${ENABLE_QT5} MATCHES true) # Manually wrap private files -SET(qtsflphone_PRIVATE_HDRS +SET(libringclient_PRIVATE_HDRS private/call_p.h private/phonedirectorymodel_p.h private/instantmessagingmodel_p.h ) IF(${ENABLE_QT5} MATCHES true) - QT5_WRAP_CPP(LIB_HEADER_MOC ${qtsflphone_PRIVATE_HDRS}) + QT5_WRAP_CPP(LIB_HEADER_MOC ${libringclient_PRIVATE_HDRS}) ELSE() - QT4_WRAP_CPP(LIB_HEADER_MOC ${qtsflphone_PRIVATE_HDRS}) + QT4_WRAP_CPP(LIB_HEADER_MOC ${libringclient_PRIVATE_HDRS}) ENDIF(${ENABLE_QT5} MATCHES true) -add_library( qtsflphone SHARED ${qtsflphone_LIB_SRCS} ${LIB_HEADER_MOC} ) +add_library( ringclient SHARED ${libringclient_LIB_SRCS} ${LIB_HEADER_MOC} ) +add_library( ringclient_static STATIC ${libringclient_LIB_SRCS} ${LIB_HEADER_MOC} ) # REMOVE_DEFINITIONS("-w") IF(${ENABLE_QT5} MATCHES true) - QT5_USE_MODULES(qtsflphone Core DBus) + QT5_USE_MODULES(ringclient Core DBus) ENDIF(${ENABLE_QT5} MATCHES true) IF(${CMAKE_SYSTEM_NAME} MATCHES "Linux") SET(LINK_LIBRT "-lrt") ENDIF() -target_link_libraries( qtsflphone +target_link_libraries( ringclient ${LINK_LIBRT} -lpthread ${QT_QTDBUS_LIBRARY} ${QT_QTCORE_LIBRARY} ) -set_target_properties( qtsflphone +set_target_properties( ringclient PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_VERSION} ) SET(INCLUDE_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/include) -install( FILES ${qtsflphone_LIB_HDRS} ${qtsflphone_extra_LIB_HDRS} - DESTINATION ${INCLUDE_INSTALL_DIR}/qtsflphone +install( FILES ${libringclient_LIB_HDRS} ${libringclient_extra_LIB_HDRS} + DESTINATION ${INCLUDE_INSTALL_DIR}/libringclient COMPONENT Devel ) #This hack force Debian based system to return a non multi-arch path -#this is required to prevent the .deb libqtsflphone.so from having an +#this is required to prevent the .deb libringclient.so from having an #higher priority than the prefixed one. STRING(REPLACE "${CMAKE_LIBRARY_ARCHITECTURE}" "" SANE_LIBRARY_PATH "${CMAKE_INSTALL_FULL_LIBDIR}" ) -install( TARGETS qtsflphone +install( TARGETS ringclient ARCHIVE DESTINATION ${SANE_LIBRARY_PATH} LIBRARY DESTINATION ${SANE_LIBRARY_PATH} DESTINATION ${SANE_LIBRARY_PATH} diff --git a/src/Messages.sh b/src/Messages.sh index 8734a9e454d050d11ace0d094be819568ccbc098..ab5cdd89a87cf624da97518d4c8cd4918acde537 100755 --- a/src/Messages.sh +++ b/src/Messages.sh @@ -1,3 +1,3 @@ #! /bin/sh -$XGETTEXT_QT `find . -name '*.cpp'` -o $podir/sflphone-client-kde_qt.pot +$XGETTEXT_QT `find . -name '*.cpp'` -o $podir/ring-kde_qt.pot diff --git a/src/abstractbookmarkmodel.cpp b/src/abstractbookmarkmodel.cpp index 9f23699db523c3ffd6de876998e1caeaae36cd8e..b1e94e52a822bbbadcfa7573758e9149fcf513c3 100644 --- a/src/abstractbookmarkmodel.cpp +++ b/src/abstractbookmarkmodel.cpp @@ -20,7 +20,7 @@ //Qt #include <QtCore/QMimeData> -//SFLPhone +//Ring #include "historymodel.h" #include "dbus/presencemanager.h" #include "phonedirectorymodel.h" @@ -28,6 +28,7 @@ #include "callmodel.h" #include "call.h" #include "uri.h" +#include "mime.h" #include "abstractitembackend.h" static bool test = false; @@ -70,7 +71,7 @@ QObject* AbstractBookmarkModel::TopLevelItem::getSelf() const AbstractBookmarkModel::AbstractBookmarkModel(QObject* parent) : QAbstractItemModel(parent){ setObjectName("AbstractBookmarkModel"); reloadCategories(); - m_lMimes << MIME_PLAIN_TEXT << MIME_PHONENUMBER; + m_lMimes << RingMimes::PLAIN_TEXT << RingMimes::PHONENUMBER; //Connect connect(&DBus::PresenceManager::instance(),SIGNAL(newServerSubscriptionRequest(QString)),this,SLOT(slotRequest(QString))); @@ -259,8 +260,8 @@ QMimeData* AbstractBookmarkModel::mimeData(const QModelIndexList &indexes) const foreach (const QModelIndex &index, indexes) { if (index.isValid()) { QString text = data(index, Call::Role::Number).toString(); - mimeData->setData(MIME_PLAIN_TEXT , text.toUtf8()); - mimeData->setData(MIME_PHONENUMBER, text.toUtf8()); + mimeData->setData(RingMimes::PLAIN_TEXT , text.toUtf8()); + mimeData->setData(RingMimes::PHONENUMBER, text.toUtf8()); return mimeData; } } diff --git a/src/abstractbookmarkmodel.h b/src/abstractbookmarkmodel.h index 1b7efd58d96ae74fe90c1a4ac3f599ddefc69696..527b1a2e383fa19e568e9106ee8087d15bb15c36 100644 --- a/src/abstractbookmarkmodel.h +++ b/src/abstractbookmarkmodel.h @@ -23,7 +23,7 @@ #include <QtCore/QStringList> #include <QtCore/QDateTime> -//SFLPhone +//Ring #include "../lib/typedefs.h" #include "../lib/contact.h" #include "../lib/call.h" diff --git a/src/abstractitembackend.cpp b/src/abstractitembackend.cpp index 21a2c4a1392492662daa7b12864a519972d7ae24..7148cafc5932aee620687f0fa894199363f2b3e0 100644 --- a/src/abstractitembackend.cpp +++ b/src/abstractitembackend.cpp @@ -20,7 +20,7 @@ //Parent #include "abstractitembackend.h" -//SFLPhone library +//Ring library #include "contact.h" #include "call.h" #include "phonenumber.h" diff --git a/src/abstractitembackend.h b/src/abstractitembackend.h index 53882a75a669fc99a175cfbd5064e19b577e1429..ca280af2275b99bb61d28e733d485a3ab6f4da40 100644 --- a/src/abstractitembackend.h +++ b/src/abstractitembackend.h @@ -27,7 +27,7 @@ #include "typedefs.h" #include "contact.h" -//SFLPhone +//Ring class Contact; class Account; class Call ; diff --git a/src/account.cpp b/src/account.cpp index 62d979bbc5a5bd82e81623232cf50dac0fc984e6..3a9d91389e4bebe0c824f5d6d6dda0d0ba76de37 100644 --- a/src/account.cpp +++ b/src/account.cpp @@ -25,10 +25,7 @@ #include <QtCore/QObject> #include <QtCore/QString> -//SFLPhone -#include "sflphone_const.h" - -//SFLPhone lib +//Ring lib #include "dbus/configurationmanager.h" #include "dbus/callmanager.h" #include "dbus/videomanager.h" diff --git a/src/account.h b/src/account.h index 3cff06563799dcedc67cfc8a6a690fb58cfe7eb1..368b79da2bd3887a1482543774c9681629361c4a 100644 --- a/src/account.h +++ b/src/account.h @@ -25,11 +25,10 @@ //Qt class QString; -//SFLPhone +//Ring #include "video/codecmodel2.h" #include "keyexchangemodel.h" #include "tlsmethodmodel.h" -#include "sflphone_const.h" #include "typedefs.h" class CredentialModel; class RingToneModel ; @@ -400,8 +399,8 @@ class LIB_EXPORT Account : public QObject { QVariant roleData (int role) const; //Setters - void setId (const QString& id); - void setAlias (const QString& detail); + void setId (const QString& id ); + void setAlias (const QString& detail ); void setProtocol (Account::Protocol proto); void setHostname (const QString& detail ); void setUsername (const QString& detail ); diff --git a/src/accountmodel.cpp b/src/accountmodel.cpp index 32ba085496f249623a27e82024f717991ff2587a..41721235ee351c61bc8e5afe5195079266e85ebb 100644 --- a/src/accountmodel.cpp +++ b/src/accountmodel.cpp @@ -16,17 +16,13 @@ * You should have received a copy of the GNU General Public License * * along with this program. If not, see <http://www.gnu.org/licenses/>. * ***************************************************************************/ - //Parent #include "accountmodel.h" -//SFLPhone -#include "sflphone_const.h" - //Qt #include <QtCore/QObject> -//SFLPhone library +//Ring library #include "dbus/configurationmanager.h" #include "dbus/callmanager.h" #include "visitors/accountlistcolorvisitor.h" diff --git a/src/audio/alsapluginmodel.cpp b/src/audio/alsapluginmodel.cpp index 6ac4fa5e57844899ec931043d8ec4de1ab8d197f..482849cb62a85c5e45a22c0017f485a98d9ec99a 100644 --- a/src/audio/alsapluginmodel.cpp +++ b/src/audio/alsapluginmodel.cpp @@ -17,7 +17,7 @@ ***************************************************************************/ #include "alsapluginmodel.h" -//SFLPhone +//Ring #include "dbus/configurationmanager.h" class AlsaPluginModelPrivate : public QObject diff --git a/src/audio/alsapluginmodel.h b/src/audio/alsapluginmodel.h index fde12a405e0645cf220bb1b53b980075df644397..84d41854aa8a004f452d11e58b7f3bad1f454776 100644 --- a/src/audio/alsapluginmodel.h +++ b/src/audio/alsapluginmodel.h @@ -23,7 +23,7 @@ //Qt #include <QtCore/QStringList> -//SFLPhone +//Ring #include "../typedefs.h" class AlsaPluginModelPrivate; diff --git a/src/audio/codecmodel.cpp b/src/audio/codecmodel.cpp index 02b6c973fce962300d3433360fbcf49d37b0b8eb..1b350f78672fb03e55d0a06ba66d94ecfa9efb8d 100644 --- a/src/audio/codecmodel.cpp +++ b/src/audio/codecmodel.cpp @@ -21,7 +21,7 @@ #include <QtCore/QDebug> #include <QtCore/QCoreApplication> -//SFLPhone +//Ring #include "account.h" #include "dbus/configurationmanager.h" diff --git a/src/audio/codecmodel.h b/src/audio/codecmodel.h index 8aef1b2b2338a88d687703a1d6f1360ddd9f24c2..9b8e420e355cda7f1aa18acc24a17f4d54465603 100644 --- a/src/audio/codecmodel.h +++ b/src/audio/codecmodel.h @@ -23,7 +23,7 @@ //Qt #include <QtCore/QString> -//SFLPhone +//Ring #include "../typedefs.h" class Account; diff --git a/src/audio/inputdevicemodel.cpp b/src/audio/inputdevicemodel.cpp index ce96458b25b35410cbc2a76d0b34dbbe023c5176..9e510299c688d731126eb40fd9ac1bf612518d23 100644 --- a/src/audio/inputdevicemodel.cpp +++ b/src/audio/inputdevicemodel.cpp @@ -17,7 +17,7 @@ ***************************************************************************/ #include "inputdevicemodel.h" -//SFLPhone +//Ring #include "dbus/configurationmanager.h" #include "settings.h" diff --git a/src/audio/inputdevicemodel.h b/src/audio/inputdevicemodel.h index 01c3ca3eb5ed178d4cdd3145ade0728ebac73840..2abc25df3f0b5f3c6b4bb5e4dbb8cc2a5acb7b5c 100644 --- a/src/audio/inputdevicemodel.h +++ b/src/audio/inputdevicemodel.h @@ -23,7 +23,7 @@ //Qt #include <QtCore/QStringList> -//SFLPhone +//Ring #include "../typedefs.h" class InputDeviceModelPrivate; diff --git a/src/audio/managermodel.cpp b/src/audio/managermodel.cpp index dec6550ec447b95ff0f4ab77c8b2b23c2e8a9871..9fd9af47e08920f144a167d63f8779f0afb17e4e 100644 --- a/src/audio/managermodel.cpp +++ b/src/audio/managermodel.cpp @@ -17,7 +17,7 @@ ***************************************************************************/ #include "managermodel.h" -//SFLPhone +//Ring #include "dbus/configurationmanager.h" #include "settings.h" diff --git a/src/audio/managermodel.h b/src/audio/managermodel.h index 6b5a2f9e0bed67ad3d3bf70a8c41520760ee4102..5ed998ca1c22da13e583a120cfc4430dbf2a4fbb 100644 --- a/src/audio/managermodel.h +++ b/src/audio/managermodel.h @@ -23,7 +23,7 @@ //Qt #include <QtCore/QStringList> -//SFLPhone +//Ring #include "../typedefs.h" class ManagerModelPrivate; diff --git a/src/audio/outputdevicemodel.cpp b/src/audio/outputdevicemodel.cpp index c59d6c9401eb343c5c79c4c200b9e568830c86bd..34900d2b221e343fec1516872fbe0085c84ef65a 100644 --- a/src/audio/outputdevicemodel.cpp +++ b/src/audio/outputdevicemodel.cpp @@ -17,7 +17,7 @@ ***************************************************************************/ #include "outputdevicemodel.h" -//SFLPhone +//Ring #include "dbus/configurationmanager.h" #include "settings.h" diff --git a/src/audio/outputdevicemodel.h b/src/audio/outputdevicemodel.h index ac6572ae9685500d5226d508fa7346ec5bf0d9c9..024e828d75d73e2c832b2386753744261805cb31 100644 --- a/src/audio/outputdevicemodel.h +++ b/src/audio/outputdevicemodel.h @@ -23,7 +23,7 @@ //Qt #include <QtCore/QStringList> -//SFLPhone +//Ring #include "../typedefs.h" class OutputDeviceModelPrivate; diff --git a/src/audio/ringtonedevicemodel.cpp b/src/audio/ringtonedevicemodel.cpp index 7b792f19aaf10ebd3f55330f470ff941036bf973..aa2d308eb1bd053c7eb89ff5cb129bd00f796fe7 100644 --- a/src/audio/ringtonedevicemodel.cpp +++ b/src/audio/ringtonedevicemodel.cpp @@ -17,7 +17,7 @@ ***************************************************************************/ #include "ringtonedevicemodel.h" -//SFLPhone +//Ring #include "dbus/configurationmanager.h" #include "settings.h" diff --git a/src/audio/ringtonedevicemodel.h b/src/audio/ringtonedevicemodel.h index 2250e96ff2cb24794029827074f57498d7fdf7cf..54b6715abf15ff69c170125fff71ca593025da79 100644 --- a/src/audio/ringtonedevicemodel.h +++ b/src/audio/ringtonedevicemodel.h @@ -23,7 +23,7 @@ //Qt #include <QtCore/QStringList> -//SFLPhone +//Ring #include "../typedefs.h" class RingtoneDeviceModelPrivate; diff --git a/src/audio/settings.cpp b/src/audio/settings.cpp index 743b84af3dae80d0ddff4b4ca9d598b85c6d4c2f..bd18600c76cc9f730834133dc6917a540824211a 100644 --- a/src/audio/settings.cpp +++ b/src/audio/settings.cpp @@ -17,7 +17,7 @@ ***************************************************************************/ #include "settings.h" -//SFLPhone +//Ring #include "dbus/configurationmanager.h" #include "dbus/callmanager.h" #include "ringtonedevicemodel.h" diff --git a/src/audio/settings.h b/src/audio/settings.h index db915732cf1bf9a0e796988f9d171de3df1b7f9d..a19ed231da584185491ce33e5c6b652f23ffd79a 100644 --- a/src/audio/settings.h +++ b/src/audio/settings.h @@ -20,7 +20,7 @@ #include <QtCore/QAbstractListModel> -//SFLPhone +//Ring #include "../typedefs.h" diff --git a/src/call.cpp b/src/call.cpp index 6094bc393adf44fd1e5fbb1129286a9ec556a5e9..85272bafc3545e43afc40bd31e362da5be55a6fd 100644 --- a/src/call.cpp +++ b/src/call.cpp @@ -28,7 +28,7 @@ #include <QtCore/QTimer> -//SFLPhone library +//Ring library #include "dbus/callmanager.h" #include "dbus/configurationmanager.h" #include "abstractitembackend.h" @@ -1080,8 +1080,8 @@ void CallPrivate::error() //Well, in this case we have no choice, it still doesn't belong here q_ptr->videoRenderer()->stopRendering(); } - throw QString("There was an error handling your call, please restart SFLPhone.Is you encounter this problem often, \ - please open SFLPhone-KDE in a terminal and send this last 100 lines before this message in a bug report at \ + throw QString("There was an error handling your call, please restart Ring.Is you encounter this problem often, \ + please open Ring-KDE in a terminal and send this last 100 lines before this message in a bug report at \ https://projects.savoirfairelinux.com/projects/sflphone/issues"); } @@ -1239,7 +1239,7 @@ void CallPrivate::call() qDebug() << "Account is not set, taking the first registered."; this->m_Account = AccountModel::currentAccount(); } - //Calls to empty URI should not be allowed, sflphoned will go crazy + //Calls to empty URI should not be allowed, dring will go crazy if ((!m_pDialNumber) || m_pDialNumber->uri().isEmpty()) { qDebug() << "Trying to call an empty URI"; changeCurrentState(Call::State::FAILURE); @@ -1386,7 +1386,7 @@ void CallPrivate::warning() //If not stopped, then the counter will keep going //Getting here indicate something wrong happened //It can be normal, aka, an invalid URI such as '><' - // or an SFLPhone-KDE bug + // or an Ring-KDE bug stop(); break; case Call::State::TRANSFERRED : diff --git a/src/call.h b/src/call.h index a6b215a7e4c8e910d8fc635174f59f2145bb4888..a65dad6687403f97461e7d4a080be8ee4bba514b 100644 --- a/src/call.h +++ b/src/call.h @@ -27,8 +27,7 @@ class QString; class QTimer; -//SFLPhone -#include "sflphone_const.h" +//Ring #include "typedefs.h" #include "historytimecategorymodel.h" class Account; @@ -152,7 +151,7 @@ public: * History items create before December 2013 will have a "state" field * mixing direction and missed. Newer items will have separated fields for that. * - * SFLPhone-KDE will keep support for at least a year + * Ring-KDE will keep support for at least a year */ enum class LegacyHistoryState : int //DEPRECATED remove { diff --git a/src/callmodel.cpp b/src/callmodel.cpp index d34ce0b34b941d30c3b6f24d9a0c7cf627dd252e..ddc009bcdbbe19b97eb27148ce68200f91b46237 100644 --- a/src/callmodel.cpp +++ b/src/callmodel.cpp @@ -21,7 +21,7 @@ #include <QtCore/QDebug> #include <QtGui/QDragEnterEvent> -//SFLPhone library +//Ring library #include "call.h" #include "uri.h" #include "phonedirectorymodel.h" @@ -31,7 +31,7 @@ #include "dbus/callmanager.h" #include "dbus/configurationmanager.h" #include "dbus/instancemanager.h" -#include "sflphone_const.h" +#include "mime.h" #include "typedefs.h" #include "abstractitembackend.h" #include "dbus/videomanager.h" @@ -785,7 +785,7 @@ QStringList CallModel::mimeTypes() const { static QStringList mimes; if (!mimes.size()) { - mimes << MIME_PLAIN_TEXT << MIME_PHONENUMBER << MIME_CALLID << "text/html"; + mimes << RingMimes::PLAIN_TEXT << RingMimes::PHONENUMBER << RingMimes::CALLID << "text/html"; } return mimes; } @@ -796,12 +796,12 @@ QMimeData* CallModel::mimeData(const QModelIndexList& indexes) const foreach (const QModelIndex &idx, indexes) { if (idx.isValid()) { const QString text = data(idx, Call::Role::Number).toString(); - mData->setData(MIME_PLAIN_TEXT , text.toUtf8()); + mData->setData(RingMimes::PLAIN_TEXT , text.toUtf8()); Call* call = getCall(idx); if (call) - mData->setData(MIME_PHONENUMBER, call->peerPhoneNumber()->toHash().toUtf8()); + mData->setData(RingMimes::PHONENUMBER, call->peerPhoneNumber()->toHash().toUtf8()); qDebug() << "Setting mime" << idx.data(Call::Role::Id).toString(); - mData->setData(MIME_CALLID , idx.data(Call::Role::Id).toString().toUtf8()); + mData->setData(RingMimes::CALLID , idx.data(Call::Role::Id).toString().toUtf8()); return mData; } } @@ -824,8 +824,8 @@ bool CallModel::dropMimeData(const QMimeData* mimedata, Qt::DropAction action, i { Q_UNUSED(action) const QModelIndex targetIdx = index ( row,column,parentIdx ); - if (mimedata->hasFormat(MIME_CALLID)) { - const QByteArray encodedCallId = mimedata->data( MIME_CALLID ); + if (mimedata->hasFormat(RingMimes::CALLID)) { + const QByteArray encodedCallId = mimedata->data( RingMimes::CALLID ); Call* call = getCall ( encodedCallId ); Call* target = getCall ( targetIdx ); @@ -888,8 +888,8 @@ bool CallModel::dropMimeData(const QMimeData* mimedata, Qt::DropAction action, i break; } } - else if (mimedata->hasFormat(MIME_PHONENUMBER)) { - const QByteArray encodedPhoneNumber = mimedata->data( MIME_PHONENUMBER ); + else if (mimedata->hasFormat(RingMimes::PHONENUMBER)) { + const QByteArray encodedPhoneNumber = mimedata->data( RingMimes::PHONENUMBER ); Call* target = getCall(targetIdx); qDebug() << "Phone number" << encodedPhoneNumber << "on call" << target; Call* newCall = dialingCall(QString(),target->account()); @@ -898,8 +898,8 @@ bool CallModel::dropMimeData(const QMimeData* mimedata, Qt::DropAction action, i newCall->performAction(Call::Action::ACCEPT); createConferenceFromCall(newCall,target); } - else if (mimedata->hasFormat(MIME_CONTACT)) { - const QByteArray encodedContact = mimedata->data(MIME_CONTACT); + else if (mimedata->hasFormat(RingMimes::CONTACT)) { + const QByteArray encodedContact = mimedata->data(RingMimes::CONTACT); Call* target = getCall(targetIdx); qDebug() << "Contact" << encodedContact << "on call" << target; if (PhoneNumberSelector::defaultVisitor()) { diff --git a/src/callmodel.h b/src/callmodel.h index 9dba6533237250b508a90ff96ac2512b9991db97..5e806988aa2b449f8b93bd7576bb7756a0066760 100644 --- a/src/callmodel.h +++ b/src/callmodel.h @@ -23,7 +23,7 @@ #include <QMap> #include "typedefs.h" -//SFLPhone +//Ring #include "call.h" class Account; struct InternalStruct; @@ -34,7 +34,7 @@ class CallModelPrivate; typedef QMap<uint, Call*> CallMap; typedef QList<Call*> CallList; -///CallModel: Central model/frontend to deal with sflphoned +///CallModel: Central model/frontend to deal with dring class LIB_EXPORT CallModel : public QAbstractItemModel { #pragma GCC diagnostic push diff --git a/src/contact.cpp b/src/contact.cpp index 4ec69667e959508c5068a8c7b9da6108d4bcd039..2df69204cc0fa7aab4a2de653c4ea946bdc8c1ec 100644 --- a/src/contact.cpp +++ b/src/contact.cpp @@ -23,8 +23,7 @@ //Qt #include <QtGui/QPixmap> -//SFLPhone library -#include "sflphone_const.h" +//Ring library #include "phonenumber.h" #include "abstractitembackend.h" #include "transitionalcontactbackend.h" diff --git a/src/contact.h b/src/contact.h index b6fee3e8abef8aaee89db187b184c368b15149b1..3a3263c6e2d1aaac1637a0846d8dad71cb23495a 100644 --- a/src/contact.h +++ b/src/contact.h @@ -34,7 +34,7 @@ namespace KABC { class PhoneNumber ; } -//SFLPhone +//Ring class PhoneNumber; class AbstractContactBackend; class ContactPrivate; diff --git a/src/contactmodel.cpp b/src/contactmodel.cpp index acad22c10d3f2e20337679ec39e32514f995fd4c..d6383857f97eebe8e43a63ea865add892e4f8fd7 100644 --- a/src/contactmodel.cpp +++ b/src/contactmodel.cpp @@ -19,7 +19,7 @@ //Parent #include "contactmodel.h" -//SFLPhone library +//Ring library #include "contact.h" #include "call.h" #include "uri.h" diff --git a/src/contactmodel.h b/src/contactmodel.h index edd563258ad48759a99d58fa706669b9091a9035..dbd5d8d3ba00df20e3a0046eb77a298e7f8a0c5a 100644 --- a/src/contactmodel.h +++ b/src/contactmodel.h @@ -28,7 +28,7 @@ #include "contact.h" #include "commonbackendmanagerinterface.h" -//SFLPhone +//Ring class Contact; class Account; class AbstractContactBackend; diff --git a/src/contactproxymodel.cpp b/src/contactproxymodel.cpp index af08b078782cc2e51a6da585c533e9e01f8cf16d..55d0bc60e43ab8e7223c939382ce1bd5aebd6c84 100644 --- a/src/contactproxymodel.cpp +++ b/src/contactproxymodel.cpp @@ -23,7 +23,7 @@ #include <QtCore/QMimeData> #include <QtCore/QCoreApplication> -//SFLPhone +//Ring #include "callmodel.h" #include "historymodel.h" #include "phonenumber.h" @@ -31,6 +31,7 @@ #include "historytimecategorymodel.h" #include "contact.h" #include "uri.h" +#include "mime.h" #include "contactmodel.h" class ContactTreeNode; @@ -191,7 +192,7 @@ ContactProxyModel::ContactProxyModel(int role, bool showAll) : QAbstractItemMode d_ptr->m_Role = role; d_ptr->m_ShowAll = showAll; d_ptr->m_lCategoryCounter.reserve(32); - d_ptr->m_lMimes << MIME_PLAIN_TEXT << MIME_PHONENUMBER; + d_ptr->m_lMimes << RingMimes::PLAIN_TEXT << RingMimes::PHONENUMBER; connect(ContactModel::instance(),SIGNAL(reloaded()),d_ptr.data(),SLOT(reloadCategories())); connect(ContactModel::instance(),SIGNAL(newContactAdded(Contact*)),d_ptr.data(),SLOT(slotContactAdded(Contact*))); QHash<int, QByteArray> roles = roleNames(); @@ -357,8 +358,8 @@ bool ContactProxyModel::dropMimeData(const QMimeData *data, Qt::DropAction actio { Q_UNUSED( action ) setData(parent,-1,Call::Role::DropState); - if (data->hasFormat(MIME_CALLID)) { - const QByteArray encodedCallId = data->data( MIME_CALLID ); + if (data->hasFormat(RingMimes::CALLID)) { + const QByteArray encodedCallId = data->data( RingMimes::CALLID ); const QModelIndex targetIdx = index ( row,column,parent ); Call* call = CallModel::instance()->getCall ( encodedCallId ); if (call && targetIdx.isValid()) { @@ -507,9 +508,9 @@ QMimeData* ContactProxyModel::mimeData(const QModelIndexList &indexes) const const Contact* ct = static_cast<Contact*>(modelItem->getSelf()); if (ct) { if (ct->phoneNumbers().size() == 1) { - mimeData->setData(MIME_PHONENUMBER , ct->phoneNumbers()[0]->toHash().toUtf8()); + mimeData->setData(RingMimes::PHONENUMBER , ct->phoneNumbers()[0]->toHash().toUtf8()); } - mimeData->setData(MIME_CONTACT , ct->uid()); + mimeData->setData(RingMimes::CONTACT , ct->uid()); } return mimeData; } break; @@ -518,8 +519,8 @@ QMimeData* ContactProxyModel::mimeData(const QModelIndexList &indexes) const const QString text = data(index, Qt::DisplayRole).toString(); const Contact::PhoneNumbers nbs = *static_cast<Contact::PhoneNumbers*>(index.internalPointer()); const PhoneNumber* nb = nbs[index.row()]; - mimeData->setData(MIME_PLAIN_TEXT , text.toUtf8()); - mimeData->setData(MIME_PHONENUMBER, nb->toHash().toUtf8()); + mimeData->setData(RingMimes::PLAIN_TEXT , text.toUtf8()); + mimeData->setData(RingMimes::PHONENUMBER, nb->toHash().toUtf8()); return mimeData; } break; case CategorizedCompositeNode::Type::TOP_LEVEL: diff --git a/src/contactproxymodel.h b/src/contactproxymodel.h index 6b3589df9b11c62cf1ca884e1dcfaabfba8a0be3..2f4753413947df96faecf74baa394d63978c9e65 100644 --- a/src/contactproxymodel.h +++ b/src/contactproxymodel.h @@ -22,7 +22,7 @@ #include <QtCore/QStringList> #include <QtCore/QAbstractItemModel> -//SFLPhone +//Ring #include "../lib/typedefs.h" #include "../lib/contact.h" class ContactModel; diff --git a/src/dbus/callmanager-introspec.xml b/src/dbus/callmanager-introspec.xml index 1b8664640354dde871ff8267b8478fc61e6ede42..78df357e4bb612e1753c9321844e6c6fcc81fe7f 100644 --- a/src/dbus/callmanager-introspec.xml +++ b/src/dbus/callmanager-introspec.xml @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" ?> <node name="/callmanager-introspec" xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0"> - <interface name="org.sflphone.SFLphone.CallManager"> + <interface name="cx.ring.Ring.CallManager"> <tp:docstring xmlns="http://www.w3.org/1999/xhtml"> <p>The CallManager interface is used to manage call and conference related actions.</p> diff --git a/src/dbus/callmanager.cpp b/src/dbus/callmanager.cpp index 1eb1d2d75c3cc47e6a171971368f845493d2124b..26c9eff3da8c5066bacb45a654013522b86ac9cd 100644 --- a/src/dbus/callmanager.cpp +++ b/src/dbus/callmanager.cpp @@ -24,10 +24,10 @@ CallManagerInterface * DBus::CallManager::interface = nullptr; CallManagerInterface & DBus::CallManager::instance(){ if (!dbus_metaTypeInit) registerCommTypes(); if (!interface) - interface = new CallManagerInterface( "org.sflphone.SFLphone", "/org/sflphone/SFLphone/CallManager", QDBusConnection::sessionBus()); + interface = new CallManagerInterface( "cx.ring.Ring", "/cx/ring/Ring/CallManager", QDBusConnection::sessionBus()); if(!interface->connection().isConnected()) - throw "Error : sflphoned not connected. Service " + interface->service() + " not connected. From call manager interface."; + throw "Error : dring not connected. Service " + interface->service() + " not connected. From call manager interface."; if (!interface->isValid()) - throw "SFLphone daemon not available, be sure it running"; + throw "Dring daemon not available, be sure it running"; return *interface; } diff --git a/src/dbus/configurationmanager-introspec.xml b/src/dbus/configurationmanager-introspec.xml index 8cc1c5dcd6b79c751f2441dc260a3473165dbec4..a947da854818be6025fc3681db009cdefb3eac73 100644 --- a/src/dbus/configurationmanager-introspec.xml +++ b/src/dbus/configurationmanager-introspec.xml @@ -1,6 +1,6 @@ <?xml version="1.0" ?> <node name="/configurationmanager-introspec" xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0"> - <interface name="org.sflphone.SFLphone.ConfigurationManager"> + <interface name="cx.ring.Ring.ConfigurationManager"> <tp:docstring xmlns="http://www.w3.org/1999/xhtml"> Used to handle the configuration stuff: accounts settings, account registration, user preferences, ... @@ -74,7 +74,7 @@ <method name="setAccountDetails" tp:name-for-bindings="setAccountDetails"> <tp:docstring> Send new account parameters, or account parameters changes, to the core. The hash table is not required to be complete, only the updated parameters may be specified. - <tp:rationale>Account settings are written to the configuration file when sflphone properly quits.</tp:rationale> + <tp:rationale>Account settings are written to the configuration file when Ring properly quits.</tp:rationale> <tp:rationale>After calling this method, the core will emit the signal <tp:member-ref>accountsChanged</tp:member-ref> with the updated data. The client must subscribe to this signal and use it to update its internal data structure.</tp:rationale> </tp:docstring> <annotation name="org.qtproject.QtDBus.QtTypeName.In1" value="MapStringString"/> diff --git a/src/dbus/configurationmanager.cpp b/src/dbus/configurationmanager.cpp index 2a85454ebf60e25891130d78389849afc7efebc6..80a06f6aad90f064b0d2cf1569c0a5943f3476c6 100644 --- a/src/dbus/configurationmanager.cpp +++ b/src/dbus/configurationmanager.cpp @@ -24,12 +24,12 @@ ConfigurationManagerInterface& DBus::ConfigurationManager::instance() { if (!dbus_metaTypeInit) registerCommTypes(); if (!interface) - interface = new ConfigurationManagerInterface("org.sflphone.SFLphone", "/org/sflphone/SFLphone/ConfigurationManager", QDBusConnection::sessionBus()); + interface = new ConfigurationManagerInterface("cx.ring.Ring", "/cx/ring/Ring/ConfigurationManager", QDBusConnection::sessionBus()); if(!interface->connection().isConnected()) { - qDebug() << "Error : sflphoned not connected. Service " << interface->service() << " not connected. From configuration manager interface."; - throw "Error : sflphoned not connected. Service " + interface->service() + " not connected. From configuration manager interface."; + qDebug() << "Error : dring not connected. Service " << interface->service() << " not connected. From configuration manager interface."; + throw "Error : dring not connected. Service " + interface->service() + " not connected. From configuration manager interface."; } if (!interface->isValid()) - throw "SFLphone daemon not available, be sure it running"; + throw "DRing daemon not available, be sure it running"; return *interface; } diff --git a/src/dbus/instance-introspec.xml b/src/dbus/instance-introspec.xml index f3d1373a6409b7875a4d80db5bf0f815f285d637..d8a620bc218c9122ed38a22450286a31273df92b 100644 --- a/src/dbus/instance-introspec.xml +++ b/src/dbus/instance-introspec.xml @@ -1,6 +1,6 @@ <?xml version="1.0" ?> <node name="/instance-introspec" xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0"> - <interface name="org.sflphone.SFLphone.Instance"> + <interface name="cx.ring.Ring.Instance"> <tp:docstring xmlns="http://www.w3.org/1999/xhtml"> <p>Count the number of clients actually registered to the core. When initializing your client, you need to register it against the core by using this interface.</p> </tp:docstring> diff --git a/src/dbus/instancemanager.cpp b/src/dbus/instancemanager.cpp index 1b3002ce6a9e5b3d0716e64debbed62460b0072a..ac0eb5411a81a7a240feeff716f800cf5d487402 100644 --- a/src/dbus/instancemanager.cpp +++ b/src/dbus/instancemanager.cpp @@ -25,9 +25,9 @@ InstanceInterface& DBus::InstanceManager::instance() { if (!dbus_metaTypeInit) registerCommTypes(); if (!interface) - interface = new InstanceInterface("org.sflphone.SFLphone", "/org/sflphone/SFLphone/Instance", QDBusConnection::sessionBus()); + interface = new InstanceInterface("cx.ring.Ring", "/cx/ring/Ring/Instance", QDBusConnection::sessionBus()); if(!interface->connection().isConnected()) { - throw "Error : sflphoned not connected. Service " + interface->service() + " not connected. From instance interface."; + throw "Error : dring not connected. Service " + interface->service() + " not connected. From instance interface."; } return *interface; } diff --git a/src/dbus/presencemanager-introspec.xml b/src/dbus/presencemanager-introspec.xml index 77b1527a43bd910c947cc7ff7dd99a2265e6f20c..7aad39b0eee257dd9faaed1de01886726a7a8347 100644 --- a/src/dbus/presencemanager-introspec.xml +++ b/src/dbus/presencemanager-introspec.xml @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" ?> <node name="/presencemanager-introspec" xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0"> - <interface name="org.sflphone.SFLphone.PresenceManager"> + <interface name="cx.ring.Ring.PresenceManager"> <!-- METHODS !--> <method name="publish" tp:name-for-bindings="publish"> <tp:added version="1.3.0"/> diff --git a/src/dbus/presencemanager.cpp b/src/dbus/presencemanager.cpp index 4d9656e686b5e9bc146bf8659123d5edf8374cb0..0b40f9a2ec3a890231d82090f7fbfc123cd15c9e 100644 --- a/src/dbus/presencemanager.cpp +++ b/src/dbus/presencemanager.cpp @@ -23,10 +23,10 @@ PresenceManagerInterface& DBus::PresenceManager::instance() { if (!dbus_metaTypeInit) registerCommTypes(); if (!interface) - interface = new PresenceManagerInterface("org.sflphone.SFLphone", "/org/sflphone/SFLphone/PresenceManager", QDBusConnection::sessionBus()); + interface = new PresenceManagerInterface("cx.ring.Ring", "/cx/ring/Ring/PresenceManager", QDBusConnection::sessionBus()); if(!interface->connection().isConnected()) { - throw "Error : sflphoned not connected. Service " + interface->service() + " not connected. From instance interface."; + throw "Error : dring not connected. Service " + interface->service() + " not connected. From instance interface."; } return *interface; } diff --git a/src/dbus/videomanager-introspec.xml b/src/dbus/videomanager-introspec.xml index b7773f8379cff93f0e687fb2fede89979c021aed..de9761b9fb7bcb5f8654076db775bc8a5400218a 100644 --- a/src/dbus/videomanager-introspec.xml +++ b/src/dbus/videomanager-introspec.xml @@ -1,6 +1,6 @@ <?xml version="1.0" ?> <node name="/videomanager-introspec" xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0"> - <interface name="org.sflphone.SFLphone.VideoManager"> + <interface name="cx.ring.Ring.VideoManager"> <!-- Video device methods --> <method name="getDeviceList" tp:name-for-bindings="getDeviceList"> diff --git a/src/dbus/videomanager.cpp b/src/dbus/videomanager.cpp index d271efd20e553f6a2226bd77f295bf97fa83979c..4aa7512132353a1b5149da50fc514ebb69271d9e 100644 --- a/src/dbus/videomanager.cpp +++ b/src/dbus/videomanager.cpp @@ -23,10 +23,10 @@ VideoManagerInterface& DBus::VideoManager::instance() { if (!dbus_metaTypeInit) registerCommTypes(); if (!interface) - interface = new VideoManagerInterface("org.sflphone.SFLphone", "/org/sflphone/SFLphone/VideoManager", QDBusConnection::sessionBus()); + interface = new VideoManagerInterface("cx.ring.Ring", "/cx/ring/Ring/VideoManager", QDBusConnection::sessionBus()); if(!interface->connection().isConnected()) { - throw "Error : sflphoned not connected. Service " + interface->service() + " not connected. From instance interface."; + throw "Error : dring not connected. Service " + interface->service() + " not connected. From instance interface."; } return *interface; } diff --git a/src/historymodel.cpp b/src/historymodel.cpp index 96745cc302309d91ad2388df1b4587d1d12c72b1..f762ffcb8c2aa623fc177e60808be54ea58c7977 100644 --- a/src/historymodel.cpp +++ b/src/historymodel.cpp @@ -20,7 +20,8 @@ //C include #include <time.h> -//SFLPhone lib +//Ring lib +#include "mime.h" #include "dbus/callmanager.h" #include "dbus/configurationmanager.h" #include "call.h" @@ -182,7 +183,7 @@ m_Role(Call::Role::FuzzyDate) HistoryModel::HistoryModel():QAbstractItemModel(QCoreApplication::instance()),d_ptr(new HistoryModelPrivate(this)) { m_spInstance = this; - d_ptr->m_lMimes << MIME_PLAIN_TEXT << MIME_PHONENUMBER << MIME_HISTORYID; + d_ptr->m_lMimes << RingMimes::PLAIN_TEXT << RingMimes::PHONENUMBER << RingMimes::HISTORYID; QHash<int, QByteArray> roles = roleNames(); roles.insert(Call::Role::Name ,QByteArray("name" )); roles.insert(Call::Role::Number ,QByteArray("number" )); @@ -541,12 +542,12 @@ QMimeData* HistoryModel::mimeData(const QModelIndexList &indexes) const foreach (const QModelIndex &idx, indexes) { if (idx.isValid()) { const QString text = data(idx, Call::Role::Number).toString(); - mimeData2->setData(MIME_PLAIN_TEXT , text.toUtf8()); + mimeData2->setData(RingMimes::PLAIN_TEXT , text.toUtf8()); const Call* call = (Call*)((CategorizedCompositeNode*)(idx.internalPointer()))->getSelf(); - mimeData2->setData(MIME_PHONENUMBER, call->peerPhoneNumber()->toHash().toUtf8()); + mimeData2->setData(RingMimes::PHONENUMBER, call->peerPhoneNumber()->toHash().toUtf8()); CategorizedCompositeNode* node = static_cast<CategorizedCompositeNode*>(idx.internalPointer()); if (node->type() == CategorizedCompositeNode::Type::CALL) - mimeData2->setData(MIME_HISTORYID , static_cast<Call*>(node->getSelf())->id().toUtf8()); + mimeData2->setData(RingMimes::HISTORYID , static_cast<Call*>(node->getSelf())->id().toUtf8()); return mimeData2; } } @@ -560,11 +561,11 @@ bool HistoryModel::dropMimeData(const QMimeData *mime, Qt::DropAction action, in Q_UNUSED(column) Q_UNUSED(action) setData(parentIdx,-1,Call::Role::DropState); - QByteArray encodedPhoneNumber = mime->data( MIME_PHONENUMBER ); - QByteArray encodedContact = mime->data( MIME_CONTACT ); + QByteArray encodedPhoneNumber = mime->data( RingMimes::PHONENUMBER ); + QByteArray encodedContact = mime->data( RingMimes::CONTACT ); - if (parentIdx.isValid() && mime->hasFormat( MIME_CALLID)) { - QByteArray encodedCallId = mime->data( MIME_CALLID ); + if (parentIdx.isValid() && mime->hasFormat( RingMimes::CALLID)) { + QByteArray encodedCallId = mime->data( RingMimes::CALLID ); Call* call = CallModel::instance()->getCall(encodedCallId); if (call) { const QModelIndex& idx = index(row,column,parentIdx); diff --git a/src/historymodel.h b/src/historymodel.h index 53eb0a12f0d2f4bc8eeb5342511bd1cb7eef841b..d699f60022f3c4033a7deb8cdf26e346f47a9d0f 100644 --- a/src/historymodel.h +++ b/src/historymodel.h @@ -25,7 +25,7 @@ //Qt -//SFLPhone +//Ring #include "call.h" #include "commonbackendmanagerinterface.h" diff --git a/src/imconversationmanager.h b/src/imconversationmanager.h index 8a9caeee8fa1897c7df6bb840034d29cbb001a47..bf5e31e58ff599a0a3b2bc76dfa33ca284fc607f 100644 --- a/src/imconversationmanager.h +++ b/src/imconversationmanager.h @@ -21,7 +21,7 @@ #include "typedefs.h" -//SFLPhone +//Ring class Call; class InstantMessagingModel; class IMConversationManagerPrivate; diff --git a/src/itembackendmodel.h b/src/itembackendmodel.h index 3908029360cb8a701b4c93fab5adbcb8cf16afc1..1b00a08ec268158c70204e593e08bb6c48de8da2 100644 --- a/src/itembackendmodel.h +++ b/src/itembackendmodel.h @@ -27,7 +27,7 @@ #include "contactmodel.h" #include "abstractitembackend.h" -//SFLPhone +//Ring class AbstractItemBackendModelExtension; class CommonItemBackendModelPrivate; diff --git a/src/legacyhistorybackend.cpp b/src/legacyhistorybackend.cpp index 9ea0945d3affed64dabc4a5037b810bbce0f50df..c0e98272f64c25e916e3ce8e5a4292e8720cfede 100644 --- a/src/legacyhistorybackend.cpp +++ b/src/legacyhistorybackend.cpp @@ -18,7 +18,7 @@ ***********************************************************************************/ #include "legacyhistorybackend.h" -//SFLPhone +//Ring #include "dbus/configurationmanager.h" #include "call.h" #include "private/call_p.h" diff --git a/src/mime.h b/src/mime.h new file mode 100644 index 0000000000000000000000000000000000000000..2fc335d8c854dd96f3d7c98d1115830db2019d13 --- /dev/null +++ b/src/mime.h @@ -0,0 +1,30 @@ +/**************************************************************************** + * Copyright (C) 2012-2015 by Savoir-Faire Linux * + * Author : Emmanuel Lepage Vallee <emmanuel.lepage@savoirfairelinux.com> * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of the GNU Lesser General Public * + * License as published by the Free Software Foundation; either * + * version 2.1 of the License, or (at your option) any later version. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * + * Lesser General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this program. If not, see <http://www.gnu.org/licenses/>. * + ***************************************************************************/ +#ifndef MIME_H +#define MIME_H + +namespace RingMimes { + constexpr static const char* CALLID = "text/ring.call.id" ; + constexpr static const char* CONTACT = "text/ring.contact" ; + constexpr static const char* HISTORYID = "text/ring.history.id" ; + constexpr static const char* PHONENUMBER = "text/ring.phone.number" ; + constexpr static const char* PLAIN_TEXT = "text/plain" ; +} + +#endif + diff --git a/src/numbercompletionmodel.cpp b/src/numbercompletionmodel.cpp index 3ff0527631bd1acb77e4fc236e871cda80e8e916..ef16967f23474e955d7a300bb73e43d53197de24 100644 --- a/src/numbercompletionmodel.cpp +++ b/src/numbercompletionmodel.cpp @@ -23,7 +23,7 @@ //System #include <cmath> -//SFLPhone +//Ring #include "phonedirectorymodel.h" #include "phonenumber.h" #include "call.h" diff --git a/src/numbercompletionmodel.h b/src/numbercompletionmodel.h index 8698c7092f6459713710d981fd72fe781096a691..e5af8aea82f7928674c539fcbe73f7c87ffecf10 100644 --- a/src/numbercompletionmodel.h +++ b/src/numbercompletionmodel.h @@ -22,7 +22,7 @@ #include "typedefs.h" #include "phonedirectorymodel.h" -//SFLPhone +//Ring class PhoneNumber; class Call; diff --git a/src/phonedirectorymodel.cpp b/src/phonedirectorymodel.cpp index 88cf111ea1446cd08017459b980fa5d96a9bc582..2e433c029e1ca2378f2857f897f0a6d50776ea85 100644 --- a/src/phonedirectorymodel.cpp +++ b/src/phonedirectorymodel.cpp @@ -20,7 +20,7 @@ //Qt #include <QtCore/QCoreApplication> -//SFLPhone +//Ring #include "phonenumber.h" #include "call.h" #include "uri.h" diff --git a/src/phonedirectorymodel.h b/src/phonedirectorymodel.h index 708b9295e35a52b710348425e5184a85bcf9ce41..ada0013b276d9aa725232b293c52307a769b92e5 100644 --- a/src/phonedirectorymodel.h +++ b/src/phonedirectorymodel.h @@ -23,7 +23,7 @@ #include <QtCore/QString> #include <QtCore/QAbstractTableModel> -//SFLPhone +//Ring #include "uri.h" class PhoneNumber ; class Contact ; diff --git a/src/phonenumber.h b/src/phonenumber.h index 906fc0a43b3f4d768cd3974f27a1e020270305f0..3010a377acf8320c2e7ddd0d6df2680f9d3be362 100644 --- a/src/phonenumber.h +++ b/src/phonenumber.h @@ -26,7 +26,7 @@ #include <QtCore/QSize> #include <QtCore/QObject> -//SFLPhone +//Ring #include "uri.h" class Account; class Contact; diff --git a/src/presencestatusmodel.cpp b/src/presencestatusmodel.cpp index fe4f067474f99cc1075d5ad002fbf660f5fda9b4..f032fdbf7e7710c9213d4bc7488080c0a3a29f4c 100644 --- a/src/presencestatusmodel.cpp +++ b/src/presencestatusmodel.cpp @@ -20,7 +20,7 @@ //Qt #include <QtCore/QCoreApplication> -//SFLPhone +//Ring #include "accountmodel.h" #include "dbus/presencemanager.h" #include "visitors/presenceserializationvisitor.h" @@ -327,7 +327,7 @@ void PresenceStatusModel::setCurrentIndex (const QModelIndex& index) emit currentStatusChanged(d_ptr->m_pCurrentStatus->status); for (int i=0; i < AccountModel::instance()->size(); i++) { DBus::PresenceManager::instance().publish( - (*AccountModel::instance())[1]->id(), d_ptr->m_pCurrentStatus->status,d_ptr->m_pCurrentStatus->message + (*AccountModel::instance())[i]->id(), d_ptr->m_pCurrentStatus->status,d_ptr->m_pCurrentStatus->message ); } } diff --git a/src/private/call_p.h b/src/private/call_p.h index e6f339804cc4d90974ec832750253cb70a546af9..e19b47fea1cc05fe8cb81a0682921698d21cd3d6 100644 --- a/src/private/call_p.h +++ b/src/private/call_p.h @@ -26,7 +26,7 @@ class QTimer; -//SFLPhone +//Ring class Account; class PhoneNumber; class UserActionModel; diff --git a/src/private/phonedirectorymodel_p.h b/src/private/phonedirectorymodel_p.h index 9c1fe9a04efc43f4385add86ec73b188b577c527..0435c9306528f22e58fc8393cd5c2ca21d8b1f72 100644 --- a/src/private/phonedirectorymodel_p.h +++ b/src/private/phonedirectorymodel_p.h @@ -19,7 +19,7 @@ #define PHONEDIRECTORYMODEL_PRIVATE_H #include <QtCore/QObject> -//SFLphone +//Ring class PhoneDirectoryModel; #include "phonenumber.h" diff --git a/src/ringtonemodel.cpp b/src/ringtonemodel.cpp index 0ef020e0264461d6d799ae22b564d97d5d327403..20e06181daab5e2078e5b437677e8acf01fe08fc 100644 --- a/src/ringtonemodel.cpp +++ b/src/ringtonemodel.cpp @@ -20,7 +20,7 @@ //Qt #include <QtCore/QTimer> -//SFLphone +//Ring #include "dbus/configurationmanager.h" #include "dbus/callmanager.h" #include "account.h" diff --git a/src/ringtonemodel.h b/src/ringtonemodel.h index 04dd6c41a1e4d9bb9b6af7ee22e09c34e1bbe505..fa967726849e3abed35071d14ab5580262c7c22a 100644 --- a/src/ringtonemodel.h +++ b/src/ringtonemodel.h @@ -24,7 +24,7 @@ #include <QtCore/QAbstractTableModel> class QTimer; -//SFLPhone +//Ring class Account; ///CredentialModel: A model for account credentials diff --git a/src/securityvalidationmodel.h b/src/securityvalidationmodel.h index 101c5dad7bf6e1311a46468e38e11eacdc18c7ed..27052393d27920c74b654362e03ac80319e5da99 100644 --- a/src/securityvalidationmodel.h +++ b/src/securityvalidationmodel.h @@ -19,12 +19,12 @@ #define SECURITYVALIDATIONMODEL_H #include <QAbstractListModel> -//SFLPhone +//Ring #include "certificate.h" #include "typedefs.h" -//SFLPhone +//Ring class Account; class Flaw; @@ -41,7 +41,7 @@ public: * 2) Decide if an account can be considered secure * 3) Decide if a call can be considered secure * - * End users should not have to be security gurus to setup SFLphone. It is our + * End users should not have to be security gurus to setup Ring. It is our * job to do as much as we can to make security configuration as transparent as * possible. * diff --git a/src/sflphone_const.h b/src/sflphone_const.h index e11c29e7c5c728e1f578298aeba079ff92faaea5..95f09919e0014f9c45d4eaac67677b36a823c03d 100644 --- a/src/sflphone_const.h +++ b/src/sflphone_const.h @@ -19,45 +19,9 @@ /* THIS FILE IS DEPRECATED DO NOT ADD NEW GLOBAL CONSTANTS */ -#ifndef SFLPHONE_CONST_H -#define SFLPHONE_CONST_H -#define ICON_INCOMING ":/images/icons/ring.svg" -#define ICON_RINGING ":/images/icons/ring.svg" -#define ICON_CURRENT ":/images/icons/current.svg" -#define ICON_DIALING ":/images/icons/dial.svg" -#define ICON_HOLD ":/images/icons/hold.svg" -#define ICON_FAILURE ":/images/icons/fail.svg" -#define ICON_BUSY ":/images/icons/busy.svg" -#define ICON_TRANSFER ":/images/icons/transfert.svg" -#define ICON_TRANSF_HOLD ":/images/icons/transfert.svg" -#define ICON_CONFERENCE ":/images/icons/user-group-properties.svg" -#define ICON_CALL ":/images/icons/call.svg" -#define ICON_HANGUP ":/images/icons/hang_up.svg" -#define ICON_UNHOLD ":/images/icons/unhold.svg" -#define ICON_ACCEPT ":/images/icons/accept.svg" -#define ICON_REFUSE ":/images/icons/refuse.svg" -#define ICON_EXEC_TRANSF ":/images/icons/call.svg" -#define ICON_REC_DEL_OFF ":/images/icons/record_disabled.svg" -#define ICON_REC_DEL_ON ":/images/icons/record.svg" -#define ICON_MAILBOX ":/images/icons/mailbox.svg" -#define ICON_DISPLAY_VOLUME_CONSTROLS ":/images/icons/icon_volume_off.svg" -#define ICON_DISPLAY_DIALPAD ":/images/icons/icon_dialpad.svg" -#define ICON_HISTORY_INCOMING ":/images/icons/incoming.svg" -#define ICON_HISTORY_OUTGOING ":/images/icons/outgoing.svg" -#define ICON_HISTORY_MISSED ":/images/icons/missed.svg" -#define ICON_HISTORY_MISSED_OUT ":/images/icons/missed_out.svg" -#define ICON_SFLPHONE ":/images/icons/sflphone.svg" -// #define ACCOUNT_TYPES_TAB {QString(Account::ProtocolName::SIP), QString(Account::ProtocolName::IAX)} -/*********************/ -/** MIME API */ -#define MIME_CALLID "text/sflphone.call.id" -#define MIME_CONTACT "text/sflphone.contact" -#define MIME_HISTORYID "text/sflphone.history.id" -#define MIME_PHONENUMBER "text/sflphone.phone.number" -#define MIME_PLAIN_TEXT "text/plain" #endif diff --git a/src/uri.h b/src/uri.h index 8322b3aaedf4d922b3a93d8a369fe71c42ae8e59..608c9db99138e559e1e3bf5fa4639f4019694952 100644 --- a/src/uri.h +++ b/src/uri.h @@ -27,7 +27,7 @@ class URIPrivate; /** * @class URI A specialized string with multiple attributes * - * Most of SFLPhone-KDE handle uri as strings, but more + * Most of Ring-KDE handle uri as strings, but more * advanced algorithms need to access the various sections. * * Here is some example of common numbers/URIs: diff --git a/src/video/channel.cpp b/src/video/channel.cpp index 59de066ee300e80fbe2491f624448ea861b31ff8..cb33572777a9ab488f5fe696d1ecda933e538595 100644 --- a/src/video/channel.cpp +++ b/src/video/channel.cpp @@ -17,7 +17,7 @@ ***************************************************************************/ #include "channel.h" -//SFLphone +//Ring #include "resolution.h" #include "device.h" #include "../dbus/videomanager.h" diff --git a/src/video/codecmodel2.h b/src/video/codecmodel2.h index 75ee96303ba686468cd766d17137087eeebebea4..4b669148fcaf75998390ae0606b72bc7b679b185 100644 --- a/src/video/codecmodel2.h +++ b/src/video/codecmodel2.h @@ -23,7 +23,7 @@ //Qt -//SFLPhone +//Ring class Account; //Typedef diff --git a/src/video/device.h b/src/video/device.h index 2f1cf6d102c2cb59a217ad5a61ab1eef3b349653..e2cf6e9511f26fe7c329be287873cc058089d90d 100644 --- a/src/video/device.h +++ b/src/video/device.h @@ -25,7 +25,7 @@ #include <QStringList> #include <QtCore/QSize> -//SFLPhone +//Ring namespace Video { class Renderer; class Resolution; diff --git a/src/video/manager.cpp b/src/video/manager.cpp index 01ef8008ab31787a92a73faf5832b2cd33f5fad1..336eba38d1fe96fdaa297f63162e0cbaf5718952 100644 --- a/src/video/manager.cpp +++ b/src/video/manager.cpp @@ -20,7 +20,7 @@ //Qt #include <QtCore/QMutex> -//SFLPhone +//Ring #include "../dbus/videomanager.h" #include "device.h" #include <call.h> diff --git a/src/video/manager.h b/src/video/manager.h index 818afd253d7182ae06ce972219189e382b4992e1..2434a16e9ce7cae63f462b54ee5a1676a94198b8 100644 --- a/src/video/manager.h +++ b/src/video/manager.h @@ -24,7 +24,7 @@ //Qt #include <QtCore/QHash> -//SFLPhone +//Ring #include "device.h" namespace Video { class Renderer; diff --git a/src/video/renderer.h b/src/video/renderer.h index 3f07e9106238fcf1c9d6b6a6e295748ae07206b9..ed1902f1d069f22ca5d42e8a388e45990f537a5b 100644 --- a/src/video/renderer.h +++ b/src/video/renderer.h @@ -28,7 +28,7 @@ class QTimer; class QMutex; -//SFLPhone +//Ring #include "device.h" //Private diff --git a/src/video/sourcesmodel.h b/src/video/sourcesmodel.h index afe1e80b408442e284bb5d029135ae4e3f997e61..b8db7319ae92da18c2bffd64e8e8c98738dd8317 100644 --- a/src/video/sourcesmodel.h +++ b/src/video/sourcesmodel.h @@ -21,7 +21,7 @@ #include <QtCore/QRect> #include "../typedefs.h" -//SFLPhone +//Ring namespace Video { diff --git a/src/visitors/accountlistcolorvisitor.h b/src/visitors/accountlistcolorvisitor.h index 21351c236957020d99a3f6df8973d756b4920a06..77b0991b62c892c118dd5b913a3fe311aaf17693 100644 --- a/src/visitors/accountlistcolorvisitor.h +++ b/src/visitors/accountlistcolorvisitor.h @@ -22,7 +22,7 @@ #include "../typedefs.h" class Account; -///SFLPhonelib Qt does not link to QtGui, and does not need to, this allow to add runtime Gui support +///Ringlib Qt does not link to QtGui, and does not need to, this allow to add runtime Gui support class LIB_EXPORT AccountListColorVisitor { public: virtual QVariant getColor(const Account* a) = 0; diff --git a/src/visitors/itemmodelstateserializationvisitor.h b/src/visitors/itemmodelstateserializationvisitor.h index a462b81f4a34586100739aabd6568c13087f5454..b7a618ef8707b01b95692501fc29b3b141390c2b 100644 --- a/src/visitors/itemmodelstateserializationvisitor.h +++ b/src/visitors/itemmodelstateserializationvisitor.h @@ -23,7 +23,7 @@ class AbstractItemBackendBase; class Account; -///SFLPhonelib Qt does not link to QtGui, and does not need to, this allow to add runtime Gui support +///Ringlib Qt does not link to QtGui, and does not need to, this allow to add runtime Gui support class LIB_EXPORT ItemModelStateSerializationVisitor { public: virtual bool save() = 0; diff --git a/src/visitors/pixmapmanipulationvisitor.h b/src/visitors/pixmapmanipulationvisitor.h index b6341b7aee9c148e5d4007cc2f4d83e11dd0df22..1465bfa57fed45a42cff5512c4df809818166771 100644 --- a/src/visitors/pixmapmanipulationvisitor.h +++ b/src/visitors/pixmapmanipulationvisitor.h @@ -23,7 +23,7 @@ #include <QtCore/QVariant> #include <QtCore/QModelIndex> -//SFLPhone +//Ring class Contact ; class PhoneNumber; class Call ;