Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Multimedia
Kdenlive
Commits
901c3ecf
Commit
901c3ecf
authored
Jan 20, 2017
by
Jean-Baptiste Mardelle
Browse files
Fix extract frame not remembering folder
parent
754b8eee
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/monitor/monitor.cpp
View file @
901c3ecf
...
...
@@ -971,9 +971,9 @@ void Monitor::slotExtractCurrentFrameToProject()
slotExtractCurrentFrame
(
QString
(),
true
);
}
void
Monitor
::
slotExtractCurrentFrame
(
QString
path
,
bool
addToProject
)
void
Monitor
::
slotExtractCurrentFrame
(
QString
frameName
,
bool
addToProject
)
{
if
(
addToProject
&&
QFileInfo
(
path
).
fileName
().
isEmpty
())
{
if
(
addToProject
&&
QFileInfo
(
frameName
).
fileName
().
isEmpty
())
{
// convenience: when extracting an image to be added to the project,
// suggest a suitable image file name. In the project monitor, this
// suggestion bases on the project file name; in the clip monitor,
...
...
@@ -989,7 +989,7 @@ void Monitor::slotExtractCurrentFrame(QString path, bool addToProject)
+
QStringLiteral
(
"-f"
)
+
QString
::
number
(
render
->
seekFramePosition
())
+
".png"
;
path
=
QFileInfo
(
path
,
suggestedImageName
).
absoluteFilePath
();
frameName
=
QFileInfo
(
frameName
,
suggestedImageName
).
fileName
();
}
QString
framesFolder
=
KRecentDirs
::
dir
(
":KdenliveFramesFolder"
);
...
...
@@ -998,7 +998,7 @@ void Monitor::slotExtractCurrentFrame(QString path, bool addToProject)
fs
->
setMimeTypeFilters
(
QStringList
()
<<
QStringLiteral
(
"image/png"
));
fs
->
setAcceptMode
(
QFileDialog
::
AcceptSave
);
fs
->
setDefaultSuffix
(
QStringLiteral
(
"png"
));
fs
->
selectFile
(
path
);
fs
->
selectFile
(
frameName
);
if
(
fs
->
exec
())
{
if
(
!
fs
->
selectedFiles
().
isEmpty
())
{
QUrl
savePath
=
fs
->
selectedUrls
().
first
();
...
...
src/monitor/monitor.h
View file @
901c3ecf
...
...
@@ -241,7 +241,7 @@ private:
private
slots
:
void
seekCursor
(
int
pos
);
void
rendererStopped
(
int
pos
);
void
slotExtractCurrentFrame
(
QString
path
=
QString
(),
bool
addToProject
=
false
);
void
slotExtractCurrentFrame
(
QString
frameName
=
QString
(),
bool
addToProject
=
false
);
void
slotExtractCurrentFrameToProject
();
void
slotSetThumbFrame
();
void
slotSaveZone
();
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment