| 192 | } |
| 193 | |
| 194 | Ref<ResourceImportMetadatav2> copy_imd_v2(Ref<ResourceImportMetadatav2> p_cf) { |
| 195 | Ref<ResourceImportMetadatav2> r_imd; |
| 196 | r_imd.instantiate(); |
| 197 | r_imd->set_editor(p_cf->get_editor()); |
| 198 | int src_count = p_cf->get_source_count(); |
| 199 | for (int i = 0; i < src_count; i++) { |
| 200 | r_imd->add_source(p_cf->get_source_path(i), p_cf->get_source_md5(i)); |
| 201 | } |
| 202 | List<String> r_options; |
| 203 | p_cf->get_options(&r_options); |
| 204 | for (auto E = r_options.front(); E; E = E->next()) { |
| 205 | r_imd->set_option(E->get(), p_cf->get_option(E->get())); |
| 206 | } |
| 207 | return r_imd; |
| 208 | } |
| 209 | |
| 210 | Ref<ImportInfo> ImportInfo::copy(const Ref<ImportInfo> &p_iinfo) { |
| 211 | ERR_FAIL_COND_V_MSG(p_iinfo.is_null(), Ref<ImportInfo>(), "ImportInfo is null"); |
no test coverage detected