fdo#80501: Ensure that we notify each listener only once.

Change-Id: If2ce4643ff58c7c2ba326d749698dd5196a108dc
(cherry picked from commit b2ee0235e88dc4da715b5766295ed88f27974fbd)
Reviewed-on: https://gerrit.libreoffice.org/10645
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>