Ejemplo n.º 1
0
 private void CopyGamparseClick(object sender, RoutedEventArgs e)
 {
     try
     {
         var    export = DataGridUtils.BuildExportData(dataGrid);
         string result = TextFormatUtils.BuildGamparseList(export.Item1, export.Item2, titleLabel.Content as string);
         Clipboard.SetDataObject(result);
     }
     catch (ArgumentNullException ane)
     {
         Clipboard.SetDataObject("EQ Log Parser Error: Failed to create BBCode\r\n");
         LOG.Error(ane);
     }
     catch (ExternalException ex)
     {
         LOG.Error(ex);
     }
 }
Ejemplo n.º 2
0
        private void CreateImageClick(object sender, RoutedEventArgs e)
        {
            // lame workaround to toggle scrollbar to fix UI
            dataGrid.IsEnabled = false;
            dataGrid.SelectedItems.Clear();
            dataGrid.VerticalScrollBarVisibility   = ScrollBarVisibility.Visible;
            dataGrid.HorizontalScrollBarVisibility = ScrollBarVisibility.Visible;

            Task.Delay(50).ContinueWith((bleh) =>
            {
                Dispatcher.InvokeAsync(() =>
                {
                    dataGrid.VerticalScrollBarVisibility   = ScrollBarVisibility.Auto;
                    dataGrid.HorizontalScrollBarVisibility = ScrollBarVisibility.Hidden;
                    SpellRowsView.ToList().ForEach(spr => spr["IconColor"] = EMPTYICON);
                    dataGrid.Items.Refresh();
                    Task.Delay(50).ContinueWith((bleh2) => Dispatcher.InvokeAsync(() =>
                    {
                        DataGridUtils.CreateImage(dataGrid, titleLabel);
                        SpellRowsView.ToList().ForEach(spr => spr["IconColor"] = ACTIVEICON);
                    }), TaskScheduler.Default);
                });
            }, TaskScheduler.Default);
        }
Ejemplo n.º 3
0
        private void CreateImageClick(object sender, RoutedEventArgs e)
        {
            // lame workaround to toggle scrollbar to fix UI
            dataGrid.IsEnabled    = false;
            dataGrid.SelectedItem = null;
            dataGrid.VerticalScrollBarVisibility   = ScrollBarVisibility.Visible;
            dataGrid.HorizontalScrollBarVisibility = ScrollBarVisibility.Visible;

            Task.Delay(50).ContinueWith((bleh) =>
            {
                Dispatcher.InvokeAsync(() =>
                {
                    dataGrid.VerticalScrollBarVisibility   = ScrollBarVisibility.Auto;
                    dataGrid.HorizontalScrollBarVisibility = ScrollBarVisibility.Hidden;
                    dataGrid.Items.Refresh();
                    Task.Delay(50).ContinueWith((bleh2) => Dispatcher.InvokeAsync(() => DataGridUtils.CreateImage(dataGrid, titleLabel)), TaskScheduler.Default);
                });
            }, TaskScheduler.Default);
        }
Ejemplo n.º 4
0
 private void CopyCsvClick(object sender, RoutedEventArgs e)
 {
     DataGridUtils.CopyCsvFromTable(dataGrid, titleLabel.Content.ToString());
 }
Ejemplo n.º 5
0
 private void UnselectAllClick(object sender, RoutedEventArgs e) => DataGridUtils.UnselectAll(sender as FrameworkElement);
Ejemplo n.º 6
0
 internal void DataGridSelectAllClick(object sender, RoutedEventArgs e) => DataGridUtils.SelectAll(sender as FrameworkElement);
Ejemplo n.º 7
0
 internal void CopyCsvClick(object sender, RoutedEventArgs e) => DataGridUtils.CopyCsvFromTable(TheDataGrid, TheTitle.Content.ToString());