Oh wait, I think I found a way. In case anybody else wants to know, here it is...
In the PrefsDialogObject:
Bool MyPrefsDialog::SetDParameter(GeListNode *node, const DescID &id,const GeData &t_data,DESCFLAGS_SET &flags)
{
BaseContainer* bc = MyPlugin::GetPreferences();
if (!bc)
SUPER::SetDParameter(node, id, t_data, flags);
switch (id[0].id)
{
// If PREFS_MYPLUGIN_SOMEVALUE was changed, store value and notify plugin objects in all open documents.
case PREFS_MYPLUGIN_SOMEVALUE:
bc->SetInt32(PREFS_MYPLUGIN_SOMEVALUE, t_data.GetInt32());
flags |= DESCFLAGS_SET::PARAM_SET;
// Iterate open documents
for (BaseDocument *doc = GetFirstDocument(); doc; doc = doc->GetNext())
{
// Send broadcast message to each document, use unique ID
doc->MultiMessage(MULTIMSG_ROUTE::BROADCAST, MyPlugin::UNIQUE_ID_PREFS, nullptr);
}
GeUpdateUI();
return true;
}
return SUPER::SetDParameter(node, id, t_data, flags);
}
And then, in the plugin object:
Bool MyPluginObject::Message(GeListNode *node, Int32 type, void *data)
{
if (type == MyPlugin::UNIQUE_ID_PREFS)
{
GePrint("Aha! My prefs have changed!"_s);
return true;
}
return SUPER::Message(node, type, data);
}