mirror of
https://github.com/danbulant/Cosmos
synced 2026-05-23 06:18:54 +00:00
Register bytes were swapped. Also made some UI fixes.
This commit is contained in:
parent
be8e244c81
commit
a11cb146ce
2 changed files with 27 additions and 26 deletions
|
|
@ -7,7 +7,7 @@
|
|||
d:DesignHeight="310" d:DesignWidth="300">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="32" />
|
||||
<ColumnDefinition Width="37" />
|
||||
<ColumnDefinition Width="75" />
|
||||
<ColumnDefinition Width="27" />
|
||||
<ColumnDefinition Width="40" />
|
||||
|
|
@ -18,15 +18,16 @@
|
|||
</Grid.ColumnDefinitions>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="25" />
|
||||
<RowDefinition Height="25" />
|
||||
<RowDefinition Height="25" />
|
||||
<RowDefinition Height="25" />
|
||||
<RowDefinition Height="40" />
|
||||
<RowDefinition Height="27" />
|
||||
<RowDefinition Height="40" />
|
||||
<RowDefinition Height="25" />
|
||||
<RowDefinition Height="25" />
|
||||
<RowDefinition Height="25" />
|
||||
<RowDefinition Height="27" />
|
||||
<RowDefinition Height="27" />
|
||||
<RowDefinition Height="27" />
|
||||
<RowDefinition Height="27" />
|
||||
<RowDefinition Height="27" />
|
||||
<RowDefinition Height="27" />
|
||||
<RowDefinition Height="27" />
|
||||
<RowDefinition Height="27" />
|
||||
<RowDefinition Height="27" />
|
||||
<RowDefinition Height="*" />
|
||||
</Grid.RowDefinitions>
|
||||
<Label Grid.Column="0" Grid.Row="0" Grid.ColumnSpan="2" Content="Registers" HorizontalAlignment="Left" FontWeight="Bold" />
|
||||
|
|
@ -61,16 +62,16 @@
|
|||
<Label Grid.Column="4" Grid.Row="4" Content="DH" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="5" Grid.Row="4" Content="12" Name="lablDH" />
|
||||
<Label Grid.Column="6" Grid.Row="4" Content="DL" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="7" Grid.Row="1" Content="12" Name="lablDL" />
|
||||
<Label Grid.Column="0" Grid.Row="5" Content="EIP" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="3" Grid.Row="5" Grid.ColumnSpan="2" Content="Flags" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="0" Grid.Row="7" Content="ESP" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="1" Grid.Row="7" Content="12345678" Name="lablESP" />
|
||||
<Label Grid.Column="0" Grid.Row="8" Content="EBP" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="1" Grid.Row="8" Content="12345678" Name="lablEBP" />
|
||||
<Label Grid.Column="0" Grid.Row="9" Content="ESI" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="1" Grid.Row="9" Content="12345678" Name="lablESI" />
|
||||
<Label Grid.Column="0" Grid.Row="10" Content="EDI" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="1" Grid.Row="10" Content="12345678" Name="lablEDI" />
|
||||
<Label Grid.Column="7" Grid.Row="4" Content="12" Name="lablDL" />
|
||||
<Label Grid.Column="0" Grid.Row="9" Content="EIP" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="0" Grid.Row="10" Content="Flags" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="0" Grid.Row="8" Content="ESP" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="1" Grid.Row="8" Content="12345678" Name="lablESP" />
|
||||
<Label Grid.Column="0" Grid.Row="5" Content="EBP" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="1" Grid.Row="5" Content="12345678" Name="lablEBP" />
|
||||
<Label Grid.Column="0" Grid.Row="6" Content="ESI" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="1" Grid.Row="6" Content="12345678" Name="lablESI" />
|
||||
<Label Grid.Column="0" Grid.Row="7" Content="EDI" HorizontalAlignment="Right" />
|
||||
<Label Grid.Column="1" Grid.Row="7" Content="12345678" Name="lablEDI" />
|
||||
</Grid>
|
||||
</UserControl>
|
||||
|
|
|
|||
|
|
@ -19,8 +19,8 @@ namespace Cosmos.VS.Debug {
|
|||
}
|
||||
|
||||
protected void UpdateRegisters(byte[] aData, int aOffset, Label a32, Label a16, Label a8Hi, Label a8Lo) {
|
||||
byte x8Lo = aData[aOffset + 3];
|
||||
byte x8Hi = aData[aOffset + 2];
|
||||
byte x8Lo = aData[aOffset];
|
||||
byte x8Hi = aData[aOffset + 1];
|
||||
a8Lo.Content = x8Lo.ToString("X2");
|
||||
a8Hi.Content = x8Hi.ToString("X2");
|
||||
a16.Content = x8Hi.ToString("X2") + x8Lo.ToString("X2");
|
||||
|
|
@ -29,10 +29,10 @@ namespace Cosmos.VS.Debug {
|
|||
|
||||
protected void UpdateRegister32(byte[] aData, int aOffset, Label a32) {
|
||||
UInt32 x32 = (UInt32)
|
||||
(aData[aOffset + 0] << 24 |
|
||||
aData[aOffset + 1] << 16 |
|
||||
aData[aOffset + 2] << 8 |
|
||||
aData[aOffset + 3]);
|
||||
(aData[aOffset + 3] << 24 |
|
||||
aData[aOffset + 2] << 16 |
|
||||
aData[aOffset + 1] << 8 |
|
||||
aData[aOffset]);
|
||||
a32.Content = x32.ToString("X8");
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue