Mercurial > pidgin.yaz
comparison console/libgnt/gntentry.c @ 14901:d9d28bd79715
[gaim-migrate @ 17673]
erasechar() returns the erase character (VERASE) from termios. This may solve
the backspace problem for Sebastian Noack.
committer: Tailor Script <tailor@pidgin.im>
author | Sadrul Habib Chowdhury <imadil@gmail.com> |
---|---|
date | Sun, 05 Nov 2006 17:37:09 +0000 |
parents | 065e7ac30338 |
children | f16e056f816d |
comparison
equal
deleted
inserted
replaced
14900:065e7ac30338 | 14901:d9d28bd79715 |
---|---|
534 | 534 |
535 static void | 535 static void |
536 gnt_entry_class_init(GntEntryClass *klass) | 536 gnt_entry_class_init(GntEntryClass *klass) |
537 { | 537 { |
538 GntBindableClass *bindable = GNT_BINDABLE_CLASS(klass); | 538 GntBindableClass *bindable = GNT_BINDABLE_CLASS(klass); |
539 char s[2] = {erasechar(), 0}; | |
540 | |
539 parent_class = GNT_WIDGET_CLASS(klass); | 541 parent_class = GNT_WIDGET_CLASS(klass); |
540 parent_class->destroy = gnt_entry_destroy; | 542 parent_class->destroy = gnt_entry_destroy; |
541 parent_class->draw = gnt_entry_draw; | 543 parent_class->draw = gnt_entry_draw; |
542 parent_class->map = gnt_entry_map; | 544 parent_class->map = gnt_entry_map; |
543 parent_class->size_request = gnt_entry_size_request; | 545 parent_class->size_request = gnt_entry_size_request; |
550 gnt_bindable_class_register_action(bindable, "cursor-end", move_end, | 552 gnt_bindable_class_register_action(bindable, "cursor-end", move_end, |
551 GNT_KEY_CTRL_E, NULL); | 553 GNT_KEY_CTRL_E, NULL); |
552 gnt_bindable_register_binding(bindable, "cursor-end", GNT_KEY_END, NULL); | 554 gnt_bindable_register_binding(bindable, "cursor-end", GNT_KEY_END, NULL); |
553 gnt_bindable_class_register_action(bindable, "delete-prev", backspace, | 555 gnt_bindable_class_register_action(bindable, "delete-prev", backspace, |
554 GNT_KEY_BACKSPACE, NULL); | 556 GNT_KEY_BACKSPACE, NULL); |
557 gnt_bindable_register_binding(bindable, "delete-prev", s, NULL); | |
555 gnt_bindable_class_register_action(bindable, "delete-next", delkey, | 558 gnt_bindable_class_register_action(bindable, "delete-next", delkey, |
556 GNT_KEY_DEL, NULL); | 559 GNT_KEY_DEL, NULL); |
557 gnt_bindable_register_binding(bindable, "delete-next", GNT_KEY_CTRL_D, NULL); | 560 gnt_bindable_register_binding(bindable, "delete-next", GNT_KEY_CTRL_D, NULL); |
558 gnt_bindable_class_register_action(bindable, "delete-start", del_to_home, | 561 gnt_bindable_class_register_action(bindable, "delete-start", del_to_home, |
559 GNT_KEY_CTRL_U, NULL); | 562 GNT_KEY_CTRL_U, NULL); |