From bf633543add4ae8cbb03750b4dc941616309482f Mon Sep 17 00:00:00 2001 From: Oliver Tacke Date: Mon, 20 Sep 2021 13:36:50 +0200 Subject: [PATCH] Set activity started only if Column is main content --- scripts/h5p-column.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/scripts/h5p-column.js b/scripts/h5p-column.js index 24b16eb..bec09d2 100644 --- a/scripts/h5p-column.js +++ b/scripts/h5p-column.js @@ -488,7 +488,10 @@ H5P.Column = (function (EventDispatcher) { createHTML(); } - self.setActivityStarted(); + // Expect parent to set activity started when Column is actually shown + if (typeof self.isRoot === 'function' && self.isRoot()) { + self.setActivityStarted(); + } } Column.prototype = Object.create(EventDispatcher.prototype);