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
4fe87ef0
Commit
4fe87ef0
authored
Sep 22, 2019
by
Jean-Baptiste Mardelle
Browse files
Fix some remaining effectstack layout issues
parent
83a4ab9a
Pipeline
#8125
passed with stage
in 22 minutes and 9 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/assets/view/assetparameterview.cpp
View file @
4fe87ef0
...
...
@@ -109,6 +109,10 @@ void AssetParameterView::setModel(const std::shared_ptr<AssetParameterModel> &mo
connect
(
this
,
&
AssetParameterView
::
initKeyframeView
,
w
,
&
AbstractParamWidget
::
slotInitMonitor
);
connect
(
w
,
&
AbstractParamWidget
::
valueChanged
,
this
,
&
AssetParameterView
::
commitChanges
);
connect
(
w
,
&
AbstractParamWidget
::
seekToPos
,
this
,
&
AssetParameterView
::
seekToPos
);
connect
(
w
,
&
AbstractParamWidget
::
updateHeight
,
[
&
,
w
]()
{
setFixedHeight
(
contentHeight
());
emit
updateHeight
();
});
m_lay
->
addWidget
(
w
);
if
(
type
==
ParamType
::
KeyframeParam
||
type
==
ParamType
::
AnimatedRect
||
type
==
ParamType
::
Roto_spline
)
{
m_mainKeyframeWidget
=
static_cast
<
KeyframeWidget
*>
(
w
);
...
...
src/assets/view/widgets/clickablelabelwidget.cpp
View file @
4fe87ef0
...
...
@@ -42,15 +42,15 @@ ClickableLabelParamWidget::ClickableLabelParamWidget(std::shared_ptr<AssetParame
QString
comment
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
CommentRole
).
toString
();
setToolTip
(
comment
);
auto
*
layout
=
new
QHBoxLayout
(
this
);
QToolButton
*
tb
=
new
QToolButton
(
this
);
tb
->
set
AutoRaise
(
true
);
tb
->
setIcon
(
QIcon
::
fromTheme
(
QStringLiteral
(
"edit-copy"
)));
m_
tb
=
new
QToolButton
(
this
);
m_
tb
->
set
Cursor
(
Qt
::
PointingHandCursor
);
m_
tb
->
setIcon
(
QIcon
::
fromTheme
(
QStringLiteral
(
"edit-copy"
)));
m_label
=
new
QLabel
(
this
);
m_label
->
setWordWrap
(
true
);
layout
->
addWidget
(
tb
);
layout
->
setContentsMargins
(
0
,
0
,
0
,
0
);
layout
->
addWidget
(
m_tb
);
layout
->
addWidget
(
m_label
);
setMinimumHeight
(
tb
->
sizeHint
().
height
());
connect
(
tb
,
&
QToolButton
::
clicked
,
[
&
]()
{
connect
(
m_tb
,
&
QToolButton
::
clicked
,
[
&
]()
{
QClipboard
*
clipboard
=
QApplication
::
clipboard
();
QString
value
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
ValueRole
).
toString
();
clipboard
->
setText
(
value
);
...
...
@@ -75,6 +75,8 @@ void ClickableLabelParamWidget::slotRefresh()
QString
value
=
m_model
->
data
(
m_index
,
AssetParameterModel
::
ValueRole
).
toString
();
m_label
->
setText
(
QStringLiteral
(
"<a href=
\"
%1
\"
>"
).
arg
(
value
)
+
m_displayName
+
QStringLiteral
(
"</a>"
));
setVisible
(
!
value
.
isEmpty
());
setMinimumHeight
(
value
.
isEmpty
()
?
0
:
m_tb
->
sizeHint
().
height
());
emit
updateHeight
();
}
bool
ClickableLabelParamWidget
::
getValue
()
...
...
src/assets/view/widgets/clickablelabelwidget.hpp
View file @
4fe87ef0
...
...
@@ -26,6 +26,7 @@
#include <QWidget>
class
QPushButton
;
class
QToolButton
;
class
QLabel
;
/** @brief This class represents a parameter that requires
...
...
@@ -58,6 +59,7 @@ public slots:
private:
QLabel
*
m_label
;
QToolButton
*
m_tb
;
QString
m_displayName
;
};
...
...
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