Please sign in to comment.
Make it possible to skip memory layer check on project close
In QGIS 3.4 there is the new feature that warns users about a potential data loss when closing a project that contains memory layers. It displays the warning: > This project includes one or more temporary scratch layers. > These layers are not saved to disk and their contents will be > permanently lost. Are you sure you want to proceed?" While this is useful in general, there are various cases when this warning is unwanted. For example, when a plugin creates memory layers by extracting data from some custom data format (and possibly also writes changes from temporary layers back to the data storage). In such situations the warning is very confusing for the users who are unaware of the internals. This commit adds a custom property "skipMemoryLayersCheck" to map layers, so if all temporary layers have this property set to non-zero value the warning will not show up. layer.setCustomProperty("skipMemoryLayersCheck", 1)
- Loading branch information