unauthorizedAccept option
[dyskinesia.git] / src / joinwin.cpp
blobf79c1676dae2f4c371e15712302b4a71f9e174ff
1 /* coded by Ketmar // Vampire Avalon (psyc://ketmar.no-ip.org/~Ketmar)
2 * Understanding is not required. Only obedience.
4 * This program is free software. It comes without any warranty, to
5 * the extent permitted by applicable law. You can redistribute it
6 * and/or modify it under the terms of the Do What The Fuck You Want
7 * To Public License, Version 2, as published by Sam Hocevar. See
8 * http://sam.zoy.org/wtfpl/COPYING for more details.
9 */
10 #include <QDebug>
12 #include <QDialog>
13 #include <QFile>
14 #include <QScrollBar>
15 #include <QTextStream>
17 #include "psycproto.h"
19 #include "joinwin.h"
22 JoinWin::JoinWin (QWidget *parent) : QDialog(parent) {
23 setupUi(this);
24 setAttribute(Qt::WA_QuitOnClose, false);
25 setAttribute(Qt::WA_DeleteOnClose, true);
27 btEnter->setEnabled(false);
31 JoinWin::~JoinWin () {
35 void JoinWin::on_leNick_textChanged (void) {
39 void JoinWin::on_leHost_textChanged (void) {
40 PsycEntity u("psyc://"+leHost->text()+"/@"+leRoom->text());
41 btEnter->setEnabled(u.isValid());
45 void JoinWin::on_leRoom_textChanged (void) {
46 PsycEntity u("psyc://"+leHost->text()+"/@"+leRoom->text());
47 btEnter->setEnabled(u.isValid());
51 void JoinWin::on_btEnter_clicked (void) {
52 PsycEntity u("psyc://"+leHost->text()+"/@"+leRoom->text());
53 if (!u.isValid()) return;
54 emit enter(u);
55 close();