Example #1
0
        private void BindControls(List <EventLogDto> eventLogs)
        {
            var rowId = (int)EventsLogTableView.SelectedRow;

            var listView = new SuperLogDataSource {
                Entries = eventLogs
            };

            EventsLogTableView.DataSource = listView;
            EventsLogTableView.ReloadData();

            if (rowId > -1 && eventLogs.Count > rowId)
            {
                EventsLogTableView.SelectRow(rowId, false);
            }
            else
            {
                if (eventLogs.Count > 0)
                {
                    EventsLogTableView.SelectRow(0, false);
                }
            }
            var td = (EventsLogTableView.Delegate as TableDelegate);

            if (td != null)
            {
                td.OnSelectionChange();
            }
            var hasEvents = eventLogs.Count > 0;

            SetButtonStatus(hasEvents);
            SetEventCounts(eventLogs);
        }
        void ReleaseDesignerOutlets()
        {
            if (LastUpdatedTimestamp != null)
            {
                LastUpdatedTimestamp.Dispose();
                LastUpdatedTimestamp = null;
            }

            if (AccountTextField != null)
            {
                AccountTextField.Dispose();
                AccountTextField = null;
            }

            if (AutoRefreshButton != null)
            {
                AutoRefreshButton.Dispose();
                AutoRefreshButton = null;
            }

            if (AutoRefreshIntervalComboBox != null)
            {
                AutoRefreshIntervalComboBox.Dispose();
                AutoRefreshIntervalComboBox = null;
            }

            if (ClearButton != null)
            {
                ClearButton.Dispose();
                ClearButton = null;
            }

            if (CloseButton != null)
            {
                CloseButton.Dispose();
                CloseButton = null;
            }

            if (CorrelationIdTextField != null)
            {
                CorrelationIdTextField.Dispose();
                CorrelationIdTextField = null;
            }

            if (DurationTextField != null)
            {
                DurationTextField.Dispose();
                DurationTextField = null;
            }

            if (EventCountTextField != null)
            {
                EventCountTextField.Dispose();
                EventCountTextField = null;
            }

            if (EventLogActionButton != null)
            {
                EventLogActionButton.Dispose();
                EventLogActionButton = null;
            }

            if (EventsCountTextField != null)
            {
                EventsCountTextField.Dispose();
                EventsCountTextField = null;
            }

            if (EventsLogTableView != null)
            {
                EventsLogTableView.Dispose();
                EventsLogTableView = null;
            }

            if (EventTypeTextField != null)
            {
                EventTypeTextField.Dispose();
                EventTypeTextField = null;
            }

            if (ExportButton != null)
            {
                ExportButton.Dispose();
                ExportButton = null;
            }

            if (FilterButton != null)
            {
                FilterButton.Dispose();
                FilterButton = null;
            }

            if (FilterStatusTextField != null)
            {
                FilterStatusTextField.Dispose();
                FilterStatusTextField = null;
            }

            if (FriendlyButton != null)
            {
                FriendlyButton.Dispose();
                FriendlyButton = null;
            }

            if (FriendlyScrollView != null)
            {
                FriendlyScrollView.Dispose();
                FriendlyScrollView = null;
            }

            if (FriendlyTextView != null)
            {
                FriendlyTextView.Dispose();
                FriendlyTextView = null;
            }

            if (FriendlyWebView != null)
            {
                FriendlyWebView.Dispose();
                FriendlyWebView = null;
            }

            if (ImportButton != null)
            {
                ImportButton.Dispose();
                ImportButton = null;
            }

            if (JsonButton != null)
            {
                JsonButton.Dispose();
                JsonButton = null;
            }

            if (JsonScrollView != null)
            {
                JsonScrollView.Dispose();
                JsonScrollView = null;
            }

            if (JsonTextField != null)
            {
                JsonTextField.Dispose();
                JsonTextField = null;
            }

            if (LevelIndicatorTextField != null)
            {
                LevelIndicatorTextField.Dispose();
                LevelIndicatorTextField = null;
            }

            if (ProviderTextField != null)
            {
                ProviderTextField.Dispose();
                ProviderTextField = null;
            }

            if (RefreshButton != null)
            {
                RefreshButton.Dispose();
                RefreshButton = null;
            }

            if (StartTextField != null)
            {
                StartTextField.Dispose();
                StartTextField = null;
            }

            if (StatusBannerTextField != null)
            {
                StatusBannerTextField.Dispose();
                StatusBannerTextField = null;
            }

            if (StatusButton != null)
            {
                StatusButton.Dispose();
                StatusButton = null;
            }

            if (StatusTextField != null)
            {
                StatusTextField.Dispose();
                StatusTextField = null;
            }
        }