Skip to content

Commit

Permalink
Revert "Don't use poll_file_object_drop in add-on"
Browse files Browse the repository at this point in the history
This reverts commit faf63b7.
  • Loading branch information
vanous committed Jul 22, 2024
1 parent faf63b7 commit 66f4b11
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions in_gdtf.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import traceback
from bpy_extras.io_utils import (
ImportHelper,
poll_file_object_drop,
)
from bpy.props import (
StringProperty,
Expand Down Expand Up @@ -142,6 +143,10 @@ class DMX_IO_FH_GDTF(bpy.types.FileHandler):
bl_import_operator = "dmx.import_gdtf_into_scene"
bl_file_extensions = ".gdtf"

@classmethod
def poll_drop(cls, context):
return poll_file_object_drop(context)


def menu_func_import(self, context):
self.layout.operator(DMX_OT_Import_GDTF.bl_idname, text="General Device Type Format (.gdtf) into BlenderDMX")
Expand Down
5 changes: 5 additions & 0 deletions in_out_mvr.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
from bpy_extras.io_utils import (
ImportHelper,
ExportHelper,
poll_file_object_drop,
)
from bpy.props import (
StringProperty,
Expand Down Expand Up @@ -77,6 +78,10 @@ class DMX_IO_FH_MVR(bpy.types.FileHandler):
bl_export_operator = "dmx.export_mvr_from_scene"
bl_file_extensions = ".mvr"

@classmethod
def poll_drop(cls, context):
return poll_file_object_drop(context)


def menu_func_export(self, context):
self.layout.operator(DMX_OT_Export_MVR.bl_idname, text="My Virtual Rig (.mvr) from BlenderDMX")
Expand Down

0 comments on commit 66f4b11

Please sign in to comment.