Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Kdenlive
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
259
Issues
259
List
Boards
Labels
Service Desk
Milestones
Merge Requests
14
Merge Requests
14
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Multimedia
Kdenlive
Commits
3b9d8bfd
Commit
3b9d8bfd
authored
Jul 22, 2020
by
Vincent Pinon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Manually fix clazy warnings
parent
d265f635
Pipeline
#28060
passed with stage
in 16 minutes and 9 seconds
Changes
113
Pipelines
1
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
113 changed files
with
399 additions
and
425 deletions
+399
-425
renderer/kdenlive_render.cpp
renderer/kdenlive_render.cpp
+1
-2
src/assets/assetpanel.cpp
src/assets/assetpanel.cpp
+5
-5
src/assets/keyframes/model/corners/cornershelper.cpp
src/assets/keyframes/model/corners/cornershelper.cpp
+0
-1
src/assets/keyframes/model/keyframemodel.cpp
src/assets/keyframes/model/keyframemodel.cpp
+0
-1
src/assets/model/assetparametermodel.cpp
src/assets/model/assetparametermodel.cpp
+1
-1
src/assets/view/assetparameterview.cpp
src/assets/view/assetparameterview.cpp
+3
-3
src/assets/view/assetparameterview.hpp
src/assets/view/assetparameterview.hpp
+3
-1
src/assets/view/widgets/boolparamwidget.cpp
src/assets/view/widgets/boolparamwidget.cpp
+1
-1
src/assets/view/widgets/buttonparamwidget.cpp
src/assets/view/widgets/buttonparamwidget.cpp
+2
-2
src/assets/view/widgets/clickablelabelwidget.cpp
src/assets/view/widgets/clickablelabelwidget.cpp
+2
-3
src/assets/view/widgets/colorwheel.cpp
src/assets/view/widgets/colorwheel.cpp
+4
-5
src/assets/view/widgets/doubleparamwidget.cpp
src/assets/view/widgets/doubleparamwidget.cpp
+1
-1
src/assets/view/widgets/fontparamwidget.cpp
src/assets/view/widgets/fontparamwidget.cpp
+1
-1
src/assets/view/widgets/geometryeditwidget.cpp
src/assets/view/widgets/geometryeditwidget.cpp
+1
-1
src/assets/view/widgets/keyframeimport.cpp
src/assets/view/widgets/keyframeimport.cpp
+0
-1
src/assets/view/widgets/keyframewidget.cpp
src/assets/view/widgets/keyframewidget.cpp
+9
-9
src/assets/view/widgets/keywordparamwidget.cpp
src/assets/view/widgets/keywordparamwidget.cpp
+2
-3
src/assets/view/widgets/listparamwidget.cpp
src/assets/view/widgets/listparamwidget.cpp
+1
-2
src/assets/view/widgets/positioneditwidget.cpp
src/assets/view/widgets/positioneditwidget.cpp
+1
-1
src/assets/view/widgets/slidewidget.cpp
src/assets/view/widgets/slidewidget.cpp
+0
-1
src/assets/view/widgets/switchparamwidget.cpp
src/assets/view/widgets/switchparamwidget.cpp
+1
-2
src/assets/view/widgets/urlparamwidget.cpp
src/assets/view/widgets/urlparamwidget.cpp
+1
-2
src/audiomixer/mixermanager.cpp
src/audiomixer/mixermanager.cpp
+4
-4
src/audiomixer/mixerwidget.cpp
src/audiomixer/mixerwidget.cpp
+12
-13
src/bin/bin.cpp
src/bin/bin.cpp
+13
-13
src/bin/bin.h
src/bin/bin.h
+6
-5
src/bin/clipcreator.cpp
src/bin/clipcreator.cpp
+0
-1
src/bin/generators/generators.cpp
src/bin/generators/generators.cpp
+1
-2
src/bin/projectclip.cpp
src/bin/projectclip.cpp
+18
-18
src/bin/projectitemmodel.cpp
src/bin/projectitemmodel.cpp
+8
-8
src/bin/projectitemmodel.h
src/bin/projectitemmodel.h
+3
-2
src/bin/projectsubclip.cpp
src/bin/projectsubclip.cpp
+1
-1
src/bin/tagwidget.cpp
src/bin/tagwidget.cpp
+2
-2
src/capture/mediacapture.cpp
src/capture/mediacapture.cpp
+2
-2
src/capture/mltdevicecapture.cpp
src/capture/mltdevicecapture.cpp
+0
-1
src/core.cpp
src/core.cpp
+8
-8
src/dialogs/clipcreationdialog.cpp
src/dialogs/clipcreationdialog.cpp
+1
-1
src/dialogs/kdenlivesettingsdialog.cpp
src/dialogs/kdenlivesettingsdialog.cpp
+7
-7
src/dialogs/profilesdialog.cpp
src/dialogs/profilesdialog.cpp
+1
-1
src/dialogs/renderwidget.cpp
src/dialogs/renderwidget.cpp
+7
-7
src/dialogs/wizard.cpp
src/dialogs/wizard.cpp
+1
-1
src/doc/documentchecker.cpp
src/doc/documentchecker.cpp
+0
-2
src/doc/documentchecker.h
src/doc/documentchecker.h
+1
-1
src/doc/documentvalidator.cpp
src/doc/documentvalidator.cpp
+1
-1
src/doc/kdenlivedoc.cpp
src/doc/kdenlivedoc.cpp
+3
-4
src/effects/effectlist/view/effectlistwidget.cpp
src/effects/effectlist/view/effectlistwidget.cpp
+1
-1
src/effects/effectstack/model/effectitemmodel.cpp
src/effects/effectstack/model/effectitemmodel.cpp
+1
-1
src/effects/effectstack/model/effectstackmodel.cpp
src/effects/effectstack/model/effectstackmodel.cpp
+4
-4
src/effects/effectstack/view/builtstack.cpp
src/effects/effectstack/view/builtstack.cpp
+1
-1
src/effects/effectstack/view/collapsibleeffectview.cpp
src/effects/effectstack/view/collapsibleeffectview.cpp
+5
-6
src/effects/effectstack/view/effectstackview.cpp
src/effects/effectstack/view/effectstackview.cpp
+3
-3
src/jobs/audiothumbjob.cpp
src/jobs/audiothumbjob.cpp
+5
-5
src/jobs/cutclipjob.cpp
src/jobs/cutclipjob.cpp
+1
-1
src/jobs/jobmanager.cpp
src/jobs/jobmanager.cpp
+6
-6
src/jobs/loadjob.cpp
src/jobs/loadjob.cpp
+2
-2
src/jobs/meltjob.cpp
src/jobs/meltjob.cpp
+1
-1
src/jobs/scenesplitjob.cpp
src/jobs/scenesplitjob.cpp
+1
-2
src/jobs/speedjob.cpp
src/jobs/speedjob.cpp
+2
-2
src/jobs/stabilizejob.cpp
src/jobs/stabilizejob.cpp
+1
-1
src/jogshuttle/jogshuttleconfig.cpp
src/jogshuttle/jogshuttleconfig.cpp
+2
-2
src/layoutmanagement.cpp
src/layoutmanagement.cpp
+1
-1
src/lib/audio/audioEnvelope.cpp
src/lib/audio/audioEnvelope.cpp
+1
-1
src/lib/localeHandling.cpp
src/lib/localeHandling.cpp
+0
-1
src/library/librarywidget.cpp
src/library/librarywidget.cpp
+1
-1
src/mainwindow.cpp
src/mainwindow.cpp
+38
-42
src/mltconnection.cpp
src/mltconnection.cpp
+1
-1
src/mltcontroller/clippropertiescontroller.cpp
src/mltcontroller/clippropertiescontroller.cpp
+17
-17
src/monitor/glwidget.cpp
src/monitor/glwidget.cpp
+2
-2
src/monitor/monitor.cpp
src/monitor/monitor.cpp
+22
-22
src/monitor/monitor.h
src/monitor/monitor.h
+1
-1
src/monitor/monitormanager.cpp
src/monitor/monitormanager.cpp
+4
-4
src/monitor/monitormanager.h
src/monitor/monitormanager.h
+1
-1
src/monitor/monitorproxy.cpp
src/monitor/monitorproxy.cpp
+1
-1
src/monitor/recmanager.cpp
src/monitor/recmanager.cpp
+1
-1
src/monitor/scopes/audiographspectrum.cpp
src/monitor/scopes/audiographspectrum.cpp
+1
-1
src/monitor/scopes/monitoraudiolevel.cpp
src/monitor/scopes/monitoraudiolevel.cpp
+1
-1
src/project/dialogs/archivewidget.cpp
src/project/dialogs/archivewidget.cpp
+3
-3
src/project/dialogs/noteswidget.cpp
src/project/dialogs/noteswidget.cpp
+2
-3
src/project/dialogs/profilewidget.cpp
src/project/dialogs/profilewidget.cpp
+1
-1
src/project/dialogs/projectsettings.cpp
src/project/dialogs/projectsettings.cpp
+3
-3
src/project/dialogs/temporarydata.cpp
src/project/dialogs/temporarydata.cpp
+1
-1
src/project/notesplugin.cpp
src/project/notesplugin.cpp
+3
-3
src/project/projectmanager.cpp
src/project/projectmanager.cpp
+6
-7
src/qt-oauth-lib/oauth2.h
src/qt-oauth-lib/oauth2.h
+3
-6
src/scopes/scopemanager.cpp
src/scopes/scopemanager.cpp
+1
-1
src/statusbarmessagelabel.h
src/statusbarmessagelabel.h
+3
-1
src/timeline2/model/builders/meltBuilder.cpp
src/timeline2/model/builders/meltBuilder.cpp
+1
-1
src/timeline2/model/clipmodel.cpp
src/timeline2/model/clipmodel.cpp
+13
-14
src/timeline2/model/compositionmodel.cpp
src/timeline2/model/compositionmodel.cpp
+3
-3
src/timeline2/model/groupsmodel.cpp
src/timeline2/model/groupsmodel.cpp
+3
-4
src/timeline2/model/timelinefunctions.cpp
src/timeline2/model/timelinefunctions.cpp
+5
-6
src/timeline2/model/timelinemodel.cpp
src/timeline2/model/timelinemodel.cpp
+2
-2
src/timeline2/model/trackmodel.cpp
src/timeline2/model/trackmodel.cpp
+10
-10
src/timeline2/view/dialogs/speeddialog.cpp
src/timeline2/view/dialogs/speeddialog.cpp
+3
-3
src/timeline2/view/dialogs/trackdialog.cpp
src/timeline2/view/dialogs/trackdialog.cpp
+1
-1
src/timeline2/view/previewmanager.cpp
src/timeline2/view/previewmanager.cpp
+17
-17
src/timeline2/view/qmltypes/thumbnailprovider.cpp
src/timeline2/view/qmltypes/thumbnailprovider.cpp
+2
-2
src/timeline2/view/timelinecontroller.cpp
src/timeline2/view/timelinecontroller.cpp
+10
-11
src/timeline2/view/timelinecontroller.h
src/timeline2/view/timelinecontroller.h
+2
-2
src/timeline2/view/timelinetabs.cpp
src/timeline2/view/timelinetabs.cpp
+1
-1
src/timeline2/view/timelinewidget.cpp
src/timeline2/view/timelinewidget.cpp
+10
-10
src/titler/graphicsscenerectmove.cpp
src/titler/graphicsscenerectmove.cpp
+1
-1
src/titler/titlewidget.cpp
src/titler/titlewidget.cpp
+7
-8
src/transitions/transitionlist/view/transitionlistwidget.cpp
src/transitions/transitionlist/view/transitionlistwidget.cpp
+1
-1
src/transitions/transitionsrepository.cpp
src/transitions/transitionsrepository.cpp
+1
-1
src/transitions/view/transitionstackview.cpp
src/transitions/view/transitionstackview.cpp
+1
-1
src/utils/freesound.cpp
src/utils/freesound.cpp
+1
-1
src/utils/resourcewidget.cpp
src/utils/resourcewidget.cpp
+1
-1
src/utils/thememanager.cpp
src/utils/thememanager.cpp
+1
-1
src/utils/thumbnailcache.cpp
src/utils/thumbnailcache.cpp
+1
-1
src/widgets/dragvalue.cpp
src/widgets/dragvalue.cpp
+1
-1
src/widgets/geometrywidget.cpp
src/widgets/geometrywidget.cpp
+1
-1
src/widgets/progressbutton.h
src/widgets/progressbutton.h
+4
-1
No files found.
renderer/kdenlive_render.cpp
View file @
3b9d8bfd
...
...
@@ -29,7 +29,6 @@ int main(int argc, char **argv)
QApplication
app
(
argc
,
argv
);
QStringList
args
=
app
.
arguments
();
QStringList
preargs
;
QString
locale
;
if
(
args
.
count
()
>=
4
)
{
// Remove program name
args
.
removeFirst
();
...
...
@@ -92,7 +91,7 @@ int main(int argc, char **argv)
QLocale
::
setDefault
(
QLocale
(
localename
));
for
(
const
QString
&
frame
:
qAsConst
(
chunks
))
{
fprintf
(
stderr
,
"START:%d
\n
"
,
frame
.
toInt
());
QString
fileName
=
QStringLiteral
(
"%1.%2"
).
arg
(
frame
).
arg
(
extension
);
QString
fileName
=
QStringLiteral
(
"%1.%2"
).
arg
(
frame
,
extension
);
if
(
baseFolder
.
exists
(
fileName
))
{
// Don't overwrite an existing file
fprintf
(
stderr
,
"DONE:%d
\n
"
,
frame
.
toInt
());
...
...
src/assets/assetpanel.cpp
View file @
3b9d8bfd
...
...
@@ -68,7 +68,7 @@ AssetPanel::AssetPanel(QWidget *parent)
for
(
const
auto
&
transition
:
qAsConst
(
allTransitions
))
{
m_switchCompoButton
->
addItem
(
transition
.
second
,
transition
.
first
);
}
connect
(
m_switchCompoButton
,
static_cast
<
void
(
QComboBox
::*
)(
int
)
>
(
&
QComboBox
::
activated
),
[
&
]()
{
connect
(
m_switchCompoButton
,
static_cast
<
void
(
QComboBox
::*
)(
int
)
>
(
&
QComboBox
::
activated
),
this
,
[
&
]()
{
if
(
m_transitionWidget
->
stackOwner
().
first
==
ObjectType
::
TimelineComposition
)
{
emit
switchCurrentComposition
(
m_transitionWidget
->
stackOwner
().
second
,
m_switchCompoButton
->
currentData
().
toString
());
}
...
...
@@ -141,7 +141,7 @@ AssetPanel::AssetPanel(QWidget *parent)
connect
(
m_effectStackWidget
,
&
EffectStackView
::
seekToPos
,
this
,
&
AssetPanel
::
seekToPos
);
connect
(
m_effectStackWidget
,
&
EffectStackView
::
reloadEffect
,
this
,
&
AssetPanel
::
reloadEffect
);
connect
(
m_transitionWidget
,
&
TransitionStackView
::
seekToTransPos
,
this
,
&
AssetPanel
::
seekToPos
);
connect
(
m_effectStackWidget
,
&
EffectStackView
::
updateEnabledState
,
[
this
]()
{
m_enableStackButton
->
setActive
(
m_effectStackWidget
->
isStackEnabled
());
});
connect
(
m_effectStackWidget
,
&
EffectStackView
::
updateEnabledState
,
this
,
[
this
]()
{
m_enableStackButton
->
setActive
(
m_effectStackWidget
->
isStackEnabled
());
});
}
void
AssetPanel
::
showTransition
(
int
tid
,
const
std
::
shared_ptr
<
AssetParameterModel
>
&
transitionModel
)
...
...
@@ -217,7 +217,7 @@ void AssetPanel::showEffectStack(const QString &itemName, const std::shared_ptr<
m_enableStackButton
->
setActive
(
effectsModel
->
isStackEnabled
());
if
(
showSplit
)
{
m_splitButton
->
setEnabled
(
effectsModel
->
rowCount
()
>
0
);
QObject
::
connect
(
effectsModel
.
get
(),
&
EffectStackModel
::
dataChanged
,
[
&
]()
{
QObject
::
connect
(
effectsModel
.
get
(),
&
EffectStackModel
::
dataChanged
,
this
,
[
&
]()
{
if
(
m_effectStackWidget
->
isEmpty
())
{
m_splitButton
->
setActive
(
false
);
}
...
...
@@ -394,7 +394,7 @@ void AssetPanel::enableStack(bool enable)
void
AssetPanel
::
deleteCurrentEffect
()
{
if
(
m_effectStackWidget
->
isVisible
())
{
m_effectStackWidget
->
removeCurrentEffect
();
emit
m_effectStackWidget
->
removeCurrentEffect
();
}
}
...
...
@@ -414,7 +414,7 @@ void AssetPanel::slotCheckWheelEventFilter()
// widget has scroll bar,
blockWheel
=
true
;
}
m_effectStackWidget
->
blockWheenEvent
(
blockWheel
);
emit
m_effectStackWidget
->
blockWheenEvent
(
blockWheel
);
}
void
AssetPanel
::
assetPanelWarning
(
const
QString
service
,
const
QString
/*id*/
,
const
QString
message
)
...
...
src/assets/keyframes/model/corners/cornershelper.cpp
View file @
3b9d8bfd
...
...
@@ -51,7 +51,6 @@ void CornersHelper::slotUpdateFromMonitorData(const QVariantList &v)
void
CornersHelper
::
refreshParams
(
int
pos
)
{
QVariantList
points
{
QPointF
(),
QPointF
(),
QPointF
(),
QPointF
()};
QList
<
double
>
coords
;
QSize
frameSize
=
pCore
->
getCurrentFrameSize
();
for
(
const
auto
&
ix
:
qAsConst
(
m_indexes
))
{
auto
type
=
m_model
->
data
(
ix
,
AssetParameterModel
::
TypeRole
).
value
<
ParamType
>
();
...
...
src/assets/keyframes/model/keyframemodel.cpp
View file @
3b9d8bfd
...
...
@@ -862,7 +862,6 @@ void KeyframeModel::parseRotoProperty(const QString &prop)
QJsonDocument
doc
=
QJsonDocument
::
fromJson
(
prop
.
toLatin1
(),
&
jsonError
);
QVariant
data
=
doc
.
toVariant
();
if
(
data
.
canConvert
(
QVariant
::
Map
))
{
QList
<
int
>
keyframes
;
QMap
<
QString
,
QVariant
>
map
=
data
.
toMap
();
QMap
<
QString
,
QVariant
>::
const_iterator
i
=
map
.
constBegin
();
while
(
i
!=
map
.
constEnd
())
{
...
...
src/assets/model/assetparametermodel.cpp
View file @
3b9d8bfd
...
...
@@ -217,7 +217,7 @@ AssetParameterModel::AssetParameterModel(std::unique_ptr<Mlt::Properties> asset,
}
qDebug
()
<<
"END parsing of "
<<
assetId
<<
". Number of found parameters"
<<
m_rows
.
size
();
emit
modelChanged
();
modelChanged
();
}
void
AssetParameterModel
::
prepareKeyframes
()
...
...
src/assets/view/assetparameterview.cpp
View file @
3b9d8bfd
...
...
@@ -58,7 +58,7 @@ void AssetParameterView::setModel(const std::shared_ptr<AssetParameterModel> &mo
const
QString
paramTag
=
model
->
getAssetId
();
QDir
dir
(
QStandardPaths
::
writableLocation
(
QStandardPaths
::
AppDataLocation
)
+
QStringLiteral
(
"/effects/presets/"
));
const
QString
presetFile
=
dir
.
absoluteFilePath
(
QString
(
"%1.json"
).
arg
(
paramTag
));
connect
(
this
,
&
AssetParameterView
::
updatePresets
,
[
this
,
presetFile
](
const
QString
&
presetName
)
{
connect
(
this
,
&
AssetParameterView
::
updatePresets
,
this
,
[
this
,
presetFile
](
const
QString
&
presetName
)
{
m_presetMenu
->
clear
();
m_presetGroup
.
reset
(
new
QActionGroup
(
this
));
m_presetGroup
->
setExclusive
(
true
);
...
...
@@ -92,7 +92,7 @@ void AssetParameterView::setModel(const std::shared_ptr<AssetParameterModel> &mo
connect
(
w
,
&
AbstractParamWidget
::
valuesChanged
,
this
,
&
AssetParameterView
::
commitMultipleChanges
);
connect
(
w
,
&
AbstractParamWidget
::
valueChanged
,
this
,
&
AssetParameterView
::
commitChanges
);
m_lay
->
addWidget
(
w
);
connect
(
w
,
&
AbstractParamWidget
::
updateHeight
,
[
&
](
int
h
)
{
connect
(
w
,
&
AbstractParamWidget
::
updateHeight
,
this
,
[
&
](
int
h
)
{
setFixedHeight
(
h
+
m_lay
->
contentsMargins
().
bottom
());
emit
updateHeight
();
});
...
...
@@ -113,7 +113,7 @@ void AssetParameterView::setModel(const std::shared_ptr<AssetParameterModel> &mo
connect
(
w
,
&
AbstractParamWidget
::
valueChanged
,
this
,
&
AssetParameterView
::
commitChanges
);
connect
(
w
,
&
AbstractParamWidget
::
seekToPos
,
this
,
&
AssetParameterView
::
seekToPos
);
connect
(
w
,
&
AbstractParamWidget
::
activateEffect
,
this
,
&
AssetParameterView
::
activateEffect
);
connect
(
w
,
&
AbstractParamWidget
::
updateHeight
,
[
&
]()
{
connect
(
w
,
&
AbstractParamWidget
::
updateHeight
,
this
,
[
&
]()
{
setFixedHeight
(
contentHeight
());
emit
updateHeight
();
});
...
...
src/assets/view/assetparameterview.hpp
View file @
3b9d8bfd
...
...
@@ -94,6 +94,9 @@ protected:
QMenu
*
m_presetMenu
;
std
::
shared_ptr
<
QActionGroup
>
m_presetGroup
;
private:
QVector
<
QPair
<
QString
,
QVariant
>>
getDefaultValues
()
const
;
private
slots
:
/** @brief Apply a change of parameter sent by the view
@param index is the index corresponding to the modified param
...
...
@@ -102,7 +105,6 @@ private slots:
*/
void
commitChanges
(
const
QModelIndex
&
index
,
const
QString
&
value
,
bool
storeUndo
);
void
commitMultipleChanges
(
const
QList
<
QModelIndex
>
indexes
,
const
QStringList
&
values
,
bool
storeUndo
);
QVector
<
QPair
<
QString
,
QVariant
>>
getDefaultValues
()
const
;
signals:
void
seekToPos
(
int
);
...
...
src/assets/view/widgets/boolparamwidget.cpp
View file @
3b9d8bfd
...
...
@@ -41,7 +41,7 @@ BoolParamWidget::BoolParamWidget(std::shared_ptr<AssetParameterModel> model, QMo
slotRefresh
();
// emit the signal of the base class when appropriate
connect
(
this
->
m_checkBox
,
&
QCheckBox
::
stateChanged
,
[
this
](
int
state
)
{
connect
(
this
->
m_checkBox
,
&
QCheckBox
::
stateChanged
,
this
,
[
this
](
int
state
)
{
emit
valueChanged
(
m_index
,
QString
::
number
(
state
),
true
);
});
}
...
...
src/assets/view/widgets/buttonparamwidget.cpp
View file @
3b9d8bfd
...
...
@@ -89,7 +89,7 @@ ButtonParamWidget::ButtonParamWidget(std::shared_ptr<AssetParameterModel> model,
setMinimumHeight
(
m_button
->
sizeHint
().
height
()
+
(
m_label
!=
nullptr
?
m_label
->
sizeHint
().
height
()
:
0
));
// emit the signal of the base class when appropriate
connect
(
this
->
m_button
,
&
QPushButton
::
clicked
,
[
&
,
filterData
,
filterAddedParams
,
consumerParams
]()
{
connect
(
this
->
m_button
,
&
QPushButton
::
clicked
,
this
,
[
&
,
filterData
,
filterAddedParams
,
consumerParams
]()
{
// Trigger job
if
(
!
m_displayConditional
)
{
QVector
<
QPair
<
QString
,
QVariant
>>
values
;
...
...
@@ -133,7 +133,7 @@ ButtonParamWidget::ButtonParamWidget(std::shared_ptr<AssetParameterModel> model,
fParams
.
insert
({
fparam
.
section
(
QLatin1Char
(
'='
),
0
,
0
),
fparam
.
section
(
QLatin1Char
(
'='
),
1
)});
}
}
pCore
->
jobManager
()
->
startJob
<
FilterClipJob
>
({
binId
},
-
1
,
QString
(),
owner
,
m_model
,
assetId
,
in
,
out
,
assetId
,
fParams
,
fData
,
consumerParams
);
emit
pCore
->
jobManager
()
->
startJob
<
FilterClipJob
>
({
binId
},
-
1
,
QString
(),
owner
,
m_model
,
assetId
,
in
,
out
,
assetId
,
fParams
,
fData
,
consumerParams
);
if
(
m_label
)
{
m_label
->
setVisible
(
false
);
}
...
...
src/assets/view/widgets/clickablelabelwidget.cpp
View file @
3b9d8bfd
...
...
@@ -38,7 +38,6 @@ ClickableLabelParamWidget::ClickableLabelParamWidget(std::shared_ptr<AssetParame
{
// setup the comment
m_displayName
=
m_model
->
data
(
m_index
,
Qt
::
DisplayRole
).
toString
();
QString
name
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
NameRole
).
toString
();
QString
comment
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
CommentRole
).
toString
();
setToolTip
(
comment
);
auto
*
layout
=
new
QHBoxLayout
(
this
);
...
...
@@ -50,12 +49,12 @@ ClickableLabelParamWidget::ClickableLabelParamWidget(std::shared_ptr<AssetParame
layout
->
setContentsMargins
(
0
,
0
,
0
,
0
);
layout
->
addWidget
(
m_tb
);
layout
->
addWidget
(
m_label
);
connect
(
m_tb
,
&
QToolButton
::
clicked
,
[
&
]()
{
connect
(
m_tb
,
&
QToolButton
::
clicked
,
this
,
[
&
]()
{
QClipboard
*
clipboard
=
QApplication
::
clipboard
();
QString
value
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
ValueRole
).
toString
();
clipboard
->
setText
(
value
);
});
connect
(
m_label
,
&
QLabel
::
linkActivated
,
[
&
](
const
QString
&
result
)
{
connect
(
m_label
,
&
QLabel
::
linkActivated
,
this
,
[
&
](
const
QString
&
result
)
{
QClipboard
*
clipboard
=
QApplication
::
clipboard
();
clipboard
->
setText
(
result
);
});
...
...
src/assets/view/widgets/colorwheel.cpp
View file @
3b9d8bfd
...
...
@@ -519,7 +519,7 @@ ColorWheel::ColorWheel(QString id, QString name, NegQColor color, QWidget *paren
hb
->
setContentsMargins
(
0
,
0
,
0
,
0
);
lay
->
addLayout
(
hb
);
m_container
->
setSizePolicy
(
QSizePolicy
::
MinimumExpanding
,
QSizePolicy
::
MinimumExpanding
);
connect
(
m_container
,
&
WheelContainer
::
colorChange
,
[
&
]
(
const
NegQColor
&
col
)
{
connect
(
m_container
,
&
WheelContainer
::
colorChange
,
this
,
[
&
]
(
const
NegQColor
&
col
)
{
QList
<
double
>
vals
=
m_container
->
getNiceParamValues
();
m_redEdit
->
blockSignals
(
true
);
m_greenEdit
->
blockSignals
(
true
);
...
...
@@ -532,13 +532,13 @@ ColorWheel::ColorWheel(QString id, QString name, NegQColor color, QWidget *paren
m_blueEdit
->
blockSignals
(
false
);
emit
colorChange
(
col
);
});
connect
(
m_redEdit
,
static_cast
<
void
(
QDoubleSpinBox
::*
)(
double
)
>
(
&
QDoubleSpinBox
::
valueChanged
),
[
&
]()
{
connect
(
m_redEdit
,
static_cast
<
void
(
QDoubleSpinBox
::*
)(
double
)
>
(
&
QDoubleSpinBox
::
valueChanged
),
this
,
[
&
]()
{
m_container
->
setRedColor
(
m_redEdit
->
value
());
});
connect
(
m_greenEdit
,
static_cast
<
void
(
QDoubleSpinBox
::*
)(
double
)
>
(
&
QDoubleSpinBox
::
valueChanged
),
[
&
]()
{
connect
(
m_greenEdit
,
static_cast
<
void
(
QDoubleSpinBox
::*
)(
double
)
>
(
&
QDoubleSpinBox
::
valueChanged
),
this
,
[
&
]()
{
m_container
->
setGreenColor
(
m_greenEdit
->
value
());
});
connect
(
m_blueEdit
,
static_cast
<
void
(
QDoubleSpinBox
::*
)(
double
)
>
(
&
QDoubleSpinBox
::
valueChanged
),
[
&
]()
{
connect
(
m_blueEdit
,
static_cast
<
void
(
QDoubleSpinBox
::*
)(
double
)
>
(
&
QDoubleSpinBox
::
valueChanged
),
this
,
[
&
]()
{
m_container
->
setBlueColor
(
m_blueEdit
->
value
());
});
setMinimumHeight
(
m_wheelName
->
height
()
+
m_container
->
minimumHeight
()
+
m_redEdit
->
height
());
...
...
@@ -555,7 +555,6 @@ NegQColor ColorWheel::color() const
void
ColorWheel
::
setColor
(
QList
<
double
>
values
)
{
m_container
->
setColor
(
values
);
QList
<
double
>
vals
=
m_container
->
getNiceParamValues
();
m_redEdit
->
blockSignals
(
true
);
m_greenEdit
->
blockSignals
(
true
);
m_blueEdit
->
blockSignals
(
true
);
...
...
src/assets/view/widgets/doubleparamwidget.cpp
View file @
3b9d8bfd
...
...
@@ -49,7 +49,7 @@ DoubleParamWidget::DoubleParamWidget(std::shared_ptr<AssetParameterModel> model,
setMinimumHeight
(
m_doubleWidget
->
height
());
// Connect signal
connect
(
m_doubleWidget
,
&
DoubleWidget
::
valueChanged
,
[
this
](
double
val
)
{
emit
valueChanged
(
m_index
,
QString
::
number
(
val
,
'f'
),
true
);
});
connect
(
m_doubleWidget
,
&
DoubleWidget
::
valueChanged
,
this
,
[
this
](
double
val
)
{
emit
valueChanged
(
m_index
,
QString
::
number
(
val
,
'f'
),
true
);
});
slotRefresh
();
}
...
...
src/assets/view/widgets/fontparamwidget.cpp
View file @
3b9d8bfd
...
...
@@ -38,7 +38,7 @@ FontParamWidget::FontParamWidget(std::shared_ptr<AssetParameterModel> model, QMo
slotRefresh
();
setMinimumHeight
(
fontfamilywidget
->
sizeHint
().
height
());
// emit the signal of the base class when appropriate
connect
(
this
->
fontfamilywidget
,
&
QFontComboBox
::
currentFontChanged
,
[
this
](
const
QFont
&
font
)
{
emit
valueChanged
(
m_index
,
font
.
family
(),
true
);
});
connect
(
this
->
fontfamilywidget
,
&
QFontComboBox
::
currentFontChanged
,
this
,
[
this
](
const
QFont
&
font
)
{
emit
valueChanged
(
m_index
,
font
.
family
(),
true
);
});
}
void
FontParamWidget
::
slotShowComment
(
bool
show
)
...
...
src/assets/view/widgets/geometryeditwidget.cpp
View file @
3b9d8bfd
...
...
@@ -57,7 +57,7 @@ GeometryEditWidget::GeometryEditWidget(std::shared_ptr<AssetParameterModel> mode
setFixedHeight
(
m_geom
->
sizeHint
().
height
());
// emit the signal of the base class when appropriate
connect
(
this
->
m_geom
,
&
GeometryWidget
::
valueChanged
,
[
this
](
const
QString
val
)
{
emit
valueChanged
(
m_index
,
val
,
true
);
});
connect
(
this
->
m_geom
,
&
GeometryWidget
::
valueChanged
,
this
,
[
this
](
const
QString
val
)
{
emit
valueChanged
(
m_index
,
val
,
true
);
});
setToolTip
(
comment
);
}
...
...
src/assets/view/widgets/keyframeimport.cpp
View file @
3b9d8bfd
...
...
@@ -372,7 +372,6 @@ void KeyframeImport::updateDestinationRange()
m_destMin
.
setEnabled
(
true
);
m_destMax
.
setEnabled
(
true
);
m_limitRange
->
setEnabled
(
true
);
QString
tag
=
m_targetCombo
->
currentData
().
toString
();
double
min
=
m_model
->
data
(
m_targetCombo
->
currentData
().
toModelIndex
(),
AssetParameterModel
::
MinRole
).
toDouble
();
double
max
=
m_model
->
data
(
m_targetCombo
->
currentData
().
toModelIndex
(),
AssetParameterModel
::
MaxRole
).
toDouble
();
m_destMin
.
setRange
(
min
,
max
);
...
...
src/assets/view/widgets/keyframewidget.cpp
View file @
3b9d8bfd
...
...
@@ -143,7 +143,7 @@ KeyframeWidget::KeyframeWidget(std::shared_ptr<AssetParameterModel> model, QMode
break
;
}
connect
(
kfType
,
static_cast
<
void
(
KSelectAction
::*
)(
QAction
*
)
>
(
&
KSelectAction
::
triggered
),
[
&
](
QAction
*
ac
)
{
KdenliveSettings
::
setDefaultkeyframeinterp
(
ac
->
data
().
toInt
());
});
this
,
[
&
](
QAction
*
ac
)
{
KdenliveSettings
::
setDefaultkeyframeinterp
(
ac
->
data
().
toInt
());
});
auto
*
container
=
new
QMenu
(
this
);
container
->
addAction
(
copy
);
container
->
addAction
(
paste
);
...
...
@@ -164,8 +164,8 @@ KeyframeWidget::KeyframeWidget(std::shared_ptr<AssetParameterModel> model, QMode
m_lay
->
addWidget
(
m_toolbar
);
monitorSeek
(
monitor
->
position
());
connect
(
m_time
,
&
TimecodeDisplay
::
timeCodeEditingFinished
,
[
&
]()
{
slotSetPosition
(
-
1
,
true
);
});
connect
(
m_keyframeview
,
&
KeyframeView
::
seekToPos
,
[
&
](
int
p
)
{
slotSetPosition
(
p
,
true
);
});
connect
(
m_time
,
&
TimecodeDisplay
::
timeCodeEditingFinished
,
this
,
[
&
]()
{
slotSetPosition
(
-
1
,
true
);
});
connect
(
m_keyframeview
,
&
KeyframeView
::
seekToPos
,
this
,
[
&
](
int
p
)
{
slotSetPosition
(
p
,
true
);
});
connect
(
m_keyframeview
,
&
KeyframeView
::
atKeyframe
,
this
,
&
KeyframeWidget
::
slotAtKeyframe
);
connect
(
m_keyframeview
,
&
KeyframeView
::
modified
,
this
,
&
KeyframeWidget
::
slotRefreshParams
);
connect
(
m_keyframeview
,
&
KeyframeView
::
activateEffect
,
this
,
&
KeyframeWidget
::
activateEffect
);
...
...
@@ -210,7 +210,7 @@ void KeyframeWidget::slotEditKeyframeType(QAction *action)
{
int
type
=
action
->
data
().
toInt
();
m_keyframeview
->
slotEditType
(
type
,
m_index
);
activateEffect
();
emit
activateEffect
();
}
void
KeyframeWidget
::
slotRefreshParams
()
...
...
@@ -356,8 +356,8 @@ void KeyframeWidget::addParameter(const QPersistentModelIndex &index)
GeometryWidget
*
geomWidget
=
new
GeometryWidget
(
pCore
->
getMonitor
(
m_model
->
monitorId
),
range
,
rect
,
opacity
,
m_sourceFrameSize
,
false
,
m_model
->
data
(
m_index
,
AssetParameterModel
::
OpacityRole
).
toBool
(),
integerOpacity
,
this
);
connect
(
geomWidget
,
&
GeometryWidget
::
valueChanged
,
[
this
,
index
](
const
QString
v
)
{
activateEffect
();
this
,
[
this
,
index
](
const
QString
v
)
{
emit
activateEffect
();
m_keyframes
->
updateKeyframe
(
GenTime
(
getPosition
(),
pCore
->
getCurrentFps
()),
QVariant
(
v
),
index
);
});
paramWidget
=
geomWidget
;
}
else
if
(
type
==
ParamType
::
Roto_spline
)
{
...
...
@@ -390,8 +390,8 @@ void KeyframeWidget::addParameter(const QPersistentModelIndex &index)
factor
=
qFuzzyIsNull
(
factor
)
?
1
:
factor
;
auto
doubleWidget
=
new
DoubleWidget
(
name
,
value
,
min
,
max
,
factor
,
defaultValue
,
comment
,
-
1
,
suffix
,
decimals
,
m_model
->
data
(
index
,
AssetParameterModel
::
OddRole
).
toBool
(),
this
);
connect
(
doubleWidget
,
&
DoubleWidget
::
valueChanged
,
[
this
,
index
](
double
v
)
{
activateEffect
();
this
,
[
this
,
index
](
double
v
)
{
emit
activateEffect
();
m_keyframes
->
updateKeyframe
(
GenTime
(
getPosition
(),
pCore
->
getCurrentFps
()),
QVariant
(
v
),
index
);
});
paramWidget
=
doubleWidget
;
...
...
@@ -432,7 +432,7 @@ void KeyframeWidget::connectMonitor(bool active)
void
KeyframeWidget
::
slotUpdateKeyframesFromMonitor
(
const
QPersistentModelIndex
&
index
,
const
QVariant
&
res
)
{
activateEffect
();
emit
activateEffect
();
if
(
m_keyframes
->
isEmpty
())
{
GenTime
pos
(
pCore
->
getItemIn
(
m_model
->
getOwnerId
())
+
m_time
->
getValue
(),
pCore
->
getCurrentFps
());
if
(
m_time
->
getValue
()
>
0
)
{
...
...
src/assets/view/widgets/keywordparamwidget.cpp
View file @
3b9d8bfd
...
...
@@ -28,7 +28,6 @@ KeywordParamWidget::KeywordParamWidget(std::shared_ptr<AssetParameterModel> mode
setupUi
(
this
);
// setup the comment
QString
name
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
NameRole
).
toString
();
QString
comment
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
CommentRole
).
toString
();
setToolTip
(
comment
);
...
...
@@ -53,11 +52,11 @@ KeywordParamWidget::KeywordParamWidget(std::shared_ptr<AssetParameterModel> mode
setMinimumHeight
(
comboboxwidget
->
sizeHint
().
height
());
// emit the signal of the base class when appropriate
connect
(
lineeditwidget
,
&
QLineEdit
::
editingFinished
,
[
this
]()
{
connect
(
lineeditwidget
,
&
QLineEdit
::
editingFinished
,
this
,
[
this
]()
{
emit
valueChanged
(
m_index
,
lineeditwidget
->
text
(),
true
);
});
connect
(
comboboxwidget
,
static_cast
<
void
(
QComboBox
::*
)(
int
)
>
(
&
QComboBox
::
currentIndexChanged
),
[
this
](
int
ix
)
{
this
,
[
this
](
int
ix
)
{
if
(
ix
>
0
)
{
QString
comboval
=
comboboxwidget
->
itemData
(
ix
).
toString
();
this
->
lineeditwidget
->
insert
(
comboval
);
...
...
src/assets/view/widgets/listparamwidget.cpp
View file @
3b9d8bfd
...
...
@@ -30,7 +30,6 @@ ListParamWidget::ListParamWidget(std::shared_ptr<AssetParameterModel> model, QMo
setupUi
(
this
);
// Get data from model
QString
name
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
NameRole
).
toString
();
QString
comment
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
CommentRole
).
toString
();
// setup the comment
...
...
@@ -47,7 +46,7 @@ ListParamWidget::ListParamWidget(std::shared_ptr<AssetParameterModel> model, QMo
// emit the signal of the base class when appropriate
// The connection is ugly because the signal "currentIndexChanged" is overloaded in QComboBox
connect
(
this
->
m_list
,
static_cast
<
void
(
QComboBox
::*
)(
int
)
>
(
&
QComboBox
::
currentIndexChanged
),
[
this
](
int
)
{
this
,
[
this
](
int
)
{
emit
valueChanged
(
m_index
,
m_list
->
itemData
(
m_list
->
currentIndex
()).
toString
(),
true
);
});
}
...
...
src/assets/view/widgets/positioneditwidget.cpp
View file @
3b9d8bfd
...
...
@@ -51,7 +51,7 @@ PositionEditWidget::PositionEditWidget(std::shared_ptr<AssetParameterModel> mode
connect
(
m_slider
,
&
QAbstractSlider
::
valueChanged
,
this
,
&
PositionEditWidget
::
valueChanged
);
// emit the signal of the base class when appropriate
connect
(
this
->
m_slider
,
&
QAbstractSlider
::
valueChanged
,
[
this
](
int
val
)
{
connect
(
this
->
m_slider
,
&
QAbstractSlider
::
valueChanged
,
this
,
[
this
](
int
val
)
{
if
(
m_inverted
)
{
val
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
ParentInRole
).
toInt
()
+
m_model
->
data
(
m_index
,
AssetParameterModel
::
ParentDurationRole
).
toInt
()
-
1
-
val
;
...
...
src/assets/view/widgets/slidewidget.cpp
View file @
3b9d8bfd
...
...
@@ -25,7 +25,6 @@ SlideWidget::SlideWidget(std::shared_ptr<AssetParameterModel> model, QModelIndex
{
// setup the comment
setupUi
(
this
);
QString
name
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
NameRole
).
toString
();
QString
comment
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
CommentRole
).
toString
();
slotRefresh
();
...
...
src/assets/view/widgets/switchparamwidget.cpp
View file @
3b9d8bfd
...
...
@@ -28,7 +28,6 @@ SwitchParamWidget::SwitchParamWidget(std::shared_ptr<AssetParameterModel> model,
setupUi
(
this
);
// setup the comment
QString
name
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
NameRole
).
toString
();
QString
comment
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
CommentRole
).
toString
();
setToolTip
(
comment
);
m_labelComment
->
setText
(
comment
);
...
...
@@ -42,7 +41,7 @@ SwitchParamWidget::SwitchParamWidget(std::shared_ptr<AssetParameterModel> model,
slotRefresh
();
// emit the signal of the base class when appropriate
connect
(
this
->
m_checkBox
,
&
QCheckBox
::
stateChanged
,
[
this
](
int
state
)
{
connect
(
this
->
m_checkBox
,
&
QCheckBox
::
stateChanged
,
this
,
[
this
](
int
state
)
{
emit
valueChanged
(
m_index
,
(
state
==
Qt
::
Checked
?
m_model
->
data
(
m_index
,
AssetParameterModel
::
MaxRole
).
toString
()
:
m_model
->
data
(
m_index
,
AssetParameterModel
::
MinRole
).
toString
()),
...
...
src/assets/view/widgets/urlparamwidget.cpp
View file @
3b9d8bfd
...
...
@@ -30,7 +30,6 @@ UrlParamWidget::UrlParamWidget(std::shared_ptr<AssetParameterModel> model, QMode
setupUi
(
this
);
// setup the comment
QString
name
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
NameRole
).
toString
();
QString
comment
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
CommentRole
).
toString
();
labelComment
->
setText
(
comment
);
setToolTip
(
comment
);
...
...
@@ -49,7 +48,7 @@ UrlParamWidget::UrlParamWidget(std::shared_ptr<AssetParameterModel> model, QMode
slotRefresh
();
// emit the signal of the base class when appropriate
connect
(
this
->
urlwidget
,
&
KUrlRequester
::
textChanged
,
[
this
]()
{
connect
(
this
->
urlwidget
,
&
KUrlRequester
::
textChanged
,
this
,
[
this
]()
{
QFileInfo
info
(
urlwidget
->
url
().
toLocalFile
());
if
(
info
.
exists
()
&&
info
.
isFile
())
{
emit
valueChanged
(
m_index
,
this
->
urlwidget
->
url
().
toLocalFile
(),
true
);
...
...
src/audiomixer/mixermanager.cpp
View file @
3b9d8bfd
...
...
@@ -72,7 +72,7 @@ void MixerManager::registerTrack(int tid, std::shared_ptr<Mlt::Tractor> service,
return
;
}
std
::
shared_ptr
<
MixerWidget
>
mixer
(
new
MixerWidget
(
tid
,
service
,
trackTag
,
this
));
connect
(
mixer
.
get
(),
&
MixerWidget
::
muteTrack
,
[
&
](
int
id
,
bool
mute
)
{
connect
(
mixer
.
get
(),
&
MixerWidget
::
muteTrack
,
this
,
[
&
](
int
id
,
bool
mute
)
{
m_model
->
setTrackProperty
(
id
,
"hide"
,
mute
?
QStringLiteral
(
"1"
)
:
QStringLiteral
(
"3"
));
});
if
(
m_visibleMixerManager
)
{
...
...
@@ -80,7 +80,7 @@ void MixerManager::registerTrack(int tid, std::shared_ptr<Mlt::Tractor> service,
}
connect
(
this
,
&
MixerManager
::
updateLevels
,
mixer
.
get
(),
&
MixerWidget
::
updateAudioLevel
);
connect
(
this
,
&
MixerManager
::
clearMixers
,
mixer
.
get
(),
&
MixerWidget
::
clear
);
connect
(
mixer
.
get
(),
&
MixerWidget
::
toggleSolo
,
[
&
](
int
trid
,
bool
solo
)
{
connect
(
mixer
.
get
(),
&
MixerWidget
::
toggleSolo
,
this
,
[
&
](
int
trid
,
bool
solo
)
{
if
(
!
solo
)
{
// unmute
for
(
int
id
:
qAsConst
(
m_soloMuted
))
{
...
...
@@ -143,7 +143,7 @@ void MixerManager::setModel(std::shared_ptr<TimelineItemModel> model)
{
// Insert master mixer
m_model
=
model
;
connect
(
m_model
.
get
(),
&
TimelineItemModel
::
dataChanged
,
[
&
](
const
QModelIndex
&
topLeft
,
const
QModelIndex
&
,
const
QVector
<
int
>
&
roles
)
{
connect
(
m_model
.
get
(),
&
TimelineItemModel
::
dataChanged
,
this
,
[
&
](
const
QModelIndex
&
topLeft
,
const
QModelIndex
&
,
const
QVector
<
int
>
&
roles
)
{
if
(
roles
.
contains
(
TimelineModel
::
IsDisabledRole
))
{
int
id
=
(
int
)
topLeft
.
internalId
();
if
(
m_mixers
.
count
(
id
)
>
0
)
{
...
...
@@ -160,7 +160,7 @@ void MixerManager::setModel(std::shared_ptr<TimelineItemModel> model)
m_masterBox
->
removeWidget
(
m_masterMixer
.
get
());
}
m_masterMixer
.
reset
(
new
MixerWidget
(
-
1
,
service
,
i18n
(
"Master"
),
this
));
connect
(
m_masterMixer
.
get
(),
&
MixerWidget
::
muteTrack
,
[
&
](
int
/*id*/
,
bool
mute
)
{
connect
(
m_masterMixer
.
get
(),
&
MixerWidget
::
muteTrack
,
this
,
[
&
](
int
/*id*/
,
bool
mute
)
{
m_model
->
tractor
()
->
set
(
"hide"
,
mute
?
3
:
1
);
});
if
(
m_visibleMixerManager
)
{
...
...
src/audiomixer/mixerwidget.cpp
View file @
3b9d8bfd
...
...
@@ -165,7 +165,7 @@ void MixerWidget::buildUI(Mlt::Tractor *service, const QString &trackTag)
m_volumeSpin
->
setSuffix
(
i18n
(
"dB"
));
m_volumeSpin
->
setFrame
(
false
);
connect
(
m_volumeSpin
,
static_cast
<
void
(
QDoubleSpinBox
::*
)(
double
)
>
(
&
QDoubleSpinBox
::
valueChanged
),
[
&
](
double
val
)
{
connect
(
m_volumeSpin
,
static_cast
<
void
(
QDoubleSpinBox
::*
)(
double
)
>
(
&
QDoubleSpinBox
::
valueChanged
),
this
,
[
&
](
double
val
)
{
m_volumeSlider
->
setValue
(
fromDB
(
val
));
});
...
...
@@ -239,7 +239,7 @@ void MixerWidget::buildUI(Mlt::Tractor *service, const QString &trackTag)
connect
(
m_balanceDial
,
&
QDial
::
valueChanged
,
m_balanceSpin
,
&
QSpinBox
::
setValue
);
connect
(
m_muteAction
,
&
KDualAction
::
activeChangedByUser
,
[
&
](
bool
active
)
{
connect
(
m_muteAction
,
&
KDualAction
::
activeChangedByUser
,
this
,
[
&
](
bool
active
)
{
if
(
m_tid
==
-
1
)
{
// Muting master, special case
if
(
m_levelFilter
)
{
...
...
@@ -263,7 +263,6 @@ void MixerWidget::buildUI(Mlt::Tractor *service, const QString &trackTag)
mute
->
setAutoRaise
(
true
);
// Setup default width
QFontMetrics
fm
(
font
());
setFixedWidth
(
3
*
mute
->
sizeHint
().
width
());
if
(
m_tid
>
-
1
)
{
...
...
@@ -273,7 +272,7 @@ void MixerWidget::buildUI(Mlt::Tractor *service, const QString &trackTag)
m_solo
->
setIcon
(
QIcon
::
fromTheme
(
"headphones"
));
m_solo
->
setToolTip
(
i18n
(
"Solo mode"
));
m_solo
->
setAutoRaise
(
true
);
connect
(
m_solo
,
&
QToolButton
::
toggled
,
[
&
](
bool
toggled
)
{
connect
(
m_solo
,
&
QToolButton
::
toggled
,
this
,
[
&
](
bool
toggled
)
{
emit
toggleSolo
(
m_tid
,
toggled
);
updateLabel
();
});
...
...
@@ -282,8 +281,8 @@ void MixerWidget::buildUI(Mlt::Tractor *service, const QString &trackTag)
m_record
->
setToolTip
(
i18n
(
"Record"
));
m_record
->
setCheckable
(
true
);
m_record
->
setAutoRaise
(
true
);
connect
(
m_record
,
&
QToolButton
::
clicked
,
[
&
]()
{
m_manager
->
recordAudio
(
m_tid
);
connect
(
m_record
,
&
QToolButton
::
clicked
,
this
,
[
&
]()
{
emit
m_manager
->
recordAudio
(
m_tid
);
});
}
else
{
m_collapse
=
new
QToolButton
(
this
);
...
...
@@ -292,19 +291,19 @@ void MixerWidget::buildUI(Mlt::Tractor *service, const QString &trackTag)
m_collapse
->
setCheckable
(
true
);
m_collapse
->
setAutoRaise
(
true
);
m_collapse
->
setChecked
(
KdenliveSettings
::
mixerCollapse
()
);
connect
(
m_collapse
,
&
QToolButton
::
clicked
,
[
&
]()
{
connect
(
m_collapse
,
&
QToolButton
::
clicked
,
this
,
[
&
]()
{
KdenliveSettings
::
setMixerCollapse
(
m_collapse
->
isChecked
());
m_collapse
->
setIcon
(
m_collapse
->
isChecked
()
?
QIcon
::
fromTheme
(
"arrow-left"
)
:
QIcon
::
fromTheme
(
"arrow-right"
));
m_manager
->
collapseMixers
();
});
}
connect
(
m_volumeSlider
,
&
QSlider
::
valueChanged
,
[
&
](
int
value
)
{
connect
(
m_volumeSlider
,
&
QSlider
::
valueChanged
,
this
,
[
&
](
int
value
)
{
QSignalBlocker
bk
(
m_volumeSpin
);
if
(
m_recording
)
{
m_volumeSpin
->
setValue
(
value
);
KdenliveSettings
::
setAudiocapturevolume
(
value
);
m_manager
->
updateRecVolume
();
emit
m_manager
->
updateRecVolume
();
//TODO update capture volume
}
else
if
(
m_levelFilter
!=
nullptr
)
{
double
dbValue
=
0
;
...
...
@@ -318,18 +317,18 @@ void MixerWidget::buildUI(Mlt::Tractor *service, const QString &trackTag)
m_levelFilter
->
set
(
"level"
,
dbValue
);
m_levelFilter
->
set
(
"disable"
,
value
==
60
?
1
:
0
);
m_levels
.
clear
();
m_manager
->
purgeCache
();
emit
m_manager
->
purgeCache
();
pCore
->
setDocumentModified
();
}
});
connect
(
m_balanceSpin
,
static_cast
<
void
(
QSpinBox
::*
)(
int
)
>
(
&
QSpinBox
::
valueChanged
),
[
&
](
int
value
)
{
connect
(
m_balanceSpin
,
static_cast
<
void
(
QSpinBox
::*
)(
int
)
>
(
&
QSpinBox
::
valueChanged
),
this
,
[
&
](
int
value
)
{
QSignalBlocker
bk
(
m_balanceDial
);
m_balanceDial
->
setValue
(
value
);
if
(
m_balanceFilter
!=
nullptr
)
{
m_balanceFilter
->
set
(
"start"
,
(
value
+
50
)
/
100.
);
m_balanceFilter
->
set
(
"disable"
,
value
==
0
?
1
:
0
);
m_levels
.
clear
();
m_manager
->
purgeCache
();
emit
m_manager
->
purgeCache
();
pCore
->
setDocumentModified
();
}
});
...
...
@@ -398,7 +397,7 @@ void MixerWidget::updateLabel()
m_trackLabel
->
setPalette
(
pal
);
}
else
if
(
m_muteAction
->
isActive
())
{
QPalette
pal
=
m_trackLabel
->
palette
();
pal
.
setColor
(
QPalette
::
Window
,
QColor
(
"#ff8c00"
));
pal
.
setColor
(
QPalette
::
Window
,
QColor
(
0xff8c00
));
m_trackLabel
->
setPalette
(
pal
);
}
else
if
(
m_solo
&&
m_solo
->
isChecked
())
{
QPalette
pal
=
m_trackLabel
->
palette
();
...
...
src/bin/bin.cpp
View file @
3b9d8bfd
...
...
@@ -124,7 +124,7 @@ public:
if
(
rate
%
2
==
1
)
{
rate
++
;
}
static_cast
<
ProjectSortProxyModel
*>
(
model
)
->
updateRating
(
index
,
(
uint
)
rate
);
emit
static_cast
<
ProjectSortProxyModel
*>
(
model
)
->
updateRating
(
index
,
(
uint
)
rate
);
}
}
}
...
...
@@ -905,10 +905,10 @@ Bin::Bin(std::shared_ptr<ProjectItemModel> model, QWidget *parent)
connect
(
m_slider
,
&
QAbstractSlider
::
valueChanged
,
this
,
&
Bin
::
slotSetIconSize
);