[vlmc-devel] [PATCH] Fix "No such signal" errors

Hugo Beauzée-Luyssen hugo at beauzee.fr
Sun Mar 6 00:02:29 CET 2016


On 03/05/2016 03:45 PM, Yikai Lu wrote:
> Make usage of sinals accord with their definitions.
> ---
>  src/Project/Project.cpp | 2 +-
>  src/Project/Project.h   | 4 ++--
>  2 files changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/src/Project/Project.cpp b/src/Project/Project.cpp
> index af3eeaf..5e374d8 100644
> --- a/src/Project/Project.cpp
> +++ b/src/Project/Project.cpp
> @@ -125,7 +125,7 @@ Project::load( const QString& path )
>      emit cleanStateChanged( m_isClean );
>      if ( autoBackupFound == false )
>          m_projectFile->close();
> -    emit projectLoaded( projectName );
> +    emit projectLoaded( projectName, path );
>      if ( outdatedBackupFound == true )
>          emit outdatedBackupFileFound();
>      if ( autoBackupFound == true )
> diff --git a/src/Project/Project.h b/src/Project/Project.h
> index 0c8b53a..795942e 100644
> --- a/src/Project/Project.h
> +++ b/src/Project/Project.h
> @@ -91,7 +91,7 @@ class Project : public QObject
>           *      - The project name has changed
>           *      - The revision (if activated) has changed
>           */
> -        void                projectUpdated( const QString& projectName );
> +        void                projectUpdated( const QVariant& projectName );

That is correct since the source signal is passing a QVariant indeed,
but then needs to be propagated to the connected slots

>  
>          /**
>           *  \brief      Used to signal that the project has been saved.
> @@ -108,7 +108,7 @@ class Project : public QObject
>          void                cleanStateChanged( bool value );
>  
>          void                projectLoading( const QString& projectName );
> -        void                projectLoaded( const QString& projectName );
> +        void                projectLoaded( const QString& projectName, const QString& projectFile );

The new signature is the one that should be used, however, there are
indeed a few places that I forgot to update. A quick grep yields mostly
the RecentProject class.

>          void                projectClosed();
>          void                backupProjectLoaded();
>          void                outdatedBackupFileFound();
> 

Regards,

-- 
Hugo Beauzée-Luyssen
www.beauzee.fr


More information about the Vlmc-devel mailing list