GIFTranslator: style fixes
This commit is contained in:
@@ -351,12 +351,15 @@ GIFSave::ResetHashtable()
|
|||||||
int
|
int
|
||||||
GIFSave::CheckHashtable(int s, unsigned char c)
|
GIFSave::CheckHashtable(int s, unsigned char c)
|
||||||
{
|
{
|
||||||
if (s == -1) return c;
|
if (s == -1)
|
||||||
|
return c;
|
||||||
|
|
||||||
int hashindex = HASH(s, c);
|
int hashindex = HASH(s, c);
|
||||||
int nextindex;
|
int nextindex;
|
||||||
while ((nextindex = code_value[hashindex]) != -1) {
|
while ((nextindex = code_value[hashindex]) != -1) {
|
||||||
if (prefix_code[nextindex] == s && append_char[nextindex] == c)
|
if (prefix_code[nextindex] == s && append_char[nextindex] == c)
|
||||||
return nextindex;
|
return nextindex;
|
||||||
|
|
||||||
hashindex = (hashindex + HASHSTEP) % HASHSIZE;
|
hashindex = (hashindex + HASHSTEP) % HASHSIZE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -428,7 +428,9 @@ GIFView::MessageReceived(BMessage* message)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
int GIFView::CheckInput(BTextControl* control) {
|
int
|
||||||
|
GIFView::CheckInput(BTextControl* control)
|
||||||
|
{
|
||||||
int value = atoi(control->Text());
|
int value = atoi(control->Text());
|
||||||
if (value < 0 || value > 255) {
|
if (value < 0 || value > 255) {
|
||||||
value = (value < 0) ? 0 : 255;
|
value = (value < 0) ? 0 : 255;
|
||||||
|
|||||||
Reference in New Issue
Block a user