# HG changeset patch # User stevenhollidge # Date 1335443015 -3600 # Node ID 8bb84cc9ba3f07afa44f78cf414c9ebf22965a2e # Parent 2084cfd89b802a9c257ed451813a99846b4dda60 Clear out rubbish diff -r 2084cfd89b80 -r 8bb84cc9ba3f Glimpse/Glimpse Controls/BrokenBindingsViewer.xaml --- a/Glimpse/Glimpse Controls/BrokenBindingsViewer.xaml Tue Apr 24 00:53:56 2012 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,9 +0,0 @@ - - - - - - - diff -r 2084cfd89b80 -r 8bb84cc9ba3f Glimpse/Glimpse Controls/BrokenBindingsViewer.xaml.vb --- a/Glimpse/Glimpse Controls/BrokenBindingsViewer.xaml.vb Tue Apr 24 00:53:56 2012 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,79 +0,0 @@ -Imports System.Reflection -Imports System.Windows.Data -Partial Public Class BrokenBindingsViewer - Inherits UserControl - - Public Sub New() - InitializeComponent() - End Sub - - Private Sub BrokenBindings_Loaded(ByVal sender As Object, ByVal e As System.Windows.RoutedEventArgs) Handles Me.Loaded - Me.icBrokenBindings.Items.Clear() - LoadBrokenBindings(GlimpseService.CreateInstance.RootVisual) - End Sub - - Private Sub LoadBrokenBindings(ByVal uie As UIElement) - - Dim fwe As FrameworkElement = TryCast(uie, FrameworkElement) - - If fwe IsNot Nothing Then - - For Each fi As FieldInfo In fwe.GetType.GetFields(BindingFlags.Public Or BindingFlags.FlattenHierarchy Or BindingFlags.Instance Or BindingFlags.Static) - - If fi.FieldType Is GetType(DependencyProperty) Then - - Dim be As BindingExpression = fwe.GetBindingExpression(DirectCast(fi.GetValue(Nothing), DependencyProperty)) - - If be IsNot Nothing AndAlso be.ParentBinding.Source Is Nothing AndAlso be.ParentBinding.RelativeSource Is Nothing Then - - Dim bolIsInherited As Boolean = False - - If fwe.DataContext IsNot Nothing AndAlso Not String.IsNullOrEmpty(be.ParentBinding.Path.Path) Then - - For Each p As PropertyInfo In fwe.DataContext.GetType.GetProperties(BindingFlags.Public Or BindingFlags.FlattenHierarchy Or BindingFlags.Static Or BindingFlags.Instance) - - If String.Compare(p.Name, be.ParentBinding.Path.Path) = 0 Then - bolIsInherited = True - Exit For - End If - - Next - - End If - - If bolIsInherited Then - Exit For - End If - - 'this code handles empty bindings on the Button controls - 'I'll have to look into why the Button has an empty or unresolved binding - If fwe.Name = "" AndAlso fwe.GetType.Name = "TextBlock" AndAlso fi.Name = "TextProperty" AndAlso be.ParentBinding.Path.Path = "" Then - Exit For - End If - - Dim objBrokenBinding As New BrokenBinding(fwe.Name, fwe.GetType.Name, fi.Name, be.ParentBinding.Path.Path) - Me.icBrokenBindings.Items.Add(objBrokenBinding) - System.Diagnostics.Debug.WriteLine(String.Format("Broken Binding - ", objBrokenBinding.ToString)) - End If - - End If - - Next - - Dim children As Integer = VisualTreeHelper.GetChildrenCount(fwe) - - For intX As Integer = 0 To children - 1 - - Dim child As FrameworkElement = TryCast(VisualTreeHelper.GetChild(fwe, intX), FrameworkElement) - - If child IsNot Nothing Then - LoadBrokenBindings(child) - End If - - Next - - End If - - End Sub - -End Class diff -r 2084cfd89b80 -r 8bb84cc9ba3f Glimpse/Glimpse Controls/ExceptionsViewer.xaml --- a/Glimpse/Glimpse Controls/ExceptionsViewer.xaml Tue Apr 24 00:53:56 2012 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,54 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -