-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Temporal layers indicators #34909
Temporal layers indicators #34909
Conversation
4d09e6c
to
ab3b8e9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking close!
Now that QgsTemporalProperty/QgsMapLayerTemporalProperties/QgsRasterLayerTemporalProperties are QObjects, you'll need to ensure these all have the Q_OBJECT macro inclusion, and also accept a parent QObject* argument in their constructors.
Then, we need to make sure that the QgsRasterLayerTemporalProperties are correctly parented to the raster layer when constructed. So in qgsrasterlayer.cpp
mTemporalProperties = qgis::make_unique<QgsRasterLayerTemporalProperties>();
becomes
mTemporalProperties = new QgsRasterLayerTemporalProperties( this );
You'll also need to change
std::unique_ptr< QgsRasterLayerTemporalProperties > mTemporalProperties;
to
QgsRasterLayerTemporalProperties * mTemporalProperties = nullptr;
in the header, since we'll be using Qt's parent memory management instead of c++ unique_ptr
Looks great, thanks! |
Can you rebase this branch off master? There's a merge conflict here. |
d8ccdd0
to
ef3484b
Compare
Sure, done! |
Thanks -- I'll merge as soon as the CI results are green! |
Thanks @nyalldawson |
Adds support for the temporal layers indicators in the Layers panel work tree.
These indicators change depending on from where the current layers temporal range is set from, eg from the project settings or from layer temporal properties options.
This PR contains work from #34590
![Temporal_layer_indicator](https://user-images.githubusercontent.com/2663775/76077526-e986d800-5fb1-11ea-8830-c2bdffe6c694.gif)
Note: This is part of the work from discussions found here and here .