GxTitle.bindCancelNode

Syntax

bindCancelNode(domNode: HTMLElement; addEvent: Boolean);

Parameters

domNode. DOM node.

addEvent. Indicates if a handler of the event of clicking a DOM node is added. If the parameter is set to True, a handler of the event of clicking a mouse is added.

Description

The bindCancelNode method cancels disabling of title edit mode on clicking the specified DOM node.

Example

To execute the example, the HTML page must contain the ExpressBox component named expressBox (see Example of Creating the ExpressBox Component). To show the title, click the Title button on the Home tab. Cancel disabling of title edit mode on clicking the a DOM node of the ExpressBox component:

// Get title
var title = expressBox.getDataView().getTitleView();
// Cancel disabling of title edit mode
title.bindCancelNode(expressBox.getDomNode(), True);

As a result if title edit mode is enabled, clicking the DOM node of the ExpressBox component does not cause disabling of edit mode.

Cancel disabling of title edit mode on clicking the a DOM node of the ExpressBox component:

// Disable title edit mode
title.unbindCancelNode(expressBox.getDomNode(), True);

As a result if title edit mode is enabled, clicking the DOM node of the ExpressBox component causes disabling of edit mode.

See also:

GxTitle