Added "folder up" action to the context menu of the "output folder" tab.

This commit is contained in:
LoRd_MuldeR 2012-12-14 23:50:56 +01:00
parent e21c61788e
commit a48dfadc98
16 changed files with 742 additions and 673 deletions

File diff suppressed because it is too large Load Diff

View File

@ -1982,6 +1982,10 @@
<source>Up One Level</source> <source>Up One Level</source>
<translation>Aufwärts</translation> <translation>Aufwärts</translation>
</message> </message>
<message>
<source>Go To Parent Directory</source>
<translation>Zum übergeordneten Verzeichnis wechseln</translation>
</message>
</context> </context>
<context> <context>
<name>MetaInfo</name> <name>MetaInfo</name>

View File

@ -1981,6 +1981,10 @@
<source>Up One Level</source> <source>Up One Level</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>Go To Parent Directory</source>
<translation type="unfinished"></translation>
</message>
</context> </context>
<context> <context>
<name>MetaInfo</name> <name>MetaInfo</name>

View File

@ -1991,6 +1991,10 @@ Ouvrir le dossier récursivement...</translation>
<source>Up One Level</source> <source>Up One Level</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>Go To Parent Directory</source>
<translation type="unfinished"></translation>
</message>
</context> </context>
<context> <context>
<name>MetaInfo</name> <name>MetaInfo</name>

View File

@ -1982,6 +1982,10 @@
<source>Up One Level</source> <source>Up One Level</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>Go To Parent Directory</source>
<translation type="unfinished"></translation>
</message>
</context> </context>
<context> <context>
<name>MetaInfo</name> <name>MetaInfo</name>

View File

@ -1981,6 +1981,10 @@
<source>Up One Level</source> <source>Up One Level</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>Go To Parent Directory</source>
<translation type="unfinished"></translation>
</message>
</context> </context>
<context> <context>
<name>MetaInfo</name> <name>MetaInfo</name>

File diff suppressed because it is too large Load Diff

View File

@ -1987,6 +1987,10 @@
<source>Up One Level</source> <source>Up One Level</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>Go To Parent Directory</source>
<translation type="unfinished"></translation>
</message>
</context> </context>
<context> <context>
<name>MetaInfo</name> <name>MetaInfo</name>

File diff suppressed because it is too large Load Diff

View File

@ -1981,6 +1981,10 @@
<source>Up One Level</source> <source>Up One Level</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>Go To Parent Directory</source>
<translation type="unfinished"></translation>
</message>
</context> </context>
<context> <context>
<name>MetaInfo</name> <name>MetaInfo</name>

View File

@ -1982,6 +1982,10 @@
<source>Up One Level</source> <source>Up One Level</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>Go To Parent Directory</source>
<translation type="unfinished"></translation>
</message>
</context> </context>
<context> <context>
<name>MetaInfo</name> <name>MetaInfo</name>

View File

@ -1981,6 +1981,10 @@
<source>Up One Level</source> <source>Up One Level</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<source>Go To Parent Directory</source>
<translation type="unfinished"></translation>
</message>
</context> </context>
<context> <context>
<name>MetaInfo</name> <name>MetaInfo</name>

Binary file not shown.

View File

@ -30,7 +30,7 @@
#define VER_LAMEXP_MINOR_LO 7 #define VER_LAMEXP_MINOR_LO 7
#define VER_LAMEXP_TYPE Alpha #define VER_LAMEXP_TYPE Alpha
#define VER_LAMEXP_PATCH 6 #define VER_LAMEXP_PATCH 6
#define VER_LAMEXP_BUILD 1217 #define VER_LAMEXP_BUILD 1218
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
// Tool versions (minimum expected versions!) // Tool versions (minimum expected versions!)

View File

@ -271,11 +271,14 @@ MainWindow::MainWindow(FileListModel *fileListModel, AudioFileModel *metaInfo, S
if(m_outputFolderContextMenu = new QMenu()) if(m_outputFolderContextMenu = new QMenu())
{ {
m_showFolderContextAction = m_outputFolderContextMenu->addAction(QIcon(":/icons/zoom.png"), "N/A"); m_showFolderContextAction = m_outputFolderContextMenu->addAction(QIcon(":/icons/zoom.png"), "N/A");
m_goUpFolderContextAction = m_outputFolderContextMenu->addAction(QIcon(":/icons/folder_up.png"), "N/A");
m_outputFolderContextMenu->addSeparator();
m_refreshFolderContextAction = m_outputFolderContextMenu->addAction(QIcon(":/icons/arrow_refresh.png"), "N/A"); m_refreshFolderContextAction = m_outputFolderContextMenu->addAction(QIcon(":/icons/arrow_refresh.png"), "N/A");
m_outputFolderContextMenu->setDefaultAction(m_showFolderContextAction); m_outputFolderContextMenu->setDefaultAction(m_showFolderContextAction);
connect(ui->outputFolderView, SIGNAL(customContextMenuRequested(QPoint)), this, SLOT(outputFolderContextMenu(QPoint))); connect(ui->outputFolderView, SIGNAL(customContextMenuRequested(QPoint)), this, SLOT(outputFolderContextMenu(QPoint)));
connect(m_showFolderContextAction, SIGNAL(triggered(bool)), this, SLOT(showFolderContextActionTriggered())); connect(m_showFolderContextAction, SIGNAL(triggered(bool)), this, SLOT(showFolderContextActionTriggered()));
connect(m_refreshFolderContextAction, SIGNAL(triggered(bool)), this, SLOT(refreshFolderContextActionTriggered())); connect(m_refreshFolderContextAction, SIGNAL(triggered(bool)), this, SLOT(refreshFolderContextActionTriggered()));
connect(m_goUpFolderContextAction, SIGNAL(triggered(bool)), this, SLOT(goUpFolderContextActionTriggered()));
} }
if(m_outputFolderFavoritesMenu = new QMenu()) if(m_outputFolderFavoritesMenu = new QMenu())
@ -977,6 +980,7 @@ void MainWindow::changeEvent(QEvent *e)
m_findFileContextAction->setText(tr("Browse File Location")); m_findFileContextAction->setText(tr("Browse File Location"));
m_showFolderContextAction->setText(tr("Browse Selected Folder")); m_showFolderContextAction->setText(tr("Browse Selected Folder"));
m_refreshFolderContextAction->setText(tr("Refresh Directory Outline")); m_refreshFolderContextAction->setText(tr("Refresh Directory Outline"));
m_goUpFolderContextAction->setText(tr("Go To Parent Directory"));
m_addFavoriteFolderAction->setText(tr("Bookmark Current Output Folder")); m_addFavoriteFolderAction->setText(tr("Bookmark Current Output Folder"));
m_exportCsvContextAction->setText(tr("Export Meta Tags to CSV File")); m_exportCsvContextAction->setText(tr("Export Meta Tags to CSV File"));
m_importCsvContextAction->setText(tr("Import Meta Tags from CSV File")); m_importCsvContextAction->setText(tr("Import Meta Tags from CSV File"));
@ -2845,6 +2849,29 @@ void MainWindow::refreshFolderContextActionTriggered(void)
QTimer::singleShot(0, this, SLOT(initOutputFolderModel())); QTimer::singleShot(0, this, SLOT(initOutputFolderModel()));
} }
/*
* Go one directory up
*/
void MainWindow::goUpFolderContextActionTriggered(void)
{
QModelIndex current = ui->outputFolderView->currentIndex();
if(current.isValid())
{
QModelIndex parent = current.parent();
if(parent.isValid())
{
ui->outputFolderView->setCurrentIndex(parent);
outputFolderViewClicked(parent);
}
else
{
MessageBeep(MB_ICONWARNING);
}
CENTER_CURRENT_OUTPUT_FOLDER_DELAYED;
}
}
/* /*
* Add current folder to favorites * Add current folder to favorites
*/ */
@ -3130,18 +3157,7 @@ void MainWindow::outputFolderMouseEventOccurred(QWidget *sender, QEvent *event)
} }
else if(sender == ui->outputFoldersGoUpLabel) else if(sender == ui->outputFoldersGoUpLabel)
{ {
QModelIndex current = ui->outputFolderView->currentIndex(); QTimer::singleShot(0, this, SLOT(goUpFolderContextActionTriggered()));
if(current.isValid() && current.parent().isValid())
{
QModelIndex parent = current.parent();
ui->outputFolderView->setCurrentIndex(parent);
outputFolderViewClicked(parent);
}
else
{
MessageBeep(MB_ICONWARNING);
}
CENTER_CURRENT_OUTPUT_FOLDER_DELAYED;
} }
else else
{ {

View File

@ -101,6 +101,7 @@ private slots:
void gotoFavoriteFolder(void); void gotoFavoriteFolder(void);
void gotoHomeFolderButtonClicked(void); void gotoHomeFolderButtonClicked(void);
void gotoMusicFolderButtonClicked(void); void gotoMusicFolderButtonClicked(void);
void goUpFolderContextActionTriggered(void);
void handleDelayedFiles(void); void handleDelayedFiles(void);
void hibernateComputerActionTriggered(bool checked); void hibernateComputerActionTriggered(bool checked);
void importCueSheetActionTriggered(bool checked); void importCueSheetActionTriggered(bool checked);
@ -216,6 +217,7 @@ private:
QAction *m_showDetailsContextAction; QAction *m_showDetailsContextAction;
QAction *m_showFolderContextAction; QAction *m_showFolderContextAction;
QAction *m_refreshFolderContextAction; QAction *m_refreshFolderContextAction;
QAction *m_goUpFolderContextAction;
QAction *m_addFavoriteFolderAction; QAction *m_addFavoriteFolderAction;
QAction *m_exportCsvContextAction; QAction *m_exportCsvContextAction;
QAction *m_importCsvContextAction; QAction *m_importCsvContextAction;