/**
  * Creates a RelatedItemEditor
  *
  * @param SiteSettings $settings
  * @param DataEditControl $controlling_editor
  * @param string $s_id
  * @param string $s_title
  * @param string $a_column_headings
  */
 public function __construct(SiteSettings $settings, DataEditControl $controlling_editor, $s_id, $s_title, $a_column_headings)
 {
     # Set up this control
     parent::__construct($settings, false);
     $this->SetXhtmlId($s_id);
     $this->SetNamingPrefix($controlling_editor->GetXhtmlId() . $s_id);
     $this->SetShowValidationErrors(false);
     $this->AddCssClass('relatedItemEditor');
     $this->AddCssClass(get_class($this));
     # Set up the editing table
     $this->table = new XhtmlTable();
     $this->table->SetCaption($s_title);
     $this->table->SetColumnGroupSizes(array(count($a_column_headings), 1));
     $colgroups = $this->table->GetColumnGroups();
     $colgroups[count($colgroups) - 1]->SetCssClass('action');
     $a_column_headings[] = 'Action';
     $o_header = new XhtmlRow($a_column_headings);
     $o_header->SetIsHeader(true);
     $this->table->AddRow($o_header);
     # Initialise variables
     $this->controlling_editor = $controlling_editor;
     $this->data_objects = new Collection();
     $this->a_rows_posted = array();
 }