diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/connectionlistmodel.cpp | 5 | ||||
-rw-r--r-- | core/connectionlistmodel.h | 1 |
2 files changed, 6 insertions, 0 deletions
diff --git a/core/connectionlistmodel.cpp b/core/connectionlistmodel.cpp index 04d1d5909..aaa829949 100644 --- a/core/connectionlistmodel.cpp +++ b/core/connectionlistmodel.cpp @@ -50,3 +50,8 @@ void ConnectionListModel::removeAllAddresses() m_addresses.clear(); endRemoveRows(); } + +int ConnectionListModel::indexOf(QString address) +{ + return m_addresses.indexOf(address); +} diff --git a/core/connectionlistmodel.h b/core/connectionlistmodel.h index b7b1db5c9..11a93bfbc 100644 --- a/core/connectionlistmodel.h +++ b/core/connectionlistmodel.h @@ -16,6 +16,7 @@ public: int rowCount(const QModelIndex &parent = QModelIndex()) const; void addAddress(const QString address); void removeAllAddresses(); + int indexOf(QString address); private: QStringList m_addresses; }; |