Cleanup: remove star import
This commit is contained in:
@@ -19,15 +19,17 @@
|
||||
# <pep8 compliant>
|
||||
|
||||
import bpy
|
||||
from bpy.types import Header, Menu, Panel
|
||||
from .space_time import *
|
||||
|
||||
from bpy.types import (
|
||||
Header,
|
||||
Menu,
|
||||
Panel,
|
||||
)
|
||||
|
||||
#######################################
|
||||
# DopeSheet Filtering - Header Buttons
|
||||
|
||||
# used for DopeSheet, NLA, and Graph Editors
|
||||
def dopesheet_filter(layout, context, genericFiltersOnly=False):
|
||||
def dopesheet_filter(layout, context, generic_filters_only=False):
|
||||
dopesheet = context.space_data.dopesheet
|
||||
is_nla = context.area.type == 'NLA_EDITOR'
|
||||
|
||||
@@ -40,7 +42,7 @@ def dopesheet_filter(layout, context, genericFiltersOnly=False):
|
||||
else: # graph and dopesheet editors - F-Curves and drivers only
|
||||
row.prop(dopesheet, "show_only_errors", text="")
|
||||
|
||||
if not genericFiltersOnly:
|
||||
if not generic_filters_only:
|
||||
if bpy.data.collections:
|
||||
row = layout.row(align=True)
|
||||
row.prop(dopesheet, "filter_collection", text="")
|
||||
@@ -205,6 +207,10 @@ class DOPESHEET_HT_header(Header):
|
||||
row.template_header()
|
||||
|
||||
if st.mode == 'TIMELINE':
|
||||
from .space_time import (
|
||||
TIME_MT_editor_menus,
|
||||
TIME_HT_editor_buttons,
|
||||
)
|
||||
TIME_MT_editor_menus.draw_collapsible(context, layout)
|
||||
TIME_HT_editor_buttons.draw_header(context, layout)
|
||||
else:
|
||||
@@ -247,9 +253,9 @@ class DOPESHEET_HT_editor_buttons(Header):
|
||||
if st.mode == 'DOPESHEET':
|
||||
dopesheet_filter(layout, context)
|
||||
elif st.mode == 'ACTION':
|
||||
# 'genericFiltersOnly' limits the options to only the relevant 'generic' subset of
|
||||
# 'generic_filters_only' limits the options to only the relevant 'generic' subset of
|
||||
# filters which will work here and are useful (especially for character animation)
|
||||
dopesheet_filter(layout, context, genericFiltersOnly=True)
|
||||
dopesheet_filter(layout, context, generic_filters_only=True)
|
||||
elif st.mode == 'GPENCIL':
|
||||
row = layout.row(align=True)
|
||||
row.prop(st.dopesheet, "show_gpencil_3d_only", text="Active Only")
|
||||
|
||||
Reference in New Issue
Block a user