comparison src/dialogs.c @ 2642:b6cf22276d4b

[gaim-migrate @ 2655] "Don't Panic!" committer: Tailor Script <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Wed, 31 Oct 2001 18:52:40 +0000
parents 66164831c228
children b0c5770156e1
comparison
equal deleted inserted replaced
2641:671c3a6a2c12 2642:b6cf22276d4b
3432 i++; 3432 i++;
3433 if (strlen(buf) >= 5 && (!strncmp(buf + strlen(buf) - 5, "<BR>\n", 5))) 3433 if (strlen(buf) >= 5 && (!strncmp(buf + strlen(buf) - 5, "<BR>\n", 5)))
3434 /* take off the \n */ 3434 /* take off the \n */
3435 buf[strlen(buf) - 1] = '\0'; 3435 buf[strlen(buf) - 1] = '\0';
3436 3436
3437 /* don't lose the thirtieth line of conversation. thanks FeRD */
3438 g_string_append(string, buf);
3439
3437 if (i == 30) { 3440 if (i == 30) {
3438 gtk_imhtml_append_text(GTK_IMHTML(view->layout), string->str, view->options); 3441 gtk_imhtml_append_text(GTK_IMHTML(view->layout), string->str, view->options);
3439 g_string_free(string, TRUE); 3442 g_string_free(string, TRUE);
3440 string = g_string_new(""); 3443 string = g_string_new("");
3441 /* you can't have these anymore. if someone clicks on another item while one is 3444 /* you can't have these anymore. if someone clicks on another item while one is
3442 * drawing, it will try to move to that item, and that causes problems here. 3445 * drawing, it will try to move to that item, and that causes problems here.
3443 while (gtk_events_pending()) 3446 while (gtk_events_pending())
3444 gtk_main_iteration(); 3447 gtk_main_iteration();
3445 */ 3448 */
3446 i = 0; 3449 i = 0;
3447 } else {
3448 g_string_append(string, buf);
3449 } 3450 }
3450 3451
3451 } 3452 }
3452 gtk_imhtml_append_text(GTK_IMHTML(view->layout), string->str, view->options); 3453 gtk_imhtml_append_text(GTK_IMHTML(view->layout), string->str, view->options);
3453 gtk_imhtml_append_text(GTK_IMHTML(view->layout), "<BR>", view->options); 3454 gtk_imhtml_append_text(GTK_IMHTML(view->layout), "<BR>", view->options);