keygenWidget.cc 633 Bytes
Newer Older
Jan Möbius's avatar
Jan Möbius committed
1
2
3

#include <QtGui>
#include "keygenWidget.hh"
Jan Möbius's avatar
Jan Möbius committed
4
#include <iostream>
Jan Möbius's avatar
Jan Möbius committed
5

Jan Möbius's avatar
Jan Möbius committed
6
7
8
9
#include "salt.hh"

KeyGenWidget::KeyGenWidget(QMainWindow *parent)
    : QMainWindow(parent)
Jan Möbius's avatar
Jan Möbius committed
10
{
Jan Möbius's avatar
Jan Möbius committed
11
12
13
  setupUi(this);
  connect(generateButton,SIGNAL(clicked()),this,SLOT(slotGenerateButton()));
}
Jan Möbius's avatar
Jan Möbius committed
14

Jan Möbius's avatar
Jan Möbius committed
15
KeyGenWidget::~KeyGenWidget() {
Jan Möbius's avatar
Jan Möbius committed
16
17
18

}

Jan Möbius's avatar
Jan Möbius committed
19
20
21
22
23
24
25
26
27
28
void KeyGenWidget::slotGenerateButton() {

    QString inputData = requestData->toPlainText();
    QStringList data = inputData.split('\n',QString::SkipEmptyParts);

    if ( data.size() != 5) {
      QMessageBox::critical(this,"Wrong request data","The request has to contain 5 lines of data");
    } else {
      close();
    }
Jan Möbius's avatar
Jan Möbius committed
29

Jan Möbius's avatar
Jan Möbius committed
30
31
  
 
Jan Möbius's avatar
Jan Möbius committed
32
}