GUI: Fix opening error item with default app.
This commit is contained in:
parent
085034ddf7
commit
e6e616e542
|
@ -564,6 +564,9 @@ void ResultsTree::StartApplication(QStandardItem *target, int application)
|
|||
return;
|
||||
}
|
||||
|
||||
if (application == -1)
|
||||
application = mApplications->GetDefaultApplication();
|
||||
|
||||
if (target && application >= 0 && application < mApplications->GetApplicationCount() && target->parent())
|
||||
{
|
||||
// Make sure we are working with the first column
|
||||
|
@ -704,7 +707,7 @@ void ResultsTree::Context(int application)
|
|||
|
||||
void ResultsTree::QuickStartApplication(const QModelIndex &index)
|
||||
{
|
||||
StartApplication(mModel.itemFromIndex(index), 0);
|
||||
StartApplication(mModel.itemFromIndex(index));
|
||||
}
|
||||
|
||||
void ResultsTree::CopyPath(QStandardItem *target, bool fullPath)
|
||||
|
|
|
@ -238,9 +238,10 @@ protected:
|
|||
* @brief Helper function to open an error within target with application*
|
||||
*
|
||||
* @param target Error tree item to open
|
||||
* @param application Index of the application to open with
|
||||
* @param application Index of the application to open with. Giving -1
|
||||
* (default value) will open the default application.
|
||||
*/
|
||||
void StartApplication(QStandardItem *target, int application);
|
||||
void StartApplication(QStandardItem *target, int application = -1);
|
||||
|
||||
/**
|
||||
* @brief Helper function to copy filename/full path to the clipboard
|
||||
|
|
Loading…
Reference in New Issue