mirror of
				https://github.com/chev2/botw-toolset.git
				synced 2025-10-30 08:12:17 +00:00 
			
		
		
		
	Update Dashboard
TabSelect is now a single method, dashboard entries are centered and wrap properly
This commit is contained in:
		
							parent
							
								
									a1a83285f8
								
							
						
					
					
						commit
						335d7bedf1
					
				
					 2 changed files with 43 additions and 35 deletions
				
			
		|  | @ -10,36 +10,38 @@ | ||||||
|         <TabControl x:Name="TabController" Margin="10,10,10,41"> |         <TabControl x:Name="TabController" Margin="10,10,10,41"> | ||||||
|             <TabItem Header="Dashboard"> |             <TabItem Header="Dashboard"> | ||||||
|                 <Grid Background="#2C343E"> |                 <Grid Background="#2C343E"> | ||||||
|                     <Label Content="Dashboard" Margin="10,10,10,0" VerticalAlignment="Top" Height="48" FontSize="28" VerticalContentAlignment="Center" FontFamily="Segoe UI Light"/> |                     <Label Content="Dashboard" Margin="10,10,10,0" VerticalAlignment="Top" Height="48" FontSize="28" VerticalContentAlignment="Center" FontFamily="Segoe UI Light" HorizontalAlignment="Center"/> | ||||||
| 
 | 
 | ||||||
|                     <Border x:Name="DashboardButtonTSCB" BorderBrush="White" HorizontalAlignment="Left" Margin="10,63,0,0" VerticalAlignment="Top" Width="250" Height="165"> |                     <WrapPanel Margin="10,0,10,10" HorizontalAlignment="Center" VerticalAlignment="Center"> | ||||||
|                         <Grid MouseLeftButtonUp="TabSelect_TSCB"> |                         <Border MouseLeftButtonUp="TabSelect" x:Name="DashboardButtonTSCB" BorderBrush="White" HorizontalAlignment="Left" VerticalAlignment="Top" Width="250" Height="165" Margin="5,5"> | ||||||
|  |                             <Grid> | ||||||
|                                 <Image Source="/Resources/Icons/mountain.png" Margin="10,10,190,0" Width="48" Height="48" VerticalAlignment="Top"/> |                                 <Image Source="/Resources/Icons/mountain.png" Margin="10,10,190,0" Width="48" Height="48" VerticalAlignment="Top"/> | ||||||
|                                 <Label Margin="63,10,10,0" VerticalContentAlignment="Center" FontSize="24" Height="48" VerticalAlignment="Top" Content="TSCB"/> |                                 <Label Margin="63,10,10,0" VerticalContentAlignment="Center" FontSize="24" Height="48" VerticalAlignment="Top" Content="TSCB"/> | ||||||
|                                 <TextBlock Text="Edits terrain scene binary files." Margin="10,63,10,10" TextWrapping="Wrap"></TextBlock> |                                 <TextBlock Text="Edits terrain scene binary files." Margin="10,63,10,10" TextWrapping="Wrap"></TextBlock> | ||||||
|                             </Grid> |                             </Grid> | ||||||
|                         </Border> |                         </Border> | ||||||
|                     <Border x:Name="DashboardButtonYaz0" BorderBrush="White" HorizontalAlignment="Left" Margin="265,63,0,0" VerticalAlignment="Top" Width="250" Height="165"> |                         <Border MouseLeftButtonUp="TabSelect" x:Name="DashboardButtonYaz0" BorderBrush="White" HorizontalAlignment="Left" VerticalAlignment="Top" Width="250" Height="165" Margin="5,5"> | ||||||
|                         <Grid MouseLeftButtonUp="TabSelect_Yaz0"> |                             <Grid> | ||||||
|                                 <Image Source="/Resources/Icons/letter-z.png" Margin="10,10,190,0" Width="48" Height="48" VerticalAlignment="Top"/> |                                 <Image Source="/Resources/Icons/letter-z.png" Margin="10,10,190,0" Width="48" Height="48" VerticalAlignment="Top"/> | ||||||
|                                 <Label Margin="63,10,10,0" VerticalContentAlignment="Center" FontSize="24" Height="48" VerticalAlignment="Top" Content="Yaz0"/> |                                 <Label Margin="63,10,10,0" VerticalContentAlignment="Center" FontSize="24" Height="48" VerticalAlignment="Top" Content="Yaz0"/> | ||||||
|                                 <TextBlock Text="Allows compression/decompression using Yaz0 encoding." Margin="10,63,10,10" TextWrapping="Wrap"></TextBlock> |                                 <TextBlock Text="Allows compression/decompression using Yaz0 encoding." Margin="10,63,10,10" TextWrapping="Wrap"></TextBlock> | ||||||
|                             </Grid> |                             </Grid> | ||||||
|                         </Border> |                         </Border> | ||||||
|                     <Border x:Name="DashboardButtonSARC" BorderBrush="White" HorizontalAlignment="Left" Margin="520,63,0,0" VerticalAlignment="Top" Width="250" Height="165"> |                         <Border MouseLeftButtonUp="TabSelect" x:Name="DashboardButtonSARC" BorderBrush="White" HorizontalAlignment="Left" VerticalAlignment="Top" Width="250" Height="165" Margin="5,5"> | ||||||
|                         <Grid MouseLeftButtonUp="TabSelect_SARC"> |                             <Grid> | ||||||
|                                 <Image Source="/Resources/Icons/package.png" Margin="10,10,190,0" Width="48" Height="48" VerticalAlignment="Top"/> |                                 <Image Source="/Resources/Icons/package.png" Margin="10,10,190,0" Width="48" Height="48" VerticalAlignment="Top"/> | ||||||
|                                 <Label Margin="63,10,10,0" VerticalContentAlignment="Center" FontSize="24" Height="48" VerticalAlignment="Top" Content="SARC"/> |                                 <Label Margin="63,10,10,0" VerticalContentAlignment="Center" FontSize="24" Height="48" VerticalAlignment="Top" Content="SARC"/> | ||||||
|                                 <TextBlock Text="Tools to unpack and pack SARC files." Margin="10,63,10,10" TextWrapping="Wrap"></TextBlock> |                                 <TextBlock Text="Tools to unpack and pack SARC files." Margin="10,63,10,10" TextWrapping="Wrap"></TextBlock> | ||||||
|                             </Grid> |                             </Grid> | ||||||
|                         </Border> |                         </Border> | ||||||
|                     <Border x:Name="DashboardButtonRSTB" BorderBrush="White" HorizontalAlignment="Left" Margin="775,63,0,0" VerticalAlignment="Top" Width="250" Height="165"> |                         <Border MouseLeftButtonUp="TabSelect" x:Name="DashboardButtonRSTB" BorderBrush="White" HorizontalAlignment="Left" VerticalAlignment="Top" Width="250" Height="165" Margin="5,5"> | ||||||
|                         <Grid MouseLeftButtonUp="TabSelect_RSTB"> |                             <Grid> | ||||||
|                                 <Image Source="/Resources/Icons/text-file.png" Margin="10,10,190,0" Width="48" Height="48" VerticalAlignment="Top"/> |                                 <Image Source="/Resources/Icons/text-file.png" Margin="10,10,190,0" Width="48" Height="48" VerticalAlignment="Top"/> | ||||||
|                                 <Label Margin="63,10,10,0" VerticalContentAlignment="Center" FontSize="24" Height="48" VerticalAlignment="Top" Content="RSTB"/> |                                 <Label Margin="63,10,10,0" VerticalContentAlignment="Center" FontSize="24" Height="48" VerticalAlignment="Top" Content="RSTB"/> | ||||||
|                                 <TextBlock Text="Allows edits to the resource table." Margin="10,63,10,10" TextWrapping="Wrap"></TextBlock> |                                 <TextBlock Text="Allows edits to the resource table." Margin="10,63,10,10" TextWrapping="Wrap"></TextBlock> | ||||||
|                             </Grid> |                             </Grid> | ||||||
|                         </Border> |                         </Border> | ||||||
|  |                     </WrapPanel> | ||||||
|                 </Grid> |                 </Grid> | ||||||
|             </TabItem> |             </TabItem> | ||||||
|             <TabItem x:Name="tabItemTSCB" Header="TSCB"> |             <TabItem x:Name="tabItemTSCB" Header="TSCB"> | ||||||
|  |  | ||||||
|  | @ -2,6 +2,7 @@ | ||||||
| using System; | using System; | ||||||
| using System.Reflection; | using System.Reflection; | ||||||
| using System.Windows; | using System.Windows; | ||||||
|  | using System.Windows.Controls; | ||||||
| 
 | 
 | ||||||
| namespace BOTWToolset | namespace BOTWToolset | ||||||
| { | { | ||||||
|  | @ -23,12 +24,17 @@ namespace BOTWToolset | ||||||
|             LabelVersion.Content = $"Version v{VERSION}"; |             LabelVersion.Content = $"Version v{VERSION}"; | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         private void TabSelect_TSCB(object sender, System.Windows.Input.MouseButtonEventArgs e) => tabItemTSCB.IsSelected = true; |         private void TabSelect(object sender, System.Windows.Input.MouseButtonEventArgs e) | ||||||
|  |         { | ||||||
|  |             var sender_border = (Border)sender; | ||||||
| 
 | 
 | ||||||
|         private void TabSelect_Yaz0(object sender, System.Windows.Input.MouseButtonEventArgs e) => tabItemYaz0.IsSelected = true; |             switch (sender_border.Name) | ||||||
| 
 |             { | ||||||
|         private void TabSelect_SARC(object sender, System.Windows.Input.MouseButtonEventArgs e) => tabItemSARC.IsSelected = true; |                 case "DashboardButtonTSCB": tabItemTSCB.IsSelected = true; break; | ||||||
| 
 |                 case "DashboardButtonYaz0": tabItemYaz0.IsSelected = true; break; | ||||||
|         private void TabSelect_RSTB(object sender, System.Windows.Input.MouseButtonEventArgs e) => tabItemRSTB.IsSelected = true; |                 case "DashboardButtonSARC": tabItemSARC.IsSelected = true; break; | ||||||
|  |                 case "DashboardButtonRSTB": tabItemRSTB.IsSelected = true; break; | ||||||
|  |             } | ||||||
|  |         } | ||||||
|     } |     } | ||||||
| } | } | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		
		Reference in a new issue
	
	 Chev
						Chev