FastLED 3.10.9
Loading...
Searching...
No Matches

◆ isDriverEnabled() [2/2]

bool fl::ChannelManager::isDriverEnabled ( const IChannelDriver & driver) const

Enabled state of a driver instance, matched by pointer.

Note
Per-frame show paths use this instead of the name overload: no fl::string is built and no names are compared (#4799). Falls back to the name when this instance is not the registered one.

Definition at line 341 of file manager.cpp.hpp.

341 {
342 for (const auto& entry : mDrivers) {
343 if (entry.driver.get() == &driver) {
344 return entry.enabled;
345 }
346 }
347 // Not registered by instance (e.g. replaced by a same-name driver).
348 return isDriverEnabled(driver.getName().c_str());
349}
fl::vector< EngineEntry > mDrivers
Shared drivers sorted by priority descending (higher values first)
Definition manager.h:327
bool isDriverEnabled(const char *name) const FL_NO_EXCEPT
Check if a driver is enabled by name.

References fl::FL_NO_EXCEPT, isDriverEnabled(), and mDrivers.

+ Here is the call graph for this function: