Welcome to mirror list, hosted at ThFree Co, Russian Federation.

space_outliner.py « ui « release - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: a87b1e21a0f6245324b5ec66ac48ceea8b4b36ff (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35

import bpy

class OUTLINER_HT_header(bpy.types.Header):
	__space_type__ = "OUTLINER"
	__idname__ = "OUTLINER_HT_header"

	def draw(self, context):
		so = context.space_data
		layout = self.layout

		layout.template_header(context)

		if context.area.show_menus:
			row = layout.row(align=True)
			row.itemM(context, "OUTLINER_MT_view")
			
		row = layout.row(align=True)
		row.itemR(so, "display_mode")

class OUTLINER_MT_view(bpy.types.Menu):
	__space_type__ = "OUTLINER"
	__label__ = "View"

	def draw(self, context):
		layout = self.layout
		so = context.space_data

		layout.column()
		row.itemR(so, "show_restriction_columns")
		#layout.itemO("TEXT_OT_new")

bpy.types.register(OUTLINER_HT_header)
bpy.types.register(OUTLINER_MT_view)