Picture of iqbal
Registered 5 years 278 days
iqbal Thursday, 23 May 2024, 04:27 PM
How to intercept changed value of ConfigItem in ConfigContext
Hi
I have a question about ConfigContext described here: innovaphone SDK - config implementation

As mentioned in SDK there are two callback functions that are called when some value is changed:
virtual void ConfigChanged() {}
virtual void ConfigChangedUnmanaged() {}

My question is how can I know which of ConfigItem is updated or can I intercept changed value as key value pair. Another option would be to have callback functions with parameters like:

virtual void ConfigChanged(const char* key, const char* value) {}
virtual void ConfigChangedUnmanaged(const char* key, const char* value) {}

Kind Regards
Iqbal
Andreas Fink
Moderator Registered 13 years 109 days
Andreas Fink (innovaphone) Friday, 24 May 2024, 11:26 AM
Re: How to intercept changed value of ConfigItem in ConfigContext
Hello Iqbal,

the public function Changed on a ConfigItem returns true, if the item was changed. This function should be called from ConfigChanged callback. You have to iterate over all items or check only specific items, you want to monitor explicitly.


Best Regards
Andreas Fink
← You can define your color theme preference here