-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathproblemdialog.cpp
More file actions
55 lines (47 loc) · 1.26 KB
/
problemdialog.cpp
File metadata and controls
55 lines (47 loc) · 1.26 KB
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
#include "problemdialog.h"
#include "ui_problemdialog.h"
#include <QDialog>
//********************************************************************
//
// Class: ProblemDialog
// Author: Fenja Harbke
//
// Purpose: called by MainWindow, when information does not fit into file
// give the user choice to react
// call choseNewPic, moreDensity, choseMorePics
//
//********************************************************************
#define CANCEL 0
#define DENSITY 1
#define PICS 2
#define NEWPIC 3
ProblemDialog::ProblemDialog(QWidget *parent) :
QDialog(parent),
ui(new Ui::ProblemDialog)
{
ui->setupUi(this);
setWindowTitle("Stegosaur");
setWindowFlags(Qt::Dialog);
connect(ui->newPicButton, SIGNAL(clicked()), this, SLOT(choseNewPic()) );
connect(ui->moreDensityButton, SIGNAL(clicked()), this, SLOT(moreDensity()) );
connect(ui->morePicsButton, SIGNAL(clicked()), this, SLOT(choseMorePics()) );
}
ProblemDialog::~ProblemDialog()
{
delete ui;
}
void ProblemDialog::choseNewPic()
{
close();
setResult(NEWPIC);
}
void ProblemDialog::moreDensity()
{
close();
setResult(DENSITY);
}
void ProblemDialog::choseMorePics()
{
close();
setResult(PICS);
}