Commit e123fc1e authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Qt: try to make the advanced open dialog more usable for files (who the H......

Qt: try to make the advanced open dialog more usable for files (who the H... uses files nowadays ;) )
parent be7fb988
......@@ -135,6 +135,7 @@ FileOpenPanel::FileOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
/* Connects */
BUTTONACT( ui.fileBrowseButton, browseFile() );
BUTTONACT( ui.delFileButton, deleteFile() );
BUTTONACT( ui.subBrowseButton, browseFileSub() );
CONNECT( ui.subCheckBox, toggled( bool ), this, toggleSubtitleFrame( bool ) );
......@@ -161,6 +162,18 @@ void FileOpenPanel::browseFile()
updateMRL();
}
void FileOpenPanel::deleteFile()
{
int i = ui.fileListWidg->currentRow();
if( i != -1 )
{
QListWidgetItem *temp = ui.fileListWidg->takeItem( i );
delete temp;
}
updateMRL();
}
/* Show a fileBrowser to select a subtitle */
void FileOpenPanel::browseFileSub()
{
......
......@@ -110,6 +110,7 @@ public slots:
private slots:
void browseFileSub();
void browseFile();
void deleteFile();
void toggleSubtitleFrame( bool );
};
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment