diff options
author | Alessio Monti di Sopra <a.monti> | 2019-11-30 09:03:22 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-11-30 09:08:04 +0300 |
commit | dc87d09b8b3249898e0f0d301fa22f03cff9d6d5 (patch) | |
tree | 44b22d9d1046dc30c7ae340eb544712630b7cd6b /release/scripts/startup/bl_ui/space_time.py | |
parent | f478fef9d6b0609f4bb60fd98e9292b60927b80e (diff) |
UI: allow to hide markers region per editor
Instead of having the option to show marker lines,
make the marker region optional.
- Added a Show Markers entry in the View menu of the animation editors.
- If the markers region is not active then the Marker menu gets hidden.
- Removed marker menu from the driver editor
and don't allow to use marker operators.
Diffstat (limited to 'release/scripts/startup/bl_ui/space_time.py')
-rw-r--r-- | release/scripts/startup/bl_ui/space_time.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/release/scripts/startup/bl_ui/space_time.py b/release/scripts/startup/bl_ui/space_time.py index 04a904edde3..6d60c67ded0 100644 --- a/release/scripts/startup/bl_ui/space_time.py +++ b/release/scripts/startup/bl_ui/space_time.py @@ -90,6 +90,7 @@ class TIME_MT_editor_menus(Menu): def draw(self, _context): layout = self.layout horizontal = (layout.direction == 'VERTICAL') + st = _context.space_data if horizontal: row = layout.row() sub = row.row(align=True) @@ -109,7 +110,8 @@ class TIME_MT_editor_menus(Menu): sub = row.row(align=True) sub.menu("TIME_MT_view") - sub.menu("TIME_MT_marker") + if st.show_markers: + sub.menu("TIME_MT_marker") class TIME_MT_marker(Menu): @@ -135,7 +137,10 @@ class TIME_MT_view(Menu): layout.separator() - layout.prop(st, "show_marker_lines") + layout.prop(st, "show_markers") + + layout.separator() + layout.prop(scene, "show_keys_from_selected_only") layout.separator() |