From: <su...@us...> - 2007-09-26 13:49:15
|
Revision: 2170 http://tora.svn.sourceforge.net/tora/?rev=2170&view=rev Author: subik Date: 2007-09-26 06:49:10 -0700 (Wed, 26 Sep 2007) Log Message: ----------- qt4 progress Modified Paths: -------------- branches/tora-1.4/tora/src/tosgatrace.cpp branches/tora-1.4/tora/src/tosplash.cpp branches/tora-1.4/tora/src/tosql.cpp branches/tora-1.4/tora/src/tostorage.cpp branches/tora-1.4/tora/src/tostorage.h branches/tora-1.4/tora/src/tostoragedefinition.cpp branches/tora-1.4/tora/src/tostoragedefinition.h branches/tora-1.4/tora/src/tosyntaxsetup.cpp branches/tora-1.4/tora/src/tosyntaxsetup.h Modified: branches/tora-1.4/tora/src/tosgatrace.cpp =================================================================== --- branches/tora-1.4/tora/src/tosgatrace.cpp 2007-09-26 13:28:19 UTC (rev 2169) +++ branches/tora-1.4/tora/src/tosgatrace.cpp 2007-09-26 13:49:10 UTC (rev 2170) @@ -180,7 +180,7 @@ toolbar->setStretchableWidget(new QLabel(toolbar, TO_TOOLBAR_WIDGET_NAME)); new toChangeConnection(toolbar, TO_TOOLBAR_WIDGET_NAME); - QSplitter *splitter = new QSplitter(Vertical, this); + QSplitter *splitter = new QSplitter(Qt::Vertical, this); Trace = new toResultLong(false, false, toQuery::Background, splitter); Modified: branches/tora-1.4/tora/src/tosplash.cpp =================================================================== --- branches/tora-1.4/tora/src/tosplash.cpp 2007-09-26 13:28:19 UTC (rev 2169) +++ branches/tora-1.4/tora/src/tosplash.cpp 2007-09-26 13:49:10 UTC (rev 2170) @@ -41,6 +41,8 @@ #include <qlabel.h> #include <qapplication.h> #include <q3progressbar.h> +#include <Q3MimeSourceFactory> +#include <QDesktopWidget> #include "icons/largelogo.xpm" @@ -50,15 +52,15 @@ Q3MimeSourceFactory::defaultFactory()->setPixmap(QString::fromLatin1("largelogo.xpm"), QPixmap(const_cast<const char**>(largelogo_xpm))); - setBackgroundColor(white); + setBackgroundColor(Qt::white); QLabel *logo = new QLabel(this, "Logo"); - logo->setBackgroundColor(white); + logo->setBackgroundColor(Qt::white); logo->setPixmap(QPixmap(const_cast<const char**>(largelogo_xpm))); Label = new QLabel(tr("Loading plugins"), this); - Label->setBackgroundColor(white); + Label->setBackgroundColor(Qt::white); Progress = new Q3ProgressBar(this, "Progress"); - QWidget *d = QApplication::desktop(); + QDesktopWidget *d = QApplication::desktop(); move((d->width() - width()) / 2, (d->height() - height()) / 2); } Modified: branches/tora-1.4/tora/src/tosql.cpp =================================================================== --- branches/tora-1.4/tora/src/tosql.cpp 2007-09-26 13:28:19 UTC (rev 2169) +++ branches/tora-1.4/tora/src/tosql.cpp 2007-09-26 13:49:10 UTC (rev 2170) @@ -185,7 +185,7 @@ sqlMap::iterator i = Definitions->find(name); if (i != Definitions->end()) return name; - throw qApp->translate("toSQL", "Tried to get unknown SQL (%1)").arg(name); + throw qApp->translate("toSQL", "Tried to get unknown SQL (%1)").arg(QString(name)); } QString toSQL::string(const Q3CString &name, @@ -226,7 +226,7 @@ while (!quit); } - throw qApp->translate("toSQL", "Tried to get unknown SQL (%1)").arg(name); + throw qApp->translate("toSQL", "Tried to get unknown SQL (%1)").arg(QString(name)); } bool toSQL::saveSQL(const QString &filename, bool all) @@ -398,5 +398,5 @@ sqlMap::iterator i = Definitions->find(name); if (i != Definitions->end()) return (*i).second.Description; - throw qApp->translate("toSQL", "Tried to get unknown SQL (%1)").arg(name); + throw qApp->translate("toSQL", "Tried to get unknown SQL (%1)").arg(QString(name)); } Modified: branches/tora-1.4/tora/src/tostorage.cpp =================================================================== --- branches/tora-1.4/tora/src/tostorage.cpp 2007-09-26 13:28:19 UTC (rev 2169) +++ branches/tora-1.4/tora/src/tostorage.cpp 2007-09-26 13:49:10 UTC (rev 2170) @@ -102,7 +102,7 @@ #define CONF_DISP_EXTENTS "DispExtents" #define CONF_DISP_AVAILABLEGRAPH "AvailableGraph" -class toStoragePrefs : public toStoragePrefsUI, public toSettingTab +class toStoragePrefs : public QWidget, public Ui::toStoragePrefsUI, public toSettingTab { toTool *Tool; @@ -112,8 +112,10 @@ }; toStoragePrefs::toStoragePrefs(toTool *tool, QWidget* parent, const char* name) - : toStoragePrefsUI(parent, name), toSettingTab("storage.html"), Tool(tool) + : QWidget(parent), toSettingTab("storage.html"), Tool(tool) { + setupUi(this); + DispCoalesced->setChecked(!tool->config(CONF_DISP_COALESCED, "").isEmpty()); DispExtents->setChecked(!tool->config(CONF_DISP_EXTENTS, "").isEmpty()); DispTablespaces->setChecked(!tool->config(CONF_DISP_TABLESPACES, "Yes").isEmpty()); @@ -155,8 +157,9 @@ }; toDropTablespace::toDropTablespace(QWidget* parent, const char* name, Qt::WFlags fl) - : toDropTablespaceUI(parent, name, fl) + : QWidget(parent)//, name, fl) { + setupUi(this); if (!name) setName("toDropTablespace"); } @@ -177,8 +180,9 @@ toStorageTablespace::toStorageTablespace(QWidget* parent, const char* name, Qt::WFlags fl) - : toStorageTablespaceUI(parent, name, fl) + : QWidget(parent)//, name, fl) { + setupUi(this); Modify = false; if (!name) setName("toStorageTablespace"); @@ -288,8 +292,11 @@ } toStorageDatafile::toStorageDatafile(bool temp, bool dispName, QWidget* parent, const char* name, Qt::WFlags fl) - : toStorageDatafileUI(parent, name, fl), Tempfile(temp) + : QWidget(parent),//, name, fl), + Tempfile(temp) { + setupUi(this); + Modify = false; InitialSizeOrig = NextSizeOrig = MaximumSizeOrig = 0; @@ -449,8 +456,10 @@ "must have same columns and bindings"); toStorageDialog::toStorageDialog(const QString &tablespace, QWidget *parent, bool drop) - : toStorageDialogUI(parent, "Storage Dialog", true) + : QDialog(parent)//, "Storage Dialog", true) { + setupUi(this); + Setup(); OkButton->setEnabled(false); @@ -508,12 +517,14 @@ connect(Tablespace, SIGNAL(tempFile(bool)), Datafile, SLOT(setTempFile(bool))); connect(Datafile, SIGNAL(validContent(bool)), this, SLOT(validContent(bool))); } - + } toStorageDialog::toStorageDialog(toConnection &conn, const QString &tablespace, QWidget *parent) - : toStorageDialogUI(parent, "Storage Dialog", true) + : QDialog(parent)//, "Storage Dialog", true) { + setupUi(this); + Setup(); try { @@ -595,8 +606,10 @@ toStorageDialog::toStorageDialog(toConnection &conn, const QString &tablespace, const QString &filename, QWidget *parent) - : toStorageDialogUI(parent, "Storage Dialog", true) + : QDialog(parent)//, "Storage Dialog", true) { + setupUi(this); + Setup(); try { @@ -914,18 +927,18 @@ toolbar->setStretchableWidget(new QLabel(toolbar, TO_TOOLBAR_WIDGET_NAME)); new toChangeConnection(toolbar, TO_TOOLBAR_WIDGET_NAME); - QSplitter *splitter = new QSplitter(Vertical, this); + QSplitter *splitter = new QSplitter(Qt::Vertical, this); Storage = new toResultStorage(!StorageTool.config(CONF_DISP_AVAILABLEGRAPH, "Yes").isEmpty(), splitter); - ExtentParent = new QSplitter(Horizontal, splitter); + ExtentParent = new QSplitter(Qt::Horizontal, splitter); Objects = new toListView(ExtentParent); Objects->addColumn(tr("Owner")); Objects->addColumn(tr("Object")); Objects->addColumn(tr("Partition")); Objects->addColumn(tr("Extents")); Objects->addColumn(tr("Blocks")); - Objects->setColumnAlignment(3, AlignRight); - Objects->setColumnAlignment(4, AlignRight); + Objects->setColumnAlignment(3, Qt::AlignRight); + Objects->setColumnAlignment(4, Qt::AlignRight); Objects->setSorting(0); Objects->setShowSortIndicator(TRUE); Modified: branches/tora-1.4/tora/src/tostorage.h =================================================================== --- branches/tora-1.4/tora/src/tostorage.h 2007-09-26 13:28:19 UTC (rev 2169) +++ branches/tora-1.4/tora/src/tostorage.h 2007-09-26 13:49:10 UTC (rev 2170) @@ -69,7 +69,7 @@ class toStorageDefinition; class toStorageDialog; -class toStorageTablespace : public toStorageTablespaceUI +class toStorageTablespace : public QWidget, public Ui::toStorageTablespaceUI { Q_OBJECT @@ -96,7 +96,7 @@ virtual void allowDefault(bool); }; -class toDropTablespace : public toDropTablespaceUI +class toDropTablespace : public QWidget, public Ui::toDropTablespaceUI { Q_OBJECT public: @@ -106,7 +106,7 @@ void validContent(bool); }; -class toStorageDatafile : public toStorageDatafileUI +class toStorageDatafile : public QWidget, public Ui::toStorageDatafileUI { Q_OBJECT @@ -140,7 +140,7 @@ virtual void valueChanged(const QString &); }; -class toStorageDialog : public toStorageDialogUI +class toStorageDialog : public QDialog, public Ui::toStorageDialogUI { Q_OBJECT enum { Modified: branches/tora-1.4/tora/src/tostoragedefinition.cpp =================================================================== --- branches/tora-1.4/tora/src/tostoragedefinition.cpp 2007-09-26 13:28:19 UTC (rev 2169) +++ branches/tora-1.4/tora/src/tostoragedefinition.cpp 2007-09-26 13:49:10 UTC (rev 2170) @@ -49,8 +49,10 @@ // #include "tostoragedefinitionui.moc" toStorageDefinition::toStorageDefinition(QWidget* parent, const char* name, Qt::WFlags fl) - : toStorageDefinitionUI(parent, name, fl) + : QWidget(parent)//, name, fl) { + setupUi(this); + InitialSize->setTitle(tr("&Initial size")); InitialSize->setValue(50); Modified: branches/tora-1.4/tora/src/tostoragedefinition.h =================================================================== --- branches/tora-1.4/tora/src/tostoragedefinition.h 2007-09-26 13:28:19 UTC (rev 2169) +++ branches/tora-1.4/tora/src/tostoragedefinition.h 2007-09-26 13:49:10 UTC (rev 2170) @@ -57,7 +57,7 @@ class toFilesize; class toStorageDialog; -class toStorageDefinition : public toStorageDefinitionUI +class toStorageDefinition : public QWidget, public Ui::toStorageDefinitionUI { public: toStorageDefinition(QWidget *parent = 0, const char *name = 0, Qt::WFlags fl = 0); Modified: branches/tora-1.4/tora/src/tosyntaxsetup.cpp =================================================================== --- branches/tora-1.4/tora/src/tosyntaxsetup.cpp 2007-09-26 13:28:19 UTC (rev 2169) +++ branches/tora-1.4/tora/src/tosyntaxsetup.cpp 2007-09-26 13:49:10 UTC (rev 2170) @@ -61,9 +61,10 @@ // #include "tosyntaxsetupui.moc" toSyntaxSetup::toSyntaxSetup(QWidget *parent, const char *name, Qt::WFlags fl) - : toSyntaxSetupUI(parent, name, fl), toSettingTab("fonts.html"), + : QWidget(parent), toSettingTab("fonts.html"), Analyzer(toSyntaxAnalyzer::defaultAnalyzer()) { + setupUi(this); KeywordUpper->setChecked(!toConfigurationSingle::Instance().globalConfig(CONF_KEYWORD_UPPER, DEFAULT_KEYWORD_UPPER).isEmpty()); SyntaxHighlighting->setChecked(!toConfigurationSingle::Instance().globalConfig(CONF_HIGHLIGHT, "Yes").isEmpty()); CodeCompletion->setChecked(!toConfigurationSingle::Instance().globalConfig(CONF_CODE_COMPLETION, "Yes").isEmpty()); Modified: branches/tora-1.4/tora/src/tosyntaxsetup.h =================================================================== --- branches/tora-1.4/tora/src/tosyntaxsetup.h 2007-09-26 13:28:19 UTC (rev 2169) +++ branches/tora-1.4/tora/src/tosyntaxsetup.h 2007-09-26 13:49:10 UTC (rev 2170) @@ -50,7 +50,7 @@ class QFont; -class toSyntaxSetup : public toSyntaxSetupUI, public toSettingTab +class toSyntaxSetup : public QWidget, public Ui::toSyntaxSetupUI, public toSettingTab { Q_OBJECT This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |