Fix T48200 part 1: GP allows to access pie menus out of context
Only allow object mode pie to be spawned in 3D view.
This commit is contained in:
parent
e7b6392cd5
commit
7c3a79b484
Notes:
blender-bot
2023-02-14 19:48:42 +01:00
Referenced by issue #48200, GP allows to access pie menus out of context
|
@ -37,6 +37,10 @@ from bpy.props import EnumProperty
|
|||
class VIEW3D_PIE_object_mode(Menu):
|
||||
bl_label = "Mode"
|
||||
|
||||
@classmethod
|
||||
def poll(cls, context):
|
||||
return (context.space_data.type == 'VIEW_3D')
|
||||
|
||||
def draw(self, context):
|
||||
layout = self.layout
|
||||
|
||||
|
|
Loading…
Reference in New Issue