You are here

function ajax_command_close_dialog in Brightcove Video Connect 7.2

Same name and namespace in other branches
  1. 7.7 brightcove.module \ajax_command_close_dialog()
  2. 7.3 brightcove_field/brightcove_field.module \ajax_command_close_dialog()
  3. 7.4 brightcove_field/brightcove_field.module \ajax_command_close_dialog()
  4. 7.5 brightcove_field/brightcove_field.module \ajax_command_close_dialog()
  5. 7.6 brightcove.module \ajax_command_close_dialog()

Creates a Drupal Ajax 'ui_close_dialog' command.

The 'dialog' command instructs the client to close a jQuery UI Dialog box.

This command is implemented by Drupal.ajax.prototype.commands.ui() defined in brightcove/brightcove_field/brightcove.js.

Parameters

$selector: Selector of the dialog that should be closed.

$data: Data to send on close, depends on dialog type.

$settings: TODO

$dialog_type: Type of dialog to close.

Return value

An array suitable for use with the ajax_render() function.

2 calls to ajax_command_close_dialog()
ajax_browse_dialog_close_callback in brightcove_field/brightcove_field.module
ajax_upload_dialog_close_callback in brightcove_field/brightcove_field.module

File

brightcove_field/brightcove_field.module, line 1418
Brightcove field module provides a Content Construction Kit module to developers, allowing them to browse videos in their Brightcove Studio and upload them.

Code

function ajax_command_close_dialog($selector = '<div>', $data, $settings = NULL, $dialog_type) {
  return array(
    'command' => 'ui_dialog_close',
    'selector' => $selector,
    'data' => $data,
    'settings' => $settings,
    'dialog_type' => $dialog_type,
  );
}