Each panel with registerForRefresh = true causes registration of another "LAM-RefreshPanel" callback. There is no check-for-duplicates logic in CALLBACK_MANAGER, it's plain table.insert.
If N panels registerForRefresh, then whenever any of those panels is shown, or a control value changed, RefreshPanel is called N-times with the same argument (not all N panels are updated, only the one that was shown, or its value changed, is updated N times).
I think you can safely cm:RegisterCallback right after the definition of RefreshPanel, no need to defer that to onLoaded or later. |