| 194 | } |
| 195 | |
| 196 | static std::pair<obs_property_t *, properties_t> |
| 197 | findListPropertyById(const obs_source_t *source, const std::string &id) |
| 198 | { |
| 199 | // Note: |
| 200 | // Using obs_source_properties() here might cause flickering for some |
| 201 | // sources, as this will call obs_properties_apply_settings() |
| 202 | // implicitly. |
| 203 | // So, we use obs_get_source_properties() instead. |
| 204 | // |
| 205 | // 20250617: This might cause issues with the move plugin as it doesn't |
| 206 | // handle obs_get_source_properties() properly in the move filter |
| 207 | auto properties = obs_get_source_properties(obs_source_get_id(source)); |
| 208 | if (!properties) { |
| 209 | return {nullptr, properties_t(nullptr, obs_properties_destroy)}; |
| 210 | } |
| 211 | auto property = obs_properties_first(properties); |
| 212 | return {findListPropertyByIdHelper(property, id), |
| 213 | properties_t(properties, obs_properties_destroy)}; |
| 214 | } |
| 215 | |
| 216 | static std::pair<obs_property_t *, properties_t> |
| 217 | findListPropertyById(const OBSWeakSource &ws, const std::string &id) |
no test coverage detected