qTox  Version: nightly | Commit: bc751c8e1cac455f9690654fcfe0f560d2d7dfdd
toxuri.h
Go to the documentation of this file.
1 /*
2  Copyright © 2014-2019 by The qTox Project Contributors
3 
4  This file is part of qTox, a Qt-based graphical interface for Tox.
5 
6  qTox is libre software: you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation, either version 3 of the License, or
9  (at your option) any later version.
10 
11  qTox is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  GNU General Public License for more details.
15 
16  You should have received a copy of the GNU General Public License
17  along with qTox. If not, see <http://www.gnu.org/licenses/>.
18 */
19 
20 
21 #pragma once
22 
23 #include <QDialog>
24 
25 class Core;
26 // Internals
27 class QByteArray;
28 class QLabel;
29 class QLineEdit;
30 class QPlainTextEdit;
31 class ToxURIDialog : public QDialog
32 {
33  Q_OBJECT
34 public:
35  explicit ToxURIDialog(QWidget* parent, Core& _core);
36  QString getRequestMessage();
37  bool handleToxURI(const QString& toxURI);
38 
39 private:
40  void setUserId(const QString& userId);
41 
42 private:
43  QPlainTextEdit* messageEdit;
44  QLabel* friendsLabel;
45  QLineEdit* userIdEdit;
47 };
ToxURIDialog
Definition: toxuri.h:31
ToxURIDialog::ToxURIDialog
ToxURIDialog(QWidget *parent, Core &_core)
Definition: toxuri.cpp:75
ToxURIDialog::getRequestMessage
QString getRequestMessage()
Definition: toxuri.cpp:118
ToxURIDialog::core
Core & core
Definition: toxuri.h:46
ToxURIDialog::messageEdit
QPlainTextEdit * messageEdit
Definition: toxuri.h:43
ToxURIDialog::handleToxURI
bool handleToxURI(const QString &toxURI)
Shows a dialog asking whether or not to add this tox address as a friend.
Definition: toxuri.cpp:41
ToxURIDialog::setUserId
void setUserId(const QString &userId)
Definition: toxuri.cpp:69
ToxURIDialog::userIdEdit
QLineEdit * userIdEdit
Definition: toxuri.h:45
ToxURIDialog::friendsLabel
QLabel * friendsLabel
Definition: toxuri.h:44
Core
Definition: core.h:59