CKEditor 4 Documentation

CKEDITOR.ui.dialog.button

Hierarchy

CKEDITOR.ui.dialog.uiElement
CKEDITOR.ui.dialog.button

Subclasses

Files

A button with a label inside.

Defined By

Properties

CKEDITOR.ui.dialog.button
view source
: Object

Defines the onChange event and onClick for button element definitions.

Defines the onChange event and onClick for button element definitions.

Overrides: CKEDITOR.ui.dialog.uiElement.eventProcessors

Defined By

Methods

CKEDITOR.ui.dialog.button
view source
new( dialog, elementDefinition, htmlList ) : CKEDITOR.ui.dialog.button
Creates a button class instance. ...

Creates a button class instance.

Parameters

  • dialog : CKEDITOR.dialog

    Parent dialog window object.

  • elementDefinition : CKEDITOR.dialog.definition.uiElement

    The element definition. Accepted fields:

    • label (Required) The button label.
    • disabled (Optional) Set to true if you want the button to appear in the disabled state.
  • htmlList : Array

    List of HTML code to output to.

Returns

Overrides: CKEDITOR.ui.dialog.uiElement.constructor

CKEDITOR.ui.dialog.button
view source
( )
Handler for the element's access key down event. ...

Handler for the element's access key down event. Simulates a mouse down to the button.

Overrides: CKEDITOR.ui.dialog.uiElement.accessKeyDown

CKEDITOR.ui.dialog.button
view source
( )
Handler for the element's access key up event. ...

Handler for the element's access key up event. Simulates a click to the button.

Overrides: CKEDITOR.ui.dialog.uiElement.accessKeyUp

CKEDITOR.ui.dialog.button
view source
( ) : Object
Simulates a click to the button. ...

Simulates a click to the button.

Returns

  • Object

    Return value of the click event.

CKEDITOR.ui.dialog.button
view source
( )
Disables the button. ...

Disables the button.

Overrides: CKEDITOR.ui.dialog.uiElement.disable

CKEDITOR.ui.dialog.button
view source
( )
Enables the button. ...

Enables the button.

Overrides: CKEDITOR.ui.dialog.uiElement.enable

Puts the focus to the UI object. ...

Puts the focus to the UI object. Switches tabs if the UI object isn't in the active tab page.

uiElement.focus();

Returns

Gets the parent dialog object containing this UI element. ...

Gets the parent dialog object containing this UI element.

var dialog = uiElement.getDialog();

Returns

Gets the root DOM element of this dialog UI object. ...

Gets the root DOM element of this dialog UI object.

uiElement.getElement().hide();

Returns

Gets the DOM element that the user inputs values. ...

Gets the DOM element that the user inputs values.

This function is used by setValue, getValue and focus. It should be overrided in child classes where the input element isn't the root element.

var rawValue = textInput.getInputElement().$.value;

Returns

Gets the current value of this dialog UI object. ...

Gets the current value of this dialog UI object.

var myValue = uiElement.getValue();

Returns

  • Object

    The current value.

Tells whether the UI object's value has changed. ...

Tells whether the UI object's value has changed.

if ( uiElement.isChanged() )
    confirm( 'Value changed! Continue?' );

Returns

  • Boolean

    true if changed, false if not changed.

CKEDITOR.ui.dialog.button
view source
( ) : Boolean
Checks whether a field is enabled. ...

Checks whether a field is enabled. Fields can be disabled by using the disable method and enabled by using the enable method.

Returns

  • Boolean

Overrides: CKEDITOR.ui.dialog.uiElement.isEnabled

Determines whether an UI element is focus-able or not. ...

Determines whether an UI element is focus-able or not. Focus-able is defined as being both visible and enabled.

Returns

  • Boolean

    Whether the UI element can be focused.

CKEDITOR.ui.dialog.button
view source
( ) : Boolean
Checks whether a field is visible. ...

Checks whether a field is visible.

Returns

  • Boolean

Overrides: CKEDITOR.ui.dialog.uiElement.isVisible

Registers the on* event handlers defined in the element definition. ...

Registers the on* event handlers defined in the element definition.

The default behavior of this function is:

  1. If the on* event is defined in the class's eventProcesors list, then the registration is delegated to the corresponding function in the eventProcessors list.
  2. If the on* event is not defined in the eventProcessors list, then register the event handler under the corresponding DOM event of the UI element's input DOM element (as defined by the return value of getInputElement).

This function is only called at UI element instantiation, but can be overridded in child classes if they require more flexibility.

Parameters

Returns

Selects the parent tab of this element. ...

Selects the parent tab of this element. Usually called by focus() or overridden focus() methods.

focus : function() {
    this.selectParentTab();
    // do something else.
}

Returns

Sets the value of this dialog UI object. ...

Sets the value of this dialog UI object.

uiElement.setValue( 'Dingo' );

Parameters

  • value : Object

    The new value.

  • noChangeEvent : Boolean

    Internal commit, to supress change event on this element.

Returns

Defined By

Events

Fired when the value of the uiElement is changed. ...

Fired when the value of the uiElement is changed.

Parameters