Watching current dir for changes to reload file list
This commit is contained in:
+2
-1
@@ -20,6 +20,7 @@ MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent),
|
||||
|
||||
m_ringList = new ImageRingList(this);
|
||||
connect(m_ringList, SIGNAL(pixmapLoaded(QPixmap)), this, SLOT(pixmapLoaded(QPixmap)));
|
||||
connect(m_ringList, SIGNAL(currentImageChanged()), this, SLOT(updateWindowTitle()));
|
||||
|
||||
QMenu *fileMenu = new QMenu(tr("File"), this);
|
||||
fileMenu->addAction(tr("Open"), this, SLOT(openFile()), QKeySequence("Ctrl+O"));
|
||||
@@ -90,7 +91,7 @@ void MainWindow::openFile()
|
||||
if(standardLocations.size())
|
||||
path = standardLocations.first();
|
||||
|
||||
QString file = QFileDialog::getOpenFileName(this, tr("Open file"), path, tr("Images (*.jpg *.png)"));
|
||||
QString file = QFileDialog::getOpenFileName(this, tr("Open file"), path, tr("Images (*.jpg *.png *.JPG *.PNG)"));
|
||||
if(!file.isEmpty())
|
||||
{
|
||||
QFileInfo info(file);
|
||||
|
||||
Reference in New Issue
Block a user