Skip to content
GitLab
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
bfcc5f91
Commit
bfcc5f91
authored
Nov 07, 2022
by
Jean-Baptiste Mardelle
Browse files
Add lock guide action in new guides list widget, with tooltip info
parent
685c75ce
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/mainwindow.cpp
View file @
bfcc5f91
...
...
@@ -1794,6 +1794,9 @@ void MainWindow::setupActions()
addAction
(
QStringLiteral
(
"lock_guides"
),
i18n
(
"Guides Locked"
),
this
,
SLOT
(
slotLockGuides
(
bool
)),
QIcon
::
fromTheme
(
QStringLiteral
(
"kdenlive-lock"
)));
lockGuides
->
setCheckable
(
true
);
lockGuides
->
setChecked
(
KdenliveSettings
::
lockedGuides
());
lockGuides
->
setToolTip
(
i18n
(
"Lock guides"
));
lockGuides
->
setWhatsThis
(
xi18nc
(
"@info:whatsthis"
,
"Lock guides. When locked, the guides won't move when using the spacer tool or inserting/removing blank in tracks."
));
addAction
(
QStringLiteral
(
"delete_all_guides"
),
i18n
(
"Delete All Guides"
),
this
,
SLOT
(
slotDeleteAllGuides
()),
QIcon
::
fromTheme
(
QStringLiteral
(
"edit-delete"
)));
...
...
src/project/dialogs/guideslist.cpp
View file @
bfcc5f91
...
...
@@ -277,6 +277,7 @@ GuidesList::~GuidesList() = default;
void
GuidesList
::
setClipMarkerModel
(
std
::
shared_ptr
<
ProjectClip
>
clip
)
{
m_markerMode
=
true
;
guides_lock
->
setVisible
(
false
);
if
(
clip
==
m_clip
)
{
return
;
}
...
...
@@ -316,6 +317,11 @@ void GuidesList::setModel(std::weak_ptr<MarkerListModel> model, std::shared_ptr<
m_model
=
std
::
move
(
model
);
setEnabled
(
true
);
guideslist_label
->
setText
(
i18n
(
"Timeline Guides"
));
if
(
!
guides_lock
->
defaultAction
())
{
QAction
*
action
=
pCore
->
window
()
->
actionCollection
()
->
action
(
"lock_guides"
);
guides_lock
->
setDefaultAction
(
action
);
}
guides_lock
->
setVisible
(
true
);
m_sortModel
=
viewModel
.
get
();
m_proxy
->
setSourceModel
(
m_sortModel
);
guides_list
->
setModel
(
m_proxy
);
...
...
src/ui/guideslist_ui.ui
View file @
bfcc5f91
...
...
@@ -74,6 +74,19 @@
</property>
</widget>
</item>
<item>
<widget
class=
"QToolButton"
name=
"guides_lock"
>
<property
name=
"text"
>
<string>
...
</string>
</property>
<property
name=
"checkable"
>
<bool>
true
</bool>
</property>
<property
name=
"autoRaise"
>
<bool>
true
</bool>
</property>
</widget>
</item>
<item>
<spacer
name=
"horizontalSpacer"
>
<property
name=
"orientation"
>
...
...
@@ -153,16 +166,16 @@
</layout>
</widget>
<customwidgets>
<customwidget>
<class>
KSqueezedTextLabel
</class>
<extends>
QLabel
</extends>
<header>
ksqueezedtextlabel.h
</header>
</customwidget>
<customwidget>
<class>
MarkerCategoryButton
</class>
<extends>
QToolButton
</extends>
<header>
widgets/markercategorybutton.h
</header>
</customwidget>
<customwidget>
<class>
KSqueezedTextLabel
</class>
<extends>
QLabel
</extends>
<header>
ksqueezedtextlabel.h
</header>
</customwidget>
</customwidgets>
<tabstops>
<tabstop>
filter_line
</tabstop>
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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