summaryrefslogtreecommitdiffstats
path: root/src/tabsymmetric.h
blob: ae65466714ec079e47684d72f626a3f5776e5710 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
#ifndef TABSYMMETRIC_H
#define TABSYMMETRIC_H

#include <QWidget>

#include "cipherssingleton.h"

namespace Ui {
class TabSymmetric;
}


/**
* \class TabSymmetric
* \brief TabWidget for the TabWidgetSelectAlgorithm, Symmetric Ciphers.
*
* This Widget contains all Settings necessary for Symmetric Ciphers and is used as a Tab in the TabWidgetSelectAlgorithm-Class.
* \author Uwe Gogolin [Gogolin.Uwe@FH-SWF.de]
* \version 0.2
* \date 13.05.2013
*/
class TabSymmetric : public QWidget
{
    Q_OBJECT
    
public: //Methods
    /**
    * \brief Class Constructor.
    *
    * Class Constructor. Initializes Graphical Elements of the Widget.
    * \param QWidget* parent The QWidget the used instance of this class is subordinated to.
    */
    TabSymmetric(QWidget *parent = 0);


    /**
    * \brief Class Destructor.
    *
    * Class Destructor. Deletes the ui-Object containing the graphical Elements.
    */
    ~TabSymmetric();
    

signals:
    /**
    * \brief SIGNAL to inform other Classes when a Cipher gets selected.
    *
    * This Signal is used to inform other Classes when a Cipher gets selected.
    * \param int cipher The Integer referencing the selected Cipher according to the Class CiphersSingleton.
    */
    void cipherChanged(int cipher);


    /**
    * \brief SIGNAL to inform other Classes when the Keylength is changed.
    *
    * This Signal is used to inform other Classes when the Keylength is changed.
    * \param int keyLength The new Keylength.
    * \param bool symmetric True if Length for Symmetric Cipher, false if for asymmetric Cipher.
    */
    void keyLengthChanged(int keyLength, bool symmetric);

private slots:
    /**
    * \brief SLOT to pass on the new Keylength.
    *
    * Called when a new Keylength is selected. Passes the value on in connection with a bool
    * set to true, signifying that it is for a symmetric Cipher.
    * \param int value The new Keylength.
    */
    void on_spinBoxKeylength_valueChanged(int value);


private: //Attributes
    /**
    * \brief Pointer to GUI-Object.
    */
    Ui::TabSymmetric *ui;
};

#endif // TABSYMMETRIC_H