-
Notifications
You must be signed in to change notification settings - Fork 276
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
Add file extension automatically for record plugin #303
Add file extension automatically for record plugin #303
Conversation
Signed-off-by: John Shepherd <[email protected]>
Codecov Report
@@ Coverage Diff @@
## ign-gazebo2 #303 +/- ##
================================================
+ Coverage 53.78% 78.05% +24.26%
================================================
Files 121 183 +62
Lines 5838 10029 +4191
================================================
+ Hits 3140 7828 +4688
+ Misses 2698 2201 -497
Continue to review full report at Codecov.
|
As an alternative to this logic, the save dialog also has a property https://doc.qt.io/qt-5/qml-qtquick-dialogs-filedialog.html#defaultSuffix-prop |
Thanks I'll check this out and see if I can condense the logic |
The might fix the case where the user enters the extension in the file dialog box, which results in |
I initially implemented this logic then hesitated. The condition that QML specifies for the I feel if we went this route we would want to compare the entered user extension to the user chosen video type in order to ensure a correct video extension. I realized this logic could become a lot more complicated than needed, and may introduce unexpected or undesired behavior (modifying the user entered extension, which I guess leads to how much we want to trust the user with what they're doing). All of this is why I simply went with appending the initially chosen video format. What do you think would be the best route here? @nkoenig |
Don't think we'll be able to do this, |
I think most applications will use whatever extension is specified, or automatically add an extension. Examples:
|
Signed-off-by: John Shepherd <[email protected]>
Implementation added, ready for another pass. |
Signed-off-by: John Shepherd <[email protected]> Co-authored-by: Louise Poubel <[email protected]> Co-authored-by: Nate Koenig <[email protected]> Signed-off-by: Guillaume Doisy <[email protected]>
This PR automatically adds the user selected file extension to the file name entered by the user, so that they do not have to manually add the extension themselves.
Closes osrf/subt#362
Signed-off-by: John Shepherd [email protected]