protected override void OnPreRender(EventArgs e) { // Display information on empty data bool isEmpty = DataHelper.DataSourceIsEmpty(DataSource); if (isEmpty) { plcViewArea.Visible = false; } else { lblInfo.Visible = false; plcViewArea.Visible = true; } // If info text is set display it if (!string.IsNullOrEmpty(InfoText)) { lblInfo.Text = InfoText; lblInfo.Visible = true; } else if (isEmpty) { lblInfo.Text = (IsCopyMoveLinkDialog ? GetString("media.copymove.empty") : CMSDialogHelper.GetNoItemsMessage(Config, SourceType)); lblInfo.Visible = true; } // Hide column 'Update' in media libraries if (((SourceType == MediaSourceEnum.MediaLibraries) || (SourceType == MediaSourceEnum.Content)) && !columnUpdateVisible) { if (gridList.NamedColumns.ContainsKey("extedit")) { gridList.NamedColumns["extedit"].Visible = false; } } base.OnPreRender(e); }