fix ConvertSizeToKb() function for case when size is less than 1Kb
git-svn-id: svn://kolibrios.org@6568 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
edc6f75e77
commit
6091b058a0
@ -17,7 +17,7 @@
|
||||
// //
|
||||
//===================================================//
|
||||
|
||||
?define WINDOW_HEADER "Clipboard viewer v1.0"
|
||||
?define WINDOW_HEADER "Clipboard viewer v1.01"
|
||||
?define T_DELETE_LAST_SLOT "Delete last slot"
|
||||
?define T_DELETE_ALL_SLOTS "Delete all slots"
|
||||
?define T_RESET_BUFFER_LOCK "Reset the lock buffer"
|
||||
|
@ -307,9 +307,17 @@ enum
|
||||
unsigned int kb;
|
||||
dword kb_line;
|
||||
|
||||
kb_line = itoa(bytes / 1024);
|
||||
strcpy(#size, kb_line);
|
||||
strcat(#size, " Kb");
|
||||
if (bytes >= 1024)
|
||||
{
|
||||
kb_line = itoa(bytes / 1024);
|
||||
strcpy(#size, kb_line);
|
||||
strcat(#size, " Kb");
|
||||
}
|
||||
else {
|
||||
kb_line = itoa(bytes);
|
||||
strcpy(#size, kb_line);
|
||||
strcat(#size, " b");
|
||||
}
|
||||
|
||||
return #size;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user