[Kst] branches/work/kst/portto4/kst/src
Barth Netterfield
netterfield at astro.utoronto.ca
Thu Dec 10 15:52:55 CET 2009
SVN commit 1061045 by netterfield:
-Fix a big in file requester
-Fix command line and reading files with new update system
-Fix creating PSDs from the command line from dirfiles
M +0 -1 libkst/datasourcefactory.cpp
M +0 -1 libkst/updatemanager.cpp
M +2 -2 libkstapp/application.cpp
M +1 -2 libkstapp/commandlineparser.cpp
M +1 -0 libkstapp/document.cpp
M +1 -1 libkstapp/mainwindow.cpp
M +6 -1 widgets/filerequester.cpp
M +1 -0 widgets/filerequester.h
--- branches/work/kst/portto4/kst/src/libkst/datasourcefactory.cpp #1061044:1061045
@@ -55,7 +55,6 @@
if (!factories) {
return 0;
}
-
DataSourceFactory *f = factories->value(stream.name().toString());
if (!f) {
return 0;
--- branches/work/kst/portto4/kst/src/libkst/updatemanager.cpp #1061044:1061045
@@ -68,7 +68,6 @@
}
void UpdateManager::doUpdates(bool forceImmediate) {
-
if (!_store) {
return;
}
--- branches/work/kst/portto4/kst/src/libkstapp/application.cpp #1061044:1061045
@@ -48,8 +48,8 @@
DialogLauncher::replaceSelf(new DialogLauncherGui);
connect(this, SIGNAL(aboutToQuit()), _mainWindow, SLOT(aboutToQuit()));
-
- //_mainWindow->show();
+ _mainWindow->show();
+ _mainWindow->hide();
}
--- branches/work/kst/portto4/kst/src/libkstapp/commandlineparser.cpp #1061044:1061045
@@ -432,7 +432,7 @@
for (int i_file=0; i_file<_fileNames.size(); i_file++) {
QString file = _fileNames.at(i_file);
QFileInfo info(file);
- if (!info.exists() || !info.isFile()) {
+ if (!info.exists()) {
printUsage(i18n("file %1 does not exist\n").arg(file));
*ok = false;
break;
@@ -545,7 +545,6 @@
}
_fileNames.append(arg);
}
- UpdateManager::self()->doUpdates(true);
}
UpdateManager::self()->doUpdates(true);
return (dataPlotted);
--- branches/work/kst/portto4/kst/src/libkstapp/document.cpp #1061044:1061045
@@ -315,6 +315,7 @@
_win->tabWidget()->setCurrentIndex(0);
_win->tabWidget()->closeCurrentView();
+ UpdateManager::self()->doUpdates(true);
return _isOpen = true;
}
--- branches/work/kst/portto4/kst/src/libkstapp/mainwindow.cpp #1061044:1061045
@@ -88,13 +88,13 @@
createStatusBar();
_tabWidget->createView();
+
setCentralWidget(_tabWidget);
connect(_tabWidget, SIGNAL(currentChanged(int)), this, SLOT(currentViewChanged()));
connect(PlotItemManager::self(), SIGNAL(tiedZoomRemoved()), this, SLOT(tiedZoomRemoved()));
connect(PlotItemManager::self(), SIGNAL(allPlotsTiedZoom()), this, SLOT(allPlotsTiedZoom()));
readSettings();
-
connect(UpdateManager::self(), SIGNAL(objectsUpdated(qint64)), this, SLOT(updateViewItems(qint64)));
QTimer::singleShot(0, this, SLOT(performHeavyStartupActions()));
--- branches/work/kst/portto4/kst/src/widgets/filerequester.cpp #1061044:1061045
@@ -48,7 +48,7 @@
_fileButton->setFixedSize(size + 8, size + 8);
setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Fixed);
- connect (_fileEdit, SIGNAL(textChanged(const QString &)), this, SLOT(setFile(const QString &)));
+ connect (_fileEdit, SIGNAL(textChanged(const QString &)), this, SLOT(updateFile(const QString &)));
connect (_fileButton, SIGNAL(clicked()), this, SLOT(chooseFile()));
QDirModel *dirModel = new QDirModel(this);
@@ -75,7 +75,12 @@
emit changed(file);
}
+void FileRequester::updateFile(const QString &file) {
+ _file = file;
+ emit changed(file);
+}
+
void FileRequester::chooseFile() {
QString file;
if (_mode == QFileDialog::ExistingFile) {
--- branches/work/kst/portto4/kst/src/widgets/filerequester.h #1061044:1061045
@@ -35,6 +35,7 @@
public Q_SLOTS:
void setFile(const QString &file);
+ void updateFile(const QString &file);
Q_SIGNALS:
void changed(const QString &file);
More information about the Kst
mailing list