author | Michel Szarindar <Michel.Szarindar@Nokia.com> |
Thu, 18 Mar 2010 18:26:18 +0000 | |
changeset 1 | 82f11024044a |
parent 0 | 42188c7ea2d9 |
permissions | -rw-r--r-- |
0
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
1 |
#include "wizard.h" |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
2 |
#include "input.h" |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
3 |
#include "doxywizard.h" |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
4 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
5 |
#include <QtGui> |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
6 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
7 |
// step1 options |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
8 |
#define STR_PROJECT_NAME QString::fromAscii("PROJECT_NAME") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
9 |
#define STR_INPUT QString::fromAscii("INPUT") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
10 |
#define STR_OUTPUT_DIRECTORY QString::fromAscii("OUTPUT_DIRECTORY") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
11 |
#define STR_PROJECT_NUMBER QString::fromAscii("PROJECT_NUMBER") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
12 |
#define STR_RECURSIVE QString::fromAscii("RECURSIVE") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
13 |
#define STR_OPTIMIZE_OUTPUT_FOR_C QString::fromAscii("OPTIMIZE_OUTPUT_FOR_C") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
14 |
#define STR_OPTIMIZE_OUTPUT_JAVA QString::fromAscii("OPTIMIZE_OUTPUT_JAVA") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
15 |
#define STR_OPTIMIZE_FOR_FORTRAN QString::fromAscii("OPTIMIZE_FOR_FORTRAN") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
16 |
#define STR_OPTIMIZE_OUTPUT_VHDL QString::fromAscii("OPTIMIZE_OUTPUT_VHDL") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
17 |
#define STR_CPP_CLI_SUPPORT QString::fromAscii("CPP_CLI_SUPPORT") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
18 |
#define STR_HIDE_SCOPE_NAMES QString::fromAscii("HIDE_SCOPE_NAMES") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
19 |
#define STR_EXTRACT_ALL QString::fromAscii("EXTRACT_ALL") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
20 |
#define STR_SOURCE_BROWSER QString::fromAscii("SOURCE_BROWSER") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
21 |
#define STR_GENERATE_HTML QString::fromAscii("GENERATE_HTML") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
22 |
#define STR_GENERATE_LATEX QString::fromAscii("GENERATE_LATEX") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
23 |
#define STR_GENERATE_MAN QString::fromAscii("GENERATE_MAN") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
24 |
#define STR_GENERATE_RTF QString::fromAscii("GENERATE_RTF") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
25 |
#define STR_GENERATE_XML QString::fromAscii("GENERATE_XML") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
26 |
#define STR_GENERATE_HTMLHELP QString::fromAscii("GENERATE_HTMLHELP") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
27 |
#define STR_GENERATE_TREEVIEW QString::fromAscii("GENERATE_TREEVIEW") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
28 |
#define STR_USE_PDFLATEX QString::fromAscii("USE_PDFLATEX") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
29 |
#define STR_PDF_HYPERLINKS QString::fromAscii("PDF_HYPERLINKS") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
30 |
#define STR_SEARCHENGINE QString::fromAscii("SEARCHENGINE") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
31 |
#define STR_HAVE_DOT QString::fromAscii("HAVE_DOT") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
32 |
#define STR_CLASS_DIAGRAMS QString::fromAscii("CLASS_DIAGRAMS") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
33 |
#define STR_CLASS_GRAPH QString::fromAscii("CLASS_GRAPH") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
34 |
#define STR_COLLABORATION_GRAPH QString::fromAscii("COLLABORATION_GRAPH") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
35 |
#define STR_GRAPHICAL_HIERARCHY QString::fromAscii("GRAPHICAL_HIERARCHY") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
36 |
#define STR_INCLUDE_GRAPH QString::fromAscii("INCLUDE_GRAPH") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
37 |
#define STR_INCLUDED_BY_GRAPH QString::fromAscii("INCLUDED_BY_GRAPH") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
38 |
#define STR_CALL_GRAPH QString::fromAscii("CALL_GRAPH") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
39 |
#define STR_CALLER_GRAPH QString::fromAscii("CALLER_GRAPH") |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
40 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
41 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
42 |
static bool g_optimizeMapping[6][6] = |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
43 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
44 |
// A: OPTIMIZE_OUTPUT_FOR_C |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
45 |
// B: OPTIMIZE_OUTPUT_JAVA |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
46 |
// C: OPTIMIZE_FOR_FORTRAN |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
47 |
// D: OPTIMIZE_OUTPUT_VHDL |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
48 |
// E: CPP_CLI_SUPPORT |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
49 |
// F: HIDE_SCOPE_NAMES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
50 |
// A B C D E F |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
51 |
{ false,false,false,false,false,false }, // 0: C++ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
52 |
{ false,false,false,false,true, false }, // 1: C++/CLI |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
53 |
{ false,true, false,false,false,false }, // 2: C#/Java |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
54 |
{ true, false,false,false,false,true }, // 3: C/PHP |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
55 |
{ false,false,true, false,false,false }, // 4: Fortran |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
56 |
{ false,false,false,true, false,false }, // 5: VHDL |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
57 |
}; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
58 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
59 |
static QString g_optimizeOptionNames[6] = |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
60 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
61 |
STR_OPTIMIZE_OUTPUT_FOR_C, |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
62 |
STR_OPTIMIZE_OUTPUT_JAVA, |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
63 |
STR_OPTIMIZE_FOR_FORTRAN, |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
64 |
STR_OPTIMIZE_OUTPUT_VHDL, |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
65 |
STR_CPP_CLI_SUPPORT, |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
66 |
STR_HIDE_SCOPE_NAMES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
67 |
}; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
68 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
69 |
//========================================================================== |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
70 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
71 |
static bool stringVariantToBool(const QVariant &v) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
72 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
73 |
QString s = v.toString().toLower(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
74 |
return s==QString::fromAscii("yes") || s==QString::fromAscii("true") || s==QString::fromAscii("1"); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
75 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
76 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
77 |
static bool getBoolOption( |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
78 |
const QHash<QString,Input*>&model,const QString &name) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
79 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
80 |
Input *option = model[name]; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
81 |
Q_ASSERT(option!=0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
82 |
return stringVariantToBool(option->value()); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
83 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
84 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
85 |
static QString getStringOption( |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
86 |
const QHash<QString,Input*>&model,const QString &name) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
87 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
88 |
Input *option = model[name]; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
89 |
Q_ASSERT(option!=0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
90 |
return option->value().toString(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
91 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
92 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
93 |
static void updateBoolOption( |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
94 |
const QHash<QString,Input*>&model,const QString &name,bool bNew) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
95 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
96 |
Input *option = model[name]; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
97 |
Q_ASSERT(option!=0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
98 |
bool bOld = stringVariantToBool(option->value()); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
99 |
if (bOld!=bNew) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
100 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
101 |
option->value()=QString::fromAscii(bNew ? "true" : "false"); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
102 |
option->update(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
103 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
104 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
105 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
106 |
static void updateStringOption( |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
107 |
const QHash<QString,Input*>&model,const QString &name,const QString &s) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
108 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
109 |
Input *option = model[name]; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
110 |
Q_ASSERT(option!=0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
111 |
if (option->value().toString()!=s) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
112 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
113 |
option->value() = s; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
114 |
option->update(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
115 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
116 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
117 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
118 |
//========================================================================== |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
119 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
120 |
Step1::Step1(Wizard *wizard,const QHash<QString,Input*> &modelData) : m_wizard(wizard), m_modelData(modelData) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
121 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
122 |
QVBoxLayout *layout = new QVBoxLayout(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
123 |
layout->setMargin(4); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
124 |
layout->setSpacing(8); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
125 |
QLabel *l = new QLabel(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
126 |
l->setText(tr("Provide some information " |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
127 |
"about the project you are documenting")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
128 |
layout->addWidget(l); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
129 |
QWidget *w = new QWidget( this ); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
130 |
QHBoxLayout *bl = new QHBoxLayout(w); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
131 |
bl->setSpacing(10); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
132 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
133 |
QWidget *col1 = new QWidget; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
134 |
QVBoxLayout *col1Layout = new QVBoxLayout(col1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
135 |
col1Layout->setSpacing(8); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
136 |
QLabel *projName = new QLabel(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
137 |
projName->setText(tr("Project name:")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
138 |
projName->setAlignment(Qt::AlignRight|Qt::AlignVCenter); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
139 |
QLabel *projVersion = new QLabel(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
140 |
projVersion->setText(tr("Project version or id:")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
141 |
projVersion->setAlignment(Qt::AlignRight|Qt::AlignVCenter); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
142 |
col1Layout->addWidget(projName); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
143 |
col1Layout->addWidget(projVersion); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
144 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
145 |
QWidget *col2 = new QWidget; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
146 |
QVBoxLayout *col2Layout = new QVBoxLayout(col2); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
147 |
col2Layout->setSpacing(8); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
148 |
m_projName = new QLineEdit; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
149 |
m_projNumber = new QLineEdit; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
150 |
col2Layout->addWidget(m_projName); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
151 |
col2Layout->addWidget(m_projNumber); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
152 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
153 |
bl->addWidget(col1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
154 |
bl->addWidget(col2); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
155 |
w->setLayout(bl); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
156 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
157 |
layout->addWidget(w); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
158 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
159 |
//--------------------------------------------------- |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
160 |
QFrame *f = new QFrame( this ); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
161 |
f->setFrameStyle( QFrame::HLine | QFrame::Sunken ); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
162 |
layout->addWidget(f); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
163 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
164 |
l = new QLabel(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
165 |
l->setText(tr("Specify the directory to scan for source code")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
166 |
layout->addWidget(l); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
167 |
QWidget *row = new QWidget; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
168 |
QHBoxLayout *rowLayout = new QHBoxLayout(row); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
169 |
rowLayout->setSpacing(10); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
170 |
l = new QLabel(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
171 |
l->setText(tr("Source code directory:")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
172 |
rowLayout->addWidget(l); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
173 |
m_sourceDir = new QLineEdit; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
174 |
m_srcSelectDir = new QPushButton(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
175 |
m_srcSelectDir->setText(tr("Select...")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
176 |
rowLayout->addWidget(m_sourceDir); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
177 |
rowLayout->addWidget(m_srcSelectDir); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
178 |
layout->addWidget(row); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
179 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
180 |
m_recursive = new QCheckBox(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
181 |
m_recursive->setText(tr("Scan recursively")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
182 |
m_recursive->setChecked(TRUE); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
183 |
layout->addWidget(m_recursive); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
184 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
185 |
//--------------------------------------------------- |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
186 |
f = new QFrame( this ); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
187 |
f->setFrameStyle( QFrame::HLine | QFrame::Sunken ); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
188 |
layout->addWidget(f); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
189 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
190 |
l = new QLabel(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
191 |
l->setText(tr("Specify the directory where doxygen should " |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
192 |
"put the generated documentation")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
193 |
layout->addWidget(l); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
194 |
row = new QWidget; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
195 |
rowLayout = new QHBoxLayout(row); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
196 |
rowLayout->setSpacing(10); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
197 |
l = new QLabel(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
198 |
l->setText(tr("Destination directory:")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
199 |
rowLayout->addWidget(l); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
200 |
m_destDir = new QLineEdit; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
201 |
m_dstSelectDir = new QPushButton(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
202 |
m_dstSelectDir->setText(tr("Select...")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
203 |
rowLayout->addWidget(m_destDir); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
204 |
rowLayout->addWidget(m_dstSelectDir); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
205 |
layout->addWidget(row); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
206 |
layout->addStretch(1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
207 |
setLayout(layout); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
208 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
209 |
connect(m_srcSelectDir,SIGNAL(clicked()), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
210 |
this,SLOT(selectSourceDir())); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
211 |
connect(m_dstSelectDir,SIGNAL(clicked()), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
212 |
this,SLOT(selectDestinationDir())); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
213 |
connect(m_projName,SIGNAL(textChanged(const QString &)),SLOT(setProjectName(const QString &))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
214 |
connect(m_projNumber,SIGNAL(textChanged(const QString &)),SLOT(setProjectNumber(const QString &))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
215 |
connect(m_sourceDir,SIGNAL(textChanged(const QString &)),SLOT(setSourceDir(const QString &))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
216 |
connect(m_recursive,SIGNAL(stateChanged(int)),SLOT(setRecursiveScan(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
217 |
connect(m_destDir,SIGNAL(textChanged(const QString &)),SLOT(setDestinationDir(const QString &))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
218 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
219 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
220 |
void Step1::selectSourceDir() |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
221 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
222 |
QString path = QFileInfo(MainWindow::instance().configFileName()).path(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
223 |
QString dirName = QFileDialog::getExistingDirectory(this, |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
224 |
tr("Select source directory"),path); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
225 |
QDir dir(path); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
226 |
if (!MainWindow::instance().configFileName().isEmpty() && dir.exists()) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
227 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
228 |
dirName = dir.relativeFilePath(dirName); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
229 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
230 |
if (dirName.isEmpty()) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
231 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
232 |
dirName=QString::fromAscii("."); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
233 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
234 |
m_sourceDir->setText(dirName); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
235 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
236 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
237 |
void Step1::selectDestinationDir() |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
238 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
239 |
QString path = QFileInfo(MainWindow::instance().configFileName()).path(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
240 |
QString dirName = QFileDialog::getExistingDirectory(this, |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
241 |
tr("Select destination directory"),path); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
242 |
QDir dir(path); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
243 |
if (!MainWindow::instance().configFileName().isEmpty() && dir.exists()) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
244 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
245 |
dirName = dir.relativeFilePath(dirName); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
246 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
247 |
if (dirName.isEmpty()) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
248 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
249 |
dirName=QString::fromAscii("."); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
250 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
251 |
m_destDir->setText(dirName); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
252 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
253 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
254 |
void Step1::setProjectName(const QString &name) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
255 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
256 |
updateStringOption(m_modelData,STR_PROJECT_NAME,name); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
257 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
258 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
259 |
void Step1::setProjectNumber(const QString &num) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
260 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
261 |
updateStringOption(m_modelData,STR_PROJECT_NUMBER,num); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
262 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
263 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
264 |
void Step1::setSourceDir(const QString &dir) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
265 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
266 |
Input *option = m_modelData[STR_INPUT]; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
267 |
if (option->value().toStringList().count()>0) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
268 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
269 |
QStringList sl = option->value().toStringList(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
270 |
if (sl[0]!=dir) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
271 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
272 |
sl[0] = dir; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
273 |
option->value() = sl; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
274 |
option->update(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
275 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
276 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
277 |
else |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
278 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
279 |
option->value() = QStringList() << dir; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
280 |
option->update(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
281 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
282 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
283 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
284 |
void Step1::setDestinationDir(const QString &dir) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
285 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
286 |
updateStringOption(m_modelData,STR_OUTPUT_DIRECTORY,dir); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
287 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
288 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
289 |
void Step1::setRecursiveScan(int s) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
290 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
291 |
updateBoolOption(m_modelData,STR_RECURSIVE,s==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
292 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
293 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
294 |
void Step1::init() |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
295 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
296 |
Input *option; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
297 |
m_projName->setText(getStringOption(m_modelData,STR_PROJECT_NAME)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
298 |
m_projNumber->setText(getStringOption(m_modelData,STR_PROJECT_NUMBER)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
299 |
option = m_modelData[STR_INPUT]; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
300 |
if (option->value().toStringList().count()>0) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
301 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
302 |
m_sourceDir->setText(option->value().toStringList().first()); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
303 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
304 |
m_recursive->setChecked( |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
305 |
getBoolOption(m_modelData,STR_RECURSIVE) ? Qt::Checked : Qt::Unchecked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
306 |
m_destDir->setText(getStringOption(m_modelData,STR_OUTPUT_DIRECTORY)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
307 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
308 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
309 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
310 |
//========================================================================== |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
311 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
312 |
Step2::Step2(Wizard *wizard,const QHash<QString,Input*> &modelData) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
313 |
: m_wizard(wizard), m_modelData(modelData) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
314 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
315 |
QRadioButton *r; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
316 |
QVBoxLayout *layout = new QVBoxLayout(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
317 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
318 |
//--------------------------------------------------- |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
319 |
m_extractModeGroup = new QButtonGroup(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
320 |
m_extractMode = new QGroupBox(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
321 |
m_extractMode->setTitle(tr("Select the desired extraction mode:")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
322 |
QGridLayout *gbox = new QGridLayout( m_extractMode ); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
323 |
r = new QRadioButton(tr("Documented entities only")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
324 |
r->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
325 |
m_extractModeGroup->addButton(r, 0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
326 |
gbox->addWidget(r,1,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
327 |
// 1 -> EXTRACT_ALL = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
328 |
r = new QRadioButton(tr("All Entities")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
329 |
m_extractModeGroup->addButton(r, 1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
330 |
gbox->addWidget(r,2,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
331 |
// 2 -> EXTRACT_ALL = YES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
332 |
m_crossRef = new QCheckBox(m_extractMode); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
333 |
m_crossRef->setText(tr("Include cross-referenced source code in the output")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
334 |
// m_crossRef -> SOURCE_BROWSER = YES/NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
335 |
gbox->addWidget(m_crossRef,3,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
336 |
layout->addWidget(m_extractMode); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
337 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
338 |
//--------------------------------------------------- |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
339 |
QFrame *f = new QFrame( this ); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
340 |
f->setFrameStyle( QFrame::HLine | QFrame::Sunken ); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
341 |
layout->addWidget(f); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
342 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
343 |
m_optimizeLangGroup = new QButtonGroup(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
344 |
m_optimizeLang = new QGroupBox(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
345 |
m_optimizeLang->setTitle(tr("Select programming language to optimize the results for")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
346 |
gbox = new QGridLayout( m_optimizeLang ); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
347 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
348 |
r = new QRadioButton(m_optimizeLang); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
349 |
r->setText(tr("Optimize for C++ output")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
350 |
r->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
351 |
m_optimizeLangGroup->addButton(r, 0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
352 |
// 0 -> OPTIMIZE_OUTPUT_FOR_C = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
353 |
// OPTIMIZE_OUTPUT_JAVA = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
354 |
// OPTIMIZE_FOR_FORTRAN = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
355 |
// OPTIMIZE_OUTPUT_VHDL = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
356 |
// CPP_CLI_SUPPORT = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
357 |
// HIDE_SCOPE_NAMES = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
358 |
gbox->addWidget(r,0,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
359 |
r = new QRadioButton(tr("Optimize for C++/CLI output")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
360 |
gbox->addWidget(r,1,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
361 |
m_optimizeLangGroup->addButton(r, 1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
362 |
// 1 -> OPTIMIZE_OUTPUT_FOR_C = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
363 |
// OPTIMIZE_OUTPUT_JAVA = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
364 |
// OPTIMIZE_FOR_FORTRAN = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
365 |
// OPTIMIZE_OUTPUT_VHDL = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
366 |
// CPP_CLI_SUPPORT = YES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
367 |
// HIDE_SCOPE_NAMES = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
368 |
r = new QRadioButton(tr("Optimize for Java or C# output")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
369 |
m_optimizeLangGroup->addButton(r, 2); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
370 |
// 2 -> OPTIMIZE_OUTPUT_FOR_C = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
371 |
// OPTIMIZE_OUTPUT_JAVA = YES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
372 |
// OPTIMIZE_FOR_FORTRAN = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
373 |
// OPTIMIZE_OUTPUT_VHDL = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
374 |
// CPP_CLI_SUPPORT = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
375 |
// HIDE_SCOPE_NAMES = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
376 |
gbox->addWidget(r,2,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
377 |
r = new QRadioButton(tr("Optimize for C or PHP output")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
378 |
m_optimizeLangGroup->addButton(r, 3); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
379 |
// 3 -> OPTIMIZE_OUTPUT_FOR_C = YES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
380 |
// OPTIMIZE_OUTPUT_JAVA = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
381 |
// OPTIMIZE_FOR_FORTRAN = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
382 |
// OPTIMIZE_OUTPUT_VHDL = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
383 |
// CPP_CLI_SUPPORT = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
384 |
// HIDE_SCOPE_NAMES = YES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
385 |
gbox->addWidget(r,3,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
386 |
r = new QRadioButton(tr("Optimize for Fortran output")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
387 |
m_optimizeLangGroup->addButton(r, 4); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
388 |
// 4 -> OPTIMIZE_OUTPUT_FOR_C = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
389 |
// OPTIMIZE_OUTPUT_JAVA = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
390 |
// OPTIMIZE_FOR_FORTRAN = YES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
391 |
// OPTIMIZE_OUTPUT_VHDL = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
392 |
// CPP_CLI_SUPPORT = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
393 |
// HIDE_SCOPE_NAMES = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
394 |
gbox->addWidget(r,4,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
395 |
r = new QRadioButton(tr("Optimize for VHDL output")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
396 |
m_optimizeLangGroup->addButton(r, 5); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
397 |
// 5 -> OPTIMIZE_OUTPUT_FOR_C = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
398 |
// OPTIMIZE_OUTPUT_JAVA = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
399 |
// OPTIMIZE_FOR_FORTRAN = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
400 |
// OPTIMIZE_OUTPUT_VHDL = YES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
401 |
// CPP_CLI_SUPPORT = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
402 |
// HIDE_SCOPE_NAMES = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
403 |
gbox->addWidget(r,5,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
404 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
405 |
layout->addWidget(m_optimizeLang); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
406 |
layout->addStretch(1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
407 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
408 |
connect(m_crossRef,SIGNAL(stateChanged(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
409 |
SLOT(changeCrossRefState(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
410 |
connect(m_optimizeLangGroup,SIGNAL(buttonClicked(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
411 |
SLOT(optimizeFor(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
412 |
connect(m_extractModeGroup,SIGNAL(buttonClicked(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
413 |
SLOT(extractMode(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
414 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
415 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
416 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
417 |
void Step2::optimizeFor(int choice) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
418 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
419 |
for (int i=0;i<6;i++) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
420 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
421 |
updateBoolOption(m_modelData, |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
422 |
g_optimizeOptionNames[i], |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
423 |
g_optimizeMapping[choice][i]); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
424 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
425 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
426 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
427 |
void Step2::extractMode(int choice) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
428 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
429 |
updateBoolOption(m_modelData,STR_EXTRACT_ALL,choice==1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
430 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
431 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
432 |
void Step2::changeCrossRefState(int choice) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
433 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
434 |
updateBoolOption(m_modelData,STR_SOURCE_BROWSER,choice==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
435 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
436 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
437 |
void Step2::init() |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
438 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
439 |
m_extractModeGroup->button( |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
440 |
getBoolOption(m_modelData,STR_EXTRACT_ALL) ? 1 : 0)->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
441 |
m_crossRef->setChecked(getBoolOption(m_modelData,STR_SOURCE_BROWSER)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
442 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
443 |
int x=0; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
444 |
if (getBoolOption(m_modelData,STR_CPP_CLI_SUPPORT)) x=1; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
445 |
else if (getBoolOption(m_modelData,STR_OPTIMIZE_OUTPUT_JAVA)) x=2; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
446 |
else if (getBoolOption(m_modelData,STR_OPTIMIZE_OUTPUT_FOR_C)) x=3; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
447 |
else if (getBoolOption(m_modelData,STR_OPTIMIZE_FOR_FORTRAN)) x=4; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
448 |
else if (getBoolOption(m_modelData,STR_OPTIMIZE_OUTPUT_VHDL)) x=5; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
449 |
m_optimizeLangGroup->button(x)->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
450 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
451 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
452 |
//========================================================================== |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
453 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
454 |
Step3::Step3(Wizard *wizard,const QHash<QString,Input*> &modelData) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
455 |
: m_wizard(wizard), m_modelData(modelData) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
456 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
457 |
QVBoxLayout *vbox = 0; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
458 |
QRadioButton *r = 0; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
459 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
460 |
QGridLayout *gbox = new QGridLayout( this ); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
461 |
gbox->addWidget(new QLabel(tr("Select the output format(s) to generate")),0,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
462 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
463 |
m_htmlOptions = new QGroupBox(tr("HTML")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
464 |
m_htmlOptions->setCheckable(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
465 |
// GENERATE_HTML |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
466 |
m_htmlOptionsGroup = new QButtonGroup(m_htmlOptions); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
467 |
QRadioButton *r = new QRadioButton(tr("plain HTML")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
468 |
r->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
469 |
m_htmlOptionsGroup->addButton(r, 0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
470 |
vbox = new QVBoxLayout; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
471 |
vbox->addWidget(r); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
472 |
r = new QRadioButton(tr("with frames and a navigation tree")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
473 |
m_htmlOptionsGroup->addButton(r, 1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
474 |
// GENERATE_TREEVIEW |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
475 |
vbox->addWidget(r); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
476 |
r = new QRadioButton(tr("prepare for compressed HTML (.chm)")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
477 |
m_htmlOptionsGroup->addButton(r, 2); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
478 |
// GENERATE_HTMLHELP |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
479 |
vbox->addWidget(r); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
480 |
m_searchEnabled=new QCheckBox(tr("With search function (requires PHP enabled web server)")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
481 |
vbox->addWidget(m_searchEnabled); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
482 |
// SEARCH_ENGINE |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
483 |
m_htmlOptions->setLayout(vbox); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
484 |
m_htmlOptions->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
485 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
486 |
gbox->addWidget(m_htmlOptions,1,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
487 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
488 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
489 |
m_texOptions = new QGroupBox(tr("LaTeX")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
490 |
m_texOptions->setCheckable(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
491 |
// GENERATE_LATEX |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
492 |
m_texOptionsGroup = new QButtonGroup(m_texOptions); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
493 |
vbox = new QVBoxLayout; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
494 |
r = new QRadioButton(tr("as intermediate format for hyperlinked PDF")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
495 |
m_texOptionsGroup->addButton(r, 0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
496 |
// PDF_HYPERLINKS = YES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
497 |
r->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
498 |
vbox->addWidget(r); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
499 |
r = new QRadioButton(tr("as intermediate format for PDF")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
500 |
m_texOptionsGroup->addButton(r, 1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
501 |
// PDF_HYPERLINKS = NO, USE_PDFLATEX = YES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
502 |
vbox->addWidget(r); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
503 |
r = new QRadioButton(tr("as intermediate format for PostScript")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
504 |
m_texOptionsGroup->addButton(r, 2); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
505 |
// USE_PDFLATEX = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
506 |
vbox->addWidget(r); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
507 |
vbox->addStretch(1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
508 |
m_texOptions->setLayout(vbox); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
509 |
m_texOptions->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
510 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
511 |
gbox->addWidget(m_texOptions,2,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
512 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
513 |
m_manEnabled=new QCheckBox(tr("Man pages")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
514 |
// GENERATE_MAN |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
515 |
m_rtfEnabled=new QCheckBox(tr("Rich Text Format (RTF)")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
516 |
// GENERATE_RTF |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
517 |
m_xmlEnabled=new QCheckBox(tr("XML")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
518 |
// GENERATE_XML |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
519 |
gbox->addWidget(m_manEnabled,3,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
520 |
gbox->addWidget(m_rtfEnabled,4,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
521 |
gbox->addWidget(m_xmlEnabled,5,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
522 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
523 |
gbox->setRowStretch(6,1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
524 |
connect(m_htmlOptions,SIGNAL(toggled(bool)),SLOT(setHtmlEnabled(bool))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
525 |
connect(m_texOptions,SIGNAL(toggled(bool)),SLOT(setLatexEnabled(bool))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
526 |
connect(m_manEnabled,SIGNAL(stateChanged(int)),SLOT(setManEnabled(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
527 |
connect(m_rtfEnabled,SIGNAL(stateChanged(int)),SLOT(setRtfEnabled(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
528 |
connect(m_xmlEnabled,SIGNAL(stateChanged(int)),SLOT(setXmlEnabled(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
529 |
connect(m_searchEnabled,SIGNAL(stateChanged(int)),SLOT(setSearchEnabled(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
530 |
connect(m_htmlOptionsGroup,SIGNAL(buttonClicked(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
531 |
SLOT(setHtmlOptions(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
532 |
connect(m_texOptionsGroup,SIGNAL(buttonClicked(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
533 |
SLOT(setLatexOptions(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
534 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
535 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
536 |
void Step3::setHtmlEnabled(bool b) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
537 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
538 |
updateBoolOption(m_modelData,STR_GENERATE_HTML,b); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
539 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
540 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
541 |
void Step3::setLatexEnabled(bool b) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
542 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
543 |
updateBoolOption(m_modelData,STR_GENERATE_LATEX,b); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
544 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
545 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
546 |
void Step3::setManEnabled(int state) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
547 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
548 |
updateBoolOption(m_modelData,STR_GENERATE_MAN,state==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
549 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
550 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
551 |
void Step3::setRtfEnabled(int state) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
552 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
553 |
updateBoolOption(m_modelData,STR_GENERATE_RTF,state==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
554 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
555 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
556 |
void Step3::setXmlEnabled(int state) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
557 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
558 |
updateBoolOption(m_modelData,STR_GENERATE_XML,state==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
559 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
560 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
561 |
void Step3::setSearchEnabled(int state) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
562 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
563 |
updateBoolOption(m_modelData,STR_SEARCHENGINE,state==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
564 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
565 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
566 |
void Step3::setHtmlOptions(int id) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
567 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
568 |
if (id==0) // plain HTML |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
569 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
570 |
updateBoolOption(m_modelData,STR_GENERATE_HTMLHELP,false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
571 |
updateBoolOption(m_modelData,STR_GENERATE_TREEVIEW,false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
572 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
573 |
else if (id==1) // with navigation tree |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
574 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
575 |
updateBoolOption(m_modelData,STR_GENERATE_HTMLHELP,false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
576 |
updateBoolOption(m_modelData,STR_GENERATE_TREEVIEW,true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
577 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
578 |
else if (id==2) // with compiled help |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
579 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
580 |
updateBoolOption(m_modelData,STR_GENERATE_HTMLHELP,true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
581 |
updateBoolOption(m_modelData,STR_GENERATE_TREEVIEW,false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
582 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
583 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
584 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
585 |
void Step3::setLatexOptions(int id) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
586 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
587 |
if (id==0) // hyperlinked PDF |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
588 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
589 |
updateBoolOption(m_modelData,STR_USE_PDFLATEX,true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
590 |
updateBoolOption(m_modelData,STR_PDF_HYPERLINKS,true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
591 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
592 |
else if (id==1) // PDF |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
593 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
594 |
updateBoolOption(m_modelData,STR_USE_PDFLATEX,true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
595 |
updateBoolOption(m_modelData,STR_PDF_HYPERLINKS,false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
596 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
597 |
else if (id==2) // PostScript |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
598 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
599 |
updateBoolOption(m_modelData,STR_USE_PDFLATEX,false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
600 |
updateBoolOption(m_modelData,STR_PDF_HYPERLINKS,false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
601 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
602 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
603 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
604 |
void Step3::init() |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
605 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
606 |
m_htmlOptions->setChecked(getBoolOption(m_modelData,STR_GENERATE_HTML)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
607 |
m_texOptions->setChecked(getBoolOption(m_modelData,STR_GENERATE_LATEX)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
608 |
m_manEnabled->setChecked(getBoolOption(m_modelData,STR_GENERATE_MAN)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
609 |
m_rtfEnabled->setChecked(getBoolOption(m_modelData,STR_GENERATE_RTF)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
610 |
m_xmlEnabled->setChecked(getBoolOption(m_modelData,STR_GENERATE_XML)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
611 |
m_searchEnabled->setChecked(getBoolOption(m_modelData,STR_SEARCHENGINE)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
612 |
if (getBoolOption(m_modelData,STR_GENERATE_HTMLHELP)) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
613 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
614 |
m_htmlOptionsGroup->button(2)->setChecked(true); // compiled help |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
615 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
616 |
else if (getBoolOption(m_modelData,STR_GENERATE_TREEVIEW)) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
617 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
618 |
m_htmlOptionsGroup->button(1)->setChecked(true); // navigation tree |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
619 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
620 |
else |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
621 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
622 |
m_htmlOptionsGroup->button(0)->setChecked(true); // plain HTML |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
623 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
624 |
if (!getBoolOption(m_modelData,STR_USE_PDFLATEX)) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
625 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
626 |
m_texOptionsGroup->button(2)->setChecked(true); // PostScript |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
627 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
628 |
else if (!getBoolOption(m_modelData,STR_PDF_HYPERLINKS)) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
629 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
630 |
m_texOptionsGroup->button(1)->setChecked(true); // Plain PDF |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
631 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
632 |
else |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
633 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
634 |
m_texOptionsGroup->button(0)->setChecked(true); // PDF with hyperlinks |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
635 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
636 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
637 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
638 |
//========================================================================== |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
639 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
640 |
Step4::Step4(Wizard *wizard,const QHash<QString,Input*> &modelData) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
641 |
: m_wizard(wizard), m_modelData(modelData) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
642 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
643 |
m_diagramModeGroup = new QButtonGroup(this); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
644 |
QGridLayout *gbox = new QGridLayout( this ); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
645 |
gbox->addWidget(new QLabel(tr("Diagrams to generate")),0,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
646 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
647 |
QRadioButton *rb = new QRadioButton(tr("No diagrams")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
648 |
m_diagramModeGroup->addButton(rb, 0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
649 |
gbox->addWidget(rb,1,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
650 |
// CLASS_DIAGRAMS = NO, HAVE_DOT = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
651 |
rb->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
652 |
rb = new QRadioButton(tr("Use built-in class diagram generator")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
653 |
m_diagramModeGroup->addButton(rb, 1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
654 |
// CLASS_DIAGRAMS = YES, HAVE_DOT = NO |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
655 |
gbox->addWidget(rb,2,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
656 |
rb = new QRadioButton(tr("Use dot tool from the GraphViz package")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
657 |
m_diagramModeGroup->addButton(rb, 2); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
658 |
gbox->addWidget(rb,3,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
659 |
// CLASS_DIAGRAMS = NO, HAVE_DOT = YES |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
660 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
661 |
m_dotGroup = new QGroupBox(tr("Dot graphs to generate")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
662 |
QVBoxLayout *vbox = new QVBoxLayout; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
663 |
m_dotClass=new QCheckBox(tr("Class diagrams")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
664 |
// CLASS_GRAPH |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
665 |
m_dotCollaboration=new QCheckBox(tr("Collaboration diagrams")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
666 |
// COLLABORATION_GRAPH |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
667 |
m_dotInheritance=new QCheckBox(tr("Overall Class hierarchy")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
668 |
// GRAPHICAL_HIERARCHY |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
669 |
m_dotInclude=new QCheckBox(tr("Include dependency graphs")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
670 |
// INCLUDE_GRAPH |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
671 |
m_dotIncludedBy=new QCheckBox(tr("Included by dependency graphs")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
672 |
// INCLUDED_BY_GRAPH |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
673 |
m_dotCall=new QCheckBox(tr("Call graphs")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
674 |
// CALL_GRAPH |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
675 |
m_dotCaller=new QCheckBox(tr("Called by graphs")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
676 |
// CALLER_GRAPH |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
677 |
vbox->addWidget(m_dotClass); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
678 |
vbox->addWidget(m_dotCollaboration); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
679 |
vbox->addWidget(m_dotInheritance); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
680 |
vbox->addWidget(m_dotInclude); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
681 |
vbox->addWidget(m_dotIncludedBy); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
682 |
vbox->addWidget(m_dotCall); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
683 |
vbox->addWidget(m_dotCaller); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
684 |
vbox->addStretch(1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
685 |
m_dotGroup->setLayout(vbox); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
686 |
m_dotClass->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
687 |
m_dotGroup->setEnabled(false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
688 |
gbox->addWidget(m_dotGroup,4,0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
689 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
690 |
m_dotInclude->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
691 |
m_dotCollaboration->setChecked(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
692 |
gbox->setRowStretch(5,1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
693 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
694 |
connect(m_diagramModeGroup,SIGNAL(buttonClicked(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
695 |
this,SLOT(diagramModeChanged(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
696 |
connect(m_dotClass,SIGNAL(stateChanged(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
697 |
this,SLOT(setClassGraphEnabled(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
698 |
connect(m_dotCollaboration,SIGNAL(stateChanged(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
699 |
this,SLOT(setCollaborationGraphEnabled(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
700 |
connect(m_dotInheritance,SIGNAL(stateChanged(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
701 |
this,SLOT(setGraphicalHierarchyEnabled(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
702 |
connect(m_dotInclude,SIGNAL(stateChanged(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
703 |
this,SLOT(setIncludeGraphEnabled(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
704 |
connect(m_dotIncludedBy,SIGNAL(stateChanged(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
705 |
this,SLOT(setIncludedByGraphEnabled(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
706 |
connect(m_dotCall,SIGNAL(stateChanged(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
707 |
this,SLOT(setCallGraphEnabled(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
708 |
connect(m_dotCaller,SIGNAL(stateChanged(int)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
709 |
this,SLOT(setCallerGraphEnabled(int))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
710 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
711 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
712 |
void Step4::diagramModeChanged(int id) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
713 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
714 |
if (id==0) // no diagrams |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
715 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
716 |
updateBoolOption(m_modelData,STR_HAVE_DOT,false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
717 |
updateBoolOption(m_modelData,STR_CLASS_DIAGRAMS,false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
718 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
719 |
else if (id==1) // builtin diagrams |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
720 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
721 |
updateBoolOption(m_modelData,STR_HAVE_DOT,false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
722 |
updateBoolOption(m_modelData,STR_CLASS_DIAGRAMS,true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
723 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
724 |
else if (id==2) // dot diagrams |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
725 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
726 |
updateBoolOption(m_modelData,STR_HAVE_DOT,true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
727 |
updateBoolOption(m_modelData,STR_CLASS_DIAGRAMS,false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
728 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
729 |
m_dotGroup->setEnabled(id==2); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
730 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
731 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
732 |
void Step4::setClassGraphEnabled(int state) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
733 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
734 |
updateBoolOption(m_modelData,STR_CLASS_GRAPH,state==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
735 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
736 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
737 |
void Step4::setCollaborationGraphEnabled(int state) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
738 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
739 |
updateBoolOption(m_modelData,STR_COLLABORATION_GRAPH,state==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
740 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
741 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
742 |
void Step4::setGraphicalHierarchyEnabled(int state) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
743 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
744 |
updateBoolOption(m_modelData,STR_GRAPHICAL_HIERARCHY,state==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
745 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
746 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
747 |
void Step4::setIncludeGraphEnabled(int state) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
748 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
749 |
updateBoolOption(m_modelData,STR_INCLUDE_GRAPH,state==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
750 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
751 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
752 |
void Step4::setIncludedByGraphEnabled(int state) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
753 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
754 |
updateBoolOption(m_modelData,STR_INCLUDED_BY_GRAPH,state==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
755 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
756 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
757 |
void Step4::setCallGraphEnabled(int state) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
758 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
759 |
updateBoolOption(m_modelData,STR_CALL_GRAPH,state==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
760 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
761 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
762 |
void Step4::setCallerGraphEnabled(int state) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
763 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
764 |
updateBoolOption(m_modelData,STR_CALLER_GRAPH,state==Qt::Checked); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
765 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
766 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
767 |
void Step4::init() |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
768 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
769 |
if (getBoolOption(m_modelData,STR_HAVE_DOT)) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
770 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
771 |
m_diagramModeGroup->button(2)->setChecked(true); // Dot |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
772 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
773 |
else if (getBoolOption(m_modelData,STR_CLASS_DIAGRAMS)) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
774 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
775 |
m_diagramModeGroup->button(1)->setChecked(true); // Builtin diagrams |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
776 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
777 |
else |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
778 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
779 |
m_diagramModeGroup->button(0)->setChecked(true); // no diagrams |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
780 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
781 |
m_dotClass->setChecked(getBoolOption(m_modelData,STR_CLASS_GRAPH)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
782 |
m_dotCollaboration->setChecked(getBoolOption(m_modelData,STR_COLLABORATION_GRAPH)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
783 |
m_dotInheritance->setChecked(getBoolOption(m_modelData,STR_GRAPHICAL_HIERARCHY)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
784 |
m_dotInclude->setChecked(getBoolOption(m_modelData,STR_INCLUDE_GRAPH)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
785 |
m_dotIncludedBy->setChecked(getBoolOption(m_modelData,STR_INCLUDED_BY_GRAPH)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
786 |
m_dotCall->setChecked(getBoolOption(m_modelData,STR_CALL_GRAPH)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
787 |
m_dotCaller->setChecked(getBoolOption(m_modelData,STR_CALLER_GRAPH)); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
788 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
789 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
790 |
//========================================================================== |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
791 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
792 |
Wizard::Wizard(const QHash<QString,Input*> &modelData, QWidget *parent) : |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
793 |
QSplitter(parent), m_modelData(modelData) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
794 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
795 |
m_treeWidget = new QTreeWidget; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
796 |
m_treeWidget->setColumnCount(1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
797 |
m_treeWidget->setHeaderLabels(QStringList() << QString::fromAscii("Topics")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
798 |
QList<QTreeWidgetItem*> items; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
799 |
items.append(new QTreeWidgetItem((QTreeWidget*)0,QStringList(tr("Project")))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
800 |
items.append(new QTreeWidgetItem((QTreeWidget*)0,QStringList(tr("Mode")))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
801 |
items.append(new QTreeWidgetItem((QTreeWidget*)0,QStringList(tr("Output")))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
802 |
items.append(new QTreeWidgetItem((QTreeWidget*)0,QStringList(tr("Diagrams")))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
803 |
m_treeWidget->insertTopLevelItems(0,items); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
804 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
805 |
m_topicStack = new QStackedWidget; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
806 |
m_step1 = new Step1(this,modelData); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
807 |
m_step2 = new Step2(this,modelData); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
808 |
m_step3 = new Step3(this,modelData); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
809 |
m_step4 = new Step4(this,modelData); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
810 |
m_topicStack->addWidget(m_step1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
811 |
m_topicStack->addWidget(m_step2); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
812 |
m_topicStack->addWidget(m_step3); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
813 |
m_topicStack->addWidget(m_step4); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
814 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
815 |
QWidget *rightSide = new QWidget; |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
816 |
QGridLayout *grid = new QGridLayout(rightSide); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
817 |
m_prev = new QPushButton(tr("Previous")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
818 |
m_prev->setEnabled(false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
819 |
m_next = new QPushButton(tr("Next")); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
820 |
grid->addWidget(m_topicStack,0,0,1,2); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
821 |
grid->addWidget(m_prev,1,0,Qt::AlignLeft); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
822 |
grid->addWidget(m_next,1,1,Qt::AlignRight); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
823 |
grid->setColumnStretch(0,1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
824 |
grid->setRowStretch(0,1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
825 |
addWidget(m_treeWidget); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
826 |
addWidget(rightSide); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
827 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
828 |
connect(m_treeWidget, |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
829 |
SIGNAL(currentItemChanged(QTreeWidgetItem *,QTreeWidgetItem *)), |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
830 |
SLOT(activateTopic(QTreeWidgetItem *,QTreeWidgetItem *))); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
831 |
connect(m_next,SIGNAL(clicked()),SLOT(nextTopic())); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
832 |
connect(m_prev,SIGNAL(clicked()),SLOT(prevTopic())); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
833 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
834 |
refresh(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
835 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
836 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
837 |
Wizard::~Wizard() |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
838 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
839 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
840 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
841 |
void Wizard::activateTopic(QTreeWidgetItem *item,QTreeWidgetItem *) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
842 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
843 |
if (item) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
844 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
845 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
846 |
QString label = item->text(0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
847 |
if (label==tr("Project")) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
848 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
849 |
m_topicStack->setCurrentWidget(m_step1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
850 |
m_prev->setEnabled(false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
851 |
m_next->setEnabled(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
852 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
853 |
else if (label==tr("Mode")) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
854 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
855 |
m_topicStack->setCurrentWidget(m_step2); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
856 |
m_prev->setEnabled(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
857 |
m_next->setEnabled(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
858 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
859 |
else if (label==tr("Output")) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
860 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
861 |
m_topicStack->setCurrentWidget(m_step3); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
862 |
m_prev->setEnabled(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
863 |
m_next->setEnabled(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
864 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
865 |
else if (label==tr("Diagrams")) |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
866 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
867 |
m_topicStack->setCurrentWidget(m_step4); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
868 |
m_prev->setEnabled(true); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
869 |
m_next->setEnabled(false); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
870 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
871 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
872 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
873 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
874 |
void Wizard::nextTopic() |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
875 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
876 |
m_topicStack->setCurrentIndex(m_topicStack->currentIndex()+1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
877 |
m_next->setEnabled(m_topicStack->count()!=m_topicStack->currentIndex()+1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
878 |
m_prev->setEnabled(m_topicStack->currentIndex()!=0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
879 |
m_treeWidget->setCurrentItem(m_treeWidget->invisibleRootItem()->child(m_topicStack->currentIndex())); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
880 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
881 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
882 |
void Wizard::prevTopic() |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
883 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
884 |
m_topicStack->setCurrentIndex(m_topicStack->currentIndex()-1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
885 |
m_next->setEnabled(m_topicStack->count()!=m_topicStack->currentIndex()+1); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
886 |
m_prev->setEnabled(m_topicStack->currentIndex()!=0); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
887 |
m_treeWidget->setCurrentItem(m_treeWidget->invisibleRootItem()->child(m_topicStack->currentIndex())); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
888 |
} |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
889 |
|
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
890 |
void Wizard::refresh() |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
891 |
{ |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
892 |
m_step1->init(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
893 |
m_step2->init(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
894 |
m_step3->init(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
895 |
m_step4->init(); |
42188c7ea2d9
Initial contribution of ORB delivering Feature bug 1460
szarinda <>
parents:
diff
changeset
|
896 |
} |