Changeset 2304


Ignore:
Timestamp:
Jan 10, 2011, 11:05:07 AM (11 years ago)
Author:
nolte
Message:

Added Tooltips to the Keysearcher Statistics view:
Users -> Subtreebar-Tooltip shows last Date
Machines -> Bar-Tooltip shows Usernames working with this Maschine

Reorganised some code.

Location:
trunk/CrypPlugins/KeySearcher
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/CrypPlugins/KeySearcher/KeySearcher.cs

    r2301 r2304  
    12951295            ((QuickWatch)QuickWatchPresentation).StatisticsPresentation.Statistics = statistic;
    12961296            ((QuickWatch)QuickWatchPresentation).StatisticsPresentation.MachineHierarchy = maschinehierarchie;
    1297 //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    1298 //TODO "maschinehierarchie" in Quickwatch einfügen. Bereits sortiert ;-) Sum = Anzahl Chunks total ; Hostname = Computername ; Users = String mit Avatarnamen der User dieses Rechners
    1299 //Anmerkung: Dictionaries lassen sich nicht sortieren.
    1300 //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    13011297
    13021298            updateToplist();
     
    13761372                        maschinehierarchie[mid].Sum = maschinehierarchie[mid].Sum + Maschines[mid].Count;
    13771373                        maschinehierarchie[mid].Hostname = Maschines[mid].Hostname;
    1378                         maschinehierarchie[mid].Users = maschinehierarchie[mid].Users + avatar + ", ";
     1374                        maschinehierarchie[mid].Users = maschinehierarchie[mid].Users + avatar + " | ";
    13791375                    }
    13801376                    else
    13811377                    {
    13821378                        //else make a new entry
    1383                         maschinehierarchie.Add(mid, new Maschinfo() { Sum = Maschines[mid].Count , Hostname = Maschines[mid].Hostname , Users = "" + avatar + ", "});
     1379                        maschinehierarchie.Add(mid, new Maschinfo() { Sum = Maschines[mid].Count , Hostname = Maschines[mid].Hostname , Users = "| " + avatar + " | "});
    13841380                    }
    13851381                }
  • trunk/CrypPlugins/KeySearcher/Presentation/Controls/StatisticsPresentation.xaml

    r2295 r2304  
    2727                        <HierarchicalDataTemplate.ItemTemplate>
    2828                            <DataTemplate>
    29                                 <StackPanel Orientation="Horizontal" Margin="1">
     29                                <StackPanel Orientation="Horizontal" Margin="1" ToolTip="{Binding Path=Value.Date}">
    3030                                    <Grid>
    3131                                        <ProgressBar Foreground="{Binding RelativeSource={RelativeSource FindAncestor,  AncestorLevel=2, AncestorType={x:Type TreeViewItem}},Path=(ItemsControl.AlternationIndex),Converter={StaticResource ResourceKey=TeamsBackgroundConverter}}" Value="{Binding Path=Value.Count, Mode=OneTime, Converter={StaticResource ResourceKey=InformationToProgressConverter2}}" Width="{Binding ElementName=statisticsTree, Path=ActualWidth, Converter={StaticResource ResourceKey=WidthConverter}}" Maximum="1" />
     
    6666                        </HierarchicalDataTemplate.ItemTemplate>-->
    6767                       
    68                         <StackPanel Orientation="Horizontal" Margin="1" ToolTip="{Binding Path=Key}">
     68                        <StackPanel Orientation="Horizontal" Margin="1" ToolTip="{Binding Path=Value.Users}">
    6969                            <Grid>
    7070                                <ProgressBar Value="{Binding Path=Value.Sum, Mode=OneTime, Converter={StaticResource ResourceKey=MachineSumToProgressConverter}}" Width="{Binding ElementName=machineTree, Path=ActualWidth, Converter={StaticResource ResourceKey=WidthConverter}}" Maximum="1" />
  • trunk/CrypPlugins/KeySearcher/Presentation/Controls/StatisticsPresentation.xaml.cs

    r2295 r2304  
    6161                Dispatcher.Invoke(DispatcherPriority.Normal, (SendOrPostCallback)delegate
    6262                                                {
    63                                                     var orderedstats = machineHierarchy.OrderByDescending((x) => x.Value.Sum);
    64                                                     machineTree.DataContext = orderedstats;
     63                                                    //var orderedstats = machineHierarchy.OrderByDescending((x) => x.Value.Sum);
     64                                                    machineTree.DataContext = machineHierarchy;
    6565                                                    machineTree.Items.Refresh();
    6666                                                }, null);
Note: See TracChangeset for help on using the changeset viewer.