Skip to content

Commit

Permalink
Silence a clazy warning
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Jun 11, 2018
1 parent 3b89ee0 commit 798408b
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
4 changes: 4 additions & 0 deletions python/core/auto_generated/qgsproject.sip.in
Expand Up @@ -1361,8 +1361,12 @@ Constructor for QgsProjectDirtyBlocker.
This will block dirtying the specified ``project`` for the lifetime of this object.
%End



~QgsProjectDirtyBlocker();

private:
QgsProjectDirtyBlocker( const QgsProjectDirtyBlocker &other );
};


Expand Down
10 changes: 10 additions & 0 deletions src/core/qgsproject.h
Expand Up @@ -1400,13 +1400,23 @@ class CORE_EXPORT QgsProjectDirtyBlocker
mProject->mDirtyBlockCount++;
}

//! QgsProjectDirtyBlocker cannot be copied
QgsProjectDirtyBlocker( const QgsProjectDirtyBlocker &other ) = delete;

//! QgsProjectDirtyBlocker cannot be copied
QgsProjectDirtyBlocker &operator=( const QgsProjectDirtyBlocker &other ) = delete;

~QgsProjectDirtyBlocker()
{
mProject->mDirtyBlockCount--;
}

private:
QgsProject *mProject = nullptr;

#ifdef SIP_RUN
QgsProjectDirtyBlocker( const QgsProjectDirtyBlocker &other );
#endif
};

/**
Expand Down

0 comments on commit 798408b

Please sign in to comment.