File tree Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -52,8 +52,13 @@ void initialize_minimp3_module(ModuleInitializationLevel p_level) {
5252 ResourceFormatImporter::get_singleton ()->add_importer (mp3_import);
5353 }
5454
55+ ClassDB::APIType prev_api = ClassDB::get_current_api ();
56+ ClassDB::set_current_api (ClassDB::API_EDITOR);
57+
5558 // Required to document import options in the class reference.
5659 GDREGISTER_CLASS (ResourceImporterMP3);
60+
61+ ClassDB::set_current_api (prev_api);
5762#endif
5863
5964 GDREGISTER_CLASS (AudioStreamMP3);
Original file line number Diff line number Diff line change @@ -48,8 +48,13 @@ void initialize_vorbis_module(ModuleInitializationLevel p_level) {
4848 ResourceFormatImporter::get_singleton ()->add_importer (ogg_vorbis_importer);
4949 }
5050
51+ ClassDB::APIType prev_api = ClassDB::get_current_api ();
52+ ClassDB::set_current_api (ClassDB::API_EDITOR);
53+
5154 // Required to document import options in the class reference.
5255 GDREGISTER_CLASS (ResourceImporterOggVorbis);
56+
57+ ClassDB::set_current_api (prev_api);
5358#endif
5459
5560 GDREGISTER_CLASS (AudioStreamOggVorbis);
You can’t perform that action at this time.
0 commit comments