Permalink
Browse files

Made the empty part of the scroll area in hex editor not apppear. Min…

…or indentation of round brackets.
  • Loading branch information...
1 parent e06ca2d commit e80e1ce28ae7bbd9ba992deeea38f08e2a21f4ad @cokyazici cokyazici committed Oct 2, 2011
Showing with 6 additions and 6 deletions.
  1. +6 −6 najitool_GUI_0.3.0.0.src/naji_gui.src/naji_hex.ec
@@ -79,20 +79,20 @@ class HexEditor : Window
if (i >= buffer_size)
break;
- surface.WriteTextf((x-24) + scroll.x, ( (y) + (yy) * (12) -24 ) - scroll.y, "%08X ", (offset * 16));
+ surface.WriteTextf( (x-24) + scroll.x, ( (y) + (yy) * (12) -24 ) - scroll.y, "%08X ", (offset * 16));
- surface.WriteTextf(( (x) + (xx) * (24) + 60 ) + scroll.x, ( (y) + (yy) * (12) -24 ) - scroll.y, "%02X ", read_buffer[i]);
+ surface.WriteTextf( ( (x) + (xx) * (24) + 60 ) + scroll.x, ( (y) + (yy) * (12) -24 ) - scroll.y, "%02X ", read_buffer[i]);
if ( ( (read_buffer[i] >= ' ') && (read_buffer[i] <= '~') ) )
{
- surface.WriteTextf(( ( (x) + (xx) * (12)) + 455) + scroll.x, ( (y) + (yy) * (12) -24 ) - scroll.y, "%c", read_buffer[i]);
+ surface.WriteTextf( ( ( (x) + (xx) * (12)) + 455) + scroll.x, ( (y) + (yy) * (12) -24 ) - scroll.y, "%c", read_buffer[i]);
}
else
{
- surface.WriteTextf( (((x) + (xx) * (12)) + 455) + scroll.x, ( (y) + (yy) * (12) -24 ) - scroll.y, ".");
+ surface.WriteTextf( ( ((x) + (xx) * (12)) + 455) + scroll.x, ( (y) + (yy) * (12) -24 ) - scroll.y, ".");
}
@@ -154,8 +154,8 @@ class HexEditor : Window
patch_load_file.Close();
-
- scrollArea.h += buffer_size;
+ if ( (scrollArea.h != 0) && (buffer_size != 0) )
+ scrollArea.h = buffer_size/1.333;
}
return true;
}

0 comments on commit e80e1ce

Please sign in to comment.