diff options
author | meta-androcto <meta.androcto1@gmail.com> | 2017-03-19 07:27:10 +0300 |
---|---|---|
committer | meta-androcto <meta.androcto1@gmail.com> | 2017-03-19 07:27:10 +0300 |
commit | e702810f3734d8f35b29843cfb44956f125d0da7 (patch) | |
tree | 043423880fc9d1aff39ac55cf0eb0144780980ee /space_view3d_pie_menus/pie_editor_switch_menu.py | |
parent | 6e2403042b62356691894c6fa671f7233e93d399 (diff) |
Update 3d Viewport pie menus: T50732
Diffstat (limited to 'space_view3d_pie_menus/pie_editor_switch_menu.py')
-rw-r--r-- | space_view3d_pie_menus/pie_editor_switch_menu.py | 43 |
1 files changed, 22 insertions, 21 deletions
diff --git a/space_view3d_pie_menus/pie_editor_switch_menu.py b/space_view3d_pie_menus/pie_editor_switch_menu.py index 2f206bf4..710c8fe1 100644 --- a/space_view3d_pie_menus/pie_editor_switch_menu.py +++ b/space_view3d_pie_menus/pie_editor_switch_menu.py @@ -65,22 +65,24 @@ class AreaPieEditor(Menu): bl_label = "Editor Switch" def draw(self, context): + layout = self.layout + pie = layout.menu_pie() # 4 - LEFT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="Text Editor", icon="TEXT").type = "TEXT_EDITOR" + pie.operator(SetAreaType.bl_idname, text="Text Editor", icon="TEXT").type = "TEXT_EDITOR" # 6 - RIGHT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="Outliner", icon="OOPS").type = "OUTLINER" + pie.menu(AreaTypePieAnim.bl_idname, text="Animation Editors", icon="ACTION") # 2 - BOTTOM - self.layout.menu_pie().operator("wm.call_menu_pie", text="More Types", icon="QUESTION").name = AreaTypePieOther.bl_idname + pie.operator(SetAreaType.bl_idname, text="Property", icon="BUTS").type = "PROPERTIES" # 8 - TOP - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="3D View", icon="MESH_CUBE").type = "VIEW_3D" + pie.operator(SetAreaType.bl_idname, text="3D View", icon="MESH_CUBE").type = "VIEW_3D" # 7 - TOP - LEFT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="UV/Image Editor", icon="IMAGE_COL").type = "IMAGE_EDITOR" + pie.operator(SetAreaType.bl_idname, text="UV/Image Editor", icon="IMAGE_COL").type = "IMAGE_EDITOR" # 9 - TOP - RIGHT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="Node Editor", icon="NODETREE").type = "NODE_EDITOR" + pie.operator(SetAreaType.bl_idname, text="Node Editor", icon="NODETREE").type = "NODE_EDITOR" # 1 - BOTTOM - LEFT - self.layout.menu_pie().operator("wm.call_menu_pie", text="Animation Pie", icon="ACTION").name = AreaTypePieAnim.bl_idname + pie.operator(SetAreaType.bl_idname, text="Outliner", icon="OOPS").type = "OUTLINER" # 3 - BOTTOM - RIGHT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="Property", icon="BUTS").type = "PROPERTIES" + pie.menu(AreaTypePieOther.bl_idname, text="More Editors", icon="QUESTION") class AreaTypePieOther(Menu): @@ -90,17 +92,16 @@ class AreaTypePieOther(Menu): def draw(self, context): # 4 - LEFT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="Logic Editor", icon="LOGIC").type = "LOGIC_EDITOR" + self.layout.operator(SetAreaType.bl_idname, text="Logic Editor", icon="LOGIC").type = "LOGIC_EDITOR" # 6 - RIGHT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="File Browser", icon="FILESEL").type = "FILE_BROWSER" + self.layout.operator(SetAreaType.bl_idname, text="File Browser", icon="FILESEL").type = "FILE_BROWSER" # 2 - BOTTOM - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="Python Console", icon="CONSOLE").type = "CONSOLE" + self.layout.operator(SetAreaType.bl_idname, text="Python Console", icon="CONSOLE").type = "CONSOLE" # 8 - TOP - self.layout.menu_pie().operator("wm.call_menu_pie", text="Back", icon="BACK").name = AreaPieEditor.bl_idname # 7 - TOP - LEFT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="User Setting", icon="PREFERENCES").type = "USER_PREFERENCES" + self.layout.operator(SetAreaType.bl_idname, text="User Setting", icon="PREFERENCES").type = "USER_PREFERENCES" # 9 - TOP - RIGHT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="Info", icon="INFO").type = "INFO" + self.layout.operator(SetAreaType.bl_idname, text="Info", icon="INFO").type = "INFO" # 1 - BOTTOM - LEFT # 3 - BOTTOM - RIGHT @@ -125,19 +126,19 @@ class AreaTypePieAnim(Menu): def draw(self, context): # 4 - LEFT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="NLA Editor", icon="NLA").type = "NLA_EDITOR" + self.layout.operator(SetAreaType.bl_idname, text="NLA Editor", icon="NLA").type = "NLA_EDITOR" # 6 - RIGHT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="DopeSheet", icon="ACTION").type = "DOPESHEET_EDITOR" + self.layout.operator(SetAreaType.bl_idname, text="DopeSheet", icon="ACTION").type = "DOPESHEET_EDITOR" # 2 - BOTTOM - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="Graph Editor", icon="IPO").type = "GRAPH_EDITOR" + self.layout.operator(SetAreaType.bl_idname, text="Graph Editor", icon="IPO").type = "GRAPH_EDITOR" # 8 - TOP - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="Timeline", icon="TIME").type = "TIMELINE" + self.layout.operator(SetAreaType.bl_idname, text="Timeline", icon="TIME").type = "TIMELINE" # 7 - TOP - LEFT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="Video Sequence Editor", icon="SEQUENCE").type = "SEQUENCE_EDITOR" + self.layout.operator(SetAreaType.bl_idname, text="Video Sequence Editor", icon="SEQUENCE").type = "SEQUENCE_EDITOR" # 9 - TOP - RIGHT - self.layout.menu_pie().operator(SetAreaType.bl_idname, text="Video Clip Editor", icon="RENDER_ANIMATION").type = "CLIP_EDITOR" + self.layout.operator(SetAreaType.bl_idname, text="Video Clip Editor", icon="RENDER_ANIMATION").type = "CLIP_EDITOR" # 1 - BOTTOM - LEFT - self.layout.menu_pie().operator("wm.call_menu_pie", text="Back", icon="BACK").name = PieEditor.bl_idname + self.layout.operator("wm.call_menu_pie", text="Back", icon="BACK").name = PieEditor.bl_idname # 3 - BOTTOM - RIGHT classes = ( |