activities/text/Complete. CompletePanel

The TextActivityBasePanel where Complete activities are played.

Constructor

new CompletePanel(act, ps, $divopt)

CompletePanel constructor

Parameters:
NameTypeAttributesDescription
actmodule:Activity.Activity

The Activity to which this Panel belongs

psmodule:JClicPlayer.JClicPlayer

Any object implementing the methods defined in the
PlayStation Java interface.

$divexternal:jQuery<optional>

The jQuery DOM element where this Panel will deploy

Extends

  • module:activities/text/TextActivityBasePanel.TextActivityBasePanel

Methods

$createTargetElement(_target, _$span) → {external:jQuery}

Creates a target DOM element for the provided target.

Parameters:
NameTypeDescription
_targetmodule:activities/text/TextActivityDocument.TextTarget

The target related to the DOM object to be created

_$spanexternal:jQuery
  • An initial DOM object (usually a span) that can be used
    to store the target, or replaced by another type of object.
Returns:
  • The jQuery DOM element loaded with the target data.
Type: 
external:jQuery

evaluatePanel() → {boolean}

Evaluates all the targets in this panel. This method is usually called from the Check button.

Returns:
  • true when all targets are OK, false otherwise.
Type: 
boolean

finishActivity(result)

Ordinary ending of the activity, usually called form processEvent

Parameters:
NameTypeDescription
resultboolean

true if the activity was successfully completed, false otherwise

startActivity()

Called when the activity starts playing