some more refactoring

This commit is contained in:
fourtf
2020-02-23 17:45:59 +01:00
parent e1838154ff
commit 4a5dc80bc6
12 changed files with 62 additions and 75 deletions
+3 -4
View File
@@ -160,13 +160,12 @@ SelectChannelDialog::SelectChannelDialog(QWidget *parent)
view->getTableView(), &QTableView::doubleClicked,
[](const QModelIndex &index) {
auto editor = new IrcConnectionEditor(
Irc::instance()
.connections.getVector()[size_t(index.row())]);
Irc::instance().connections.raw()[size_t(index.row())]);
if (editor->exec() == QDialog::Accepted)
{
auto data = editor->data();
auto &&conns = Irc::instance().connections.getVector();
auto &&conns = Irc::instance().connections.raw();
int i = 0;
for (auto &&conn : conns)
{
@@ -348,7 +347,7 @@ IndirectChannel SelectChannelDialog::getSelectedChannel() const
->currentIndex()
.row();
auto &&vector = Irc::instance().connections.getVector();
auto &&vector = Irc::instance().connections.raw();
if (row >= 0 && row < int(vector.size()))
{