diff --git a/EgtCustomWindow.vb b/EgtCustomWindow.vb index 177b545..ede38fb 100644 --- a/EgtCustomWindow.vb +++ b/EgtCustomWindow.vb @@ -166,6 +166,14 @@ Public Class EgtCustomWindow DefaultStyleKeyProperty.OverrideMetadata(GetType(EgtCustomWindow), New FrameworkPropertyMetadata(GetType(EgtCustomWindow))) End Sub + Sub New() + + End Sub + + Sub New(Owner As Window) + Me.Owner = Owner + End Sub + Public Overrides Sub OnApplyTemplate() MyBase.OnApplyTemplate() m_IsResizable = IsResizable diff --git a/EgtFloating/EgtFloatingManager.vb b/EgtFloating/EgtFloatingManager.vb index e8ea0c4..8daff84 100644 --- a/EgtFloating/EgtFloatingManager.vb +++ b/EgtFloating/EgtFloatingManager.vb @@ -85,10 +85,19 @@ Namespace EgtFloating End Sub Private Sub Me_Loaded(sender As Object, e As System.Windows.RoutedEventArgs) Handles Me.Loaded - m_ParentWindow = Utility.FindAncestor(Of Window)(Me) - If TypeOf Me.Items(Me.Items.Count - 1) Is EgtFloatingTray Then + 'm_ParentWindow = Utility.FindAncestor(Of Window)(Me) + m_ParentWindow = Window.GetWindow(Me) + If Me.Items.Count > 0 AndAlso TypeOf Me.Items(Me.Items.Count - 1) Is EgtFloatingTray Then LastChildFill = False End If + ' PERMETTE DI SPOSTARE LE WINDOW TRAY NEL CASO VENGA SPOSTATA LA MAINWINDOW!!!!!!! + 'For TrayIndex = 0 To Me.Items.Count - 1 + ' If TypeOf Me.Items(TrayIndex) Is EgtFloatingTray Then + ' Dim TrayItem As EgtFloatingTray = DirectCast(Me.Items(TrayIndex), EgtFloatingTray) + ' AddHandler ParentWindow.LocationChanged, AddressOf TrayItem.Me_LocationChanged + ' AddHandler ParentWindow.SizeChanged, AddressOf TrayItem.Me_DimensionChanged + ' End If + 'Next End Sub Private Sub Me_Unloaded(sender As Object, e As System.Windows.RoutedEventArgs) Handles Me.Unloaded diff --git a/EgtFloating/EgtFloatingTray.vb b/EgtFloating/EgtFloatingTray.vb index 324205e..76a0803 100644 --- a/EgtFloating/EgtFloatingTray.vb +++ b/EgtFloating/EgtFloatingTray.vb @@ -89,13 +89,13 @@ Namespace EgtFloating m_TrayWindow.Visibility = Windows.Visibility.Hidden End Sub - Private Sub Me_LocationChanged() + Friend Sub Me_LocationChanged() Dim pos As Point = Me.PointToScreen(New Point(0, 0)) m_TrayWindow.Top = pos.Y m_TrayWindow.Left = pos.X End Sub - Private Sub Me_DimensionChanged() + Friend Sub Me_DimensionChanged() ' Aggiorna le massime dimensioni del contenuto al cambiare della dimensione della Tray. ' NON TIENE CONTO DELLE TRAY CON PIU' DI UN ELEMENTO!! For Index As Integer = 0 To Me.Items.Count - 1 diff --git a/EgtWPFLib5.vbproj b/EgtWPFLib5.vbproj index 12a07bc..e488792 100644 --- a/EgtWPFLib5.vbproj +++ b/EgtWPFLib5.vbproj @@ -94,6 +94,15 @@ + + EgtMachGroupPanelV.xaml + + + + NewMachGroupWndV.xaml + + + @@ -113,6 +122,8 @@ Settings.settings True + + VbMyResourcesResXFileCodeGenerator Resources.Designer.vb @@ -137,6 +148,14 @@ Designer MSBuild:Compile + + MSBuild:Compile + Designer + + + MSBuild:Compile + Designer + MSBuild:Compile Designer diff --git a/MachGroupPanel/EgtMachGroupPanelV.xaml b/MachGroupPanel/EgtMachGroupPanelV.xaml new file mode 100644 index 0000000..7649e2f --- /dev/null +++ b/MachGroupPanel/EgtMachGroupPanelV.xaml @@ -0,0 +1,100 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +