aboutsummaryrefslogtreecommitdiff
path: root/contact.cpp
diff options
context:
space:
mode:
authorXavier Del Campo Romero <xavi.dcr@tutanota.com>2023-06-12 23:47:17 +0200
committerXavier Del Campo Romero <xavi.dcr@tutanota.com>2023-06-29 14:09:46 +0200
commit05b2584fa4d773f5a88ed3ce98f5dd8304e11c34 (patch)
treef72e73c3259b8100e886f49f67ecc669b7667502 /contact.cpp
parent3b8fafc4122848219898245d52dabd669cacb4ba (diff)
First commit
Diffstat (limited to 'contact.cpp')
-rw-r--r--contact.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/contact.cpp b/contact.cpp
new file mode 100644
index 0000000..bb21314
--- /dev/null
+++ b/contact.cpp
@@ -0,0 +1,16 @@
+#include "contact.h"
+
+Contact::Contact(const QString &own, const QString &other,
+ QListWidget *const list, QWidget *const parent) :
+ QListWidgetItem(list),
+ QWidget(parent),
+ own(own),
+ other(other)
+{
+ ui.setupUi(this);
+ ui.own_jid->setText(own);
+ ui.contact_jid->setText(other);
+ QListWidgetItem::setSizeHint(QWidget::sizeHint());
+ list->addItem(this);
+ list->setItemWidget(this, this);
+}