Merge branch 'blender-v2.90-release'
This commit is contained in:
commit
289aac723a
|
@ -107,6 +107,14 @@ class OUTLINER_MT_editor_menus(Menu):
|
|||
class OUTLINER_MT_context_menu(Menu):
|
||||
bl_label = "Outliner Context Menu"
|
||||
|
||||
@staticmethod
|
||||
def draw_common_operators(layout):
|
||||
layout.menu("OUTLINER_MT_context_menu_view")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.menu("INFO_MT_area")
|
||||
|
||||
def draw(self, context):
|
||||
space = context.space_data
|
||||
|
||||
|
@ -116,11 +124,7 @@ class OUTLINER_MT_context_menu(Menu):
|
|||
OUTLINER_MT_collection_new.draw_without_context_menu(context, layout)
|
||||
layout.separator()
|
||||
|
||||
layout.menu("OUTLINER_MT_context_menu_view")
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.menu("INFO_MT_area")
|
||||
OUTLINER_MT_context_menu.draw_common_operators(layout)
|
||||
|
||||
|
||||
class OUTLINER_MT_context_menu_view(Menu):
|
||||
|
@ -242,7 +246,7 @@ class OUTLINER_MT_collection(Menu):
|
|||
|
||||
layout.separator()
|
||||
|
||||
OUTLINER_MT_context_menu.draw(self, context)
|
||||
OUTLINER_MT_context_menu.draw_common_operators(layout)
|
||||
|
||||
|
||||
class OUTLINER_MT_collection_new(Menu):
|
||||
|
@ -250,7 +254,7 @@ class OUTLINER_MT_collection_new(Menu):
|
|||
|
||||
@staticmethod
|
||||
def draw_without_context_menu(context, layout):
|
||||
layout.operator("outliner.collection_new", text="New Collection").nested = False
|
||||
layout.operator("outliner.collection_new", text="New Collection").nested = True
|
||||
layout.operator("outliner.id_paste", text="Paste Data-Blocks", icon='PASTEDOWN')
|
||||
|
||||
def draw(self, context):
|
||||
|
@ -260,7 +264,7 @@ class OUTLINER_MT_collection_new(Menu):
|
|||
|
||||
layout.separator()
|
||||
|
||||
OUTLINER_MT_context_menu.draw(self, context)
|
||||
OUTLINER_MT_context_menu.draw_common_operators(layout)
|
||||
|
||||
|
||||
class OUTLINER_MT_object(Menu):
|
||||
|
@ -303,11 +307,15 @@ class OUTLINER_MT_object(Menu):
|
|||
layout.operator("outliner.id_operation", text="Unlink").type = 'UNLINK'
|
||||
layout.separator()
|
||||
|
||||
layout.operator("outliner.collection_new", text="New Collection").nested = True
|
||||
|
||||
layout.separator()
|
||||
|
||||
layout.operator_menu_enum("outliner.id_operation", "type", text="ID Data")
|
||||
|
||||
layout.separator()
|
||||
|
||||
OUTLINER_MT_context_menu.draw(self, context)
|
||||
OUTLINER_MT_context_menu.draw_common_operators(layout)
|
||||
|
||||
|
||||
class OUTLINER_PT_filter(Panel):
|
||||
|
|
|
@ -1376,13 +1376,13 @@ static void outliner_draw_restrictbuts(uiBlock *block,
|
|||
ID *id = tselem->id;
|
||||
bGPDlayer *gpl = (bGPDlayer *)te->directdata;
|
||||
|
||||
if (soops->show_restrict_flags & SO_RESTRICT_VIEWPORT) {
|
||||
if (soops->show_restrict_flags & SO_RESTRICT_HIDE) {
|
||||
bt = uiDefIconButBitS(block,
|
||||
UI_BTYPE_ICON_TOGGLE,
|
||||
GP_LAYER_HIDE,
|
||||
0,
|
||||
ICON_HIDE_OFF,
|
||||
(int)(region->v2d.cur.xmax - restrict_offsets.viewport),
|
||||
(int)(region->v2d.cur.xmax - restrict_offsets.hide),
|
||||
te->ys,
|
||||
UI_UNIT_X,
|
||||
UI_UNIT_Y,
|
||||
|
|
Loading…
Reference in New Issue