[vlmc-devel] [PATCH 1/2] ProjectWizard: Don't fake RecentProjects when a project is supposed to be opend

Hugo Beauzée-Luyssen hugo at beauzee.fr
Tue Apr 12 15:30:01 CEST 2016


On 04/11/2016 10:55 AM, Yikai Lu wrote:
> ---
>   src/Gui/wizard/WelcomePage.cpp | 19 -------------------
>   1 file changed, 19 deletions(-)
>
> diff --git a/src/Gui/wizard/WelcomePage.cpp b/src/Gui/wizard/WelcomePage.cpp
> index 6e44cb8..7767a55 100644
> --- a/src/Gui/wizard/WelcomePage.cpp
> +++ b/src/Gui/wizard/WelcomePage.cpp
> @@ -146,27 +146,8 @@ WelcomePage::loadProject()
>           return;
>       }
>
> -    // Search if the item is already in the list
> -    QListWidgetItem* item = nullptr;
> -    for ( int i = 0; i < m_ui.projectsListWidget->count(); ++i )
> -    {
> -        item = m_ui.projectsListWidget->item( i );
> -        if ( item->data( FilePath ).toString().contains( projectPath ) )
> -            break;
> -        item = nullptr;
> -    }
> -
> -    // Item not in list, insert it temporarily
> -    if ( !item )
> -    {
> -        QFileInfo fi( projectPath );
> -        item = new QListWidgetItem( fi.fileName() );
> -        item->setData( FilePath, fi.absoluteFilePath() );
>
> -        m_ui.projectsListWidget->addItem( item );
> -    }
>
> -    item->setSelected( true );
>       selectOpenRadio();
>   }
>
>
Both applied, thanks!


More information about the Vlmc-devel mailing list