summaryrefslogtreecommitdiff
path: root/riscos/wimp_event.c
diff options
context:
space:
mode:
authorJohn Tytgat <joty@netsurf-browser.org>2008-08-05 01:23:04 +0000
committerJohn Tytgat <joty@netsurf-browser.org>2008-08-05 01:23:04 +0000
commitc40fc354b3783502ce0c9be1629380acb10c0570 (patch)
tree27076646b9e6041439a5e082b1cb99d67045b0ac /riscos/wimp_event.c
parent039362166c2d31dd23931332b6af94bf274d2635 (diff)
downloadnetsurf-c40fc354b3783502ce0c9be1629380acb10c0570.tar.gz
netsurf-c40fc354b3783502ce0c9be1629380acb10c0570.tar.bz2
- Teached ro_gui_set_icon_string() and ro_gui_get_icon_string() about the difference between direct and indirect icons.
- ro_gui_get_icon_string(): - Constify return value of ro_gui_get_icon_string() as you really shouldn't change its contents via this pointer. - Enfore NUL string termination as return value (instead of other control char termination) - Merged ro_gui_set_icon_string_le() into ro_gui_set_icon_string() by adding ro_gui_set_icon_string() and extra to_utf8 parameter. - ro_gui_strncmp(): added svn path=/trunk/netsurf/; revision=4907
Diffstat (limited to 'riscos/wimp_event.c')
-rw-r--r--riscos/wimp_event.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/riscos/wimp_event.c b/riscos/wimp_event.c
index 8cfe49747..097efafbe 100644
--- a/riscos/wimp_event.c
+++ b/riscos/wimp_event.c
@@ -180,7 +180,7 @@ bool ro_gui_wimp_event_restore(wimp_w w)
case EVENT_TEXT_FIELD:
if (event->previous_value.textual)
ro_gui_set_icon_string(window->w, event->i,
- event->previous_value.textual);
+ event->previous_value.textual, true);
break;
case EVENT_CHECKBOX:
case EVENT_RADIO:
@@ -381,8 +381,8 @@ bool ro_gui_wimp_event_menu_selection(wimp_w w, wimp_i i, wimp_menu *menu,
if (menu_entry->menu_flags & wimp_MENU_TICKED)
return true;
- ro_gui_set_icon_string_le(window->w, event->data.menu_gright.field,
- menu_entry->data.indirected_text.text);
+ ro_gui_set_icon_string(window->w, event->data.menu_gright.field,
+ menu_entry->data.indirected_text.text, false);
ro_gui_wimp_event_prepare_menu(window->w, event);
if (window->menu_selection)
window->menu_selection(window->w, event->i);
@@ -591,7 +591,7 @@ bool ro_gui_wimp_event_mouse_click(wimp_pointer *pointer)
void ro_gui_wimp_event_prepare_menu(wimp_w w, struct icon_event *event)
{
int i;
- char *text;
+ const char *text;
unsigned int button_type;
wimp_icon_state ic;
wimp_menu *menu;