forked from qt-creator/qt-creator
VCS/Diff editors: Set readonly attributes correctly.
Make VCS-generated editors read-only, enable editing when opening a patch. Make VCS-Editor non-read-only by default, add setter for "Forced read-only" that makes it a temporary, read-only file. Task-number: QTCREATORBUG-1528 Reviewed-by: Thorbjorn Lindeijer <thorbjorn.lindeijer@nokia.com>
This commit is contained in:
@@ -105,6 +105,13 @@ public:
|
||||
|
||||
virtual ~VCSBaseEditor();
|
||||
|
||||
/* Force read-only: Make it a read-only, temporary file.
|
||||
* Should be set to true by version control views. It is not on
|
||||
* by default since it should not trigger when patches are opened as
|
||||
* files. */
|
||||
void setForceReadOnly(bool b);
|
||||
bool isForceReadOnly() const;
|
||||
|
||||
QString source() const;
|
||||
void setSource(const QString &source);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user