From 35735b2f3688ff12bda9a4515ca50e295b1a6afd Mon Sep 17 00:00:00 2001 From: dan Date: Tue, 18 May 1999 00:01:59 +0000 Subject: [PATCH] Fixed a crashing bug related to textfield selections, and reordered the items in the textfield delegate structure to be grouped togheter based on their meaning. --- WINGs/WINGs.h | 6 +++--- WINGs/wtextfield.c | 3 ++- WPrefs.app/Paths.c | 2 +- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/WINGs/WINGs.h b/WINGs/WINGs.h index 2b47c92d..2db93155 100644 --- a/WINGs/WINGs.h +++ b/WINGs/WINGs.h @@ -435,12 +435,12 @@ typedef struct WMBrowserDelegate { typedef struct WMTextFieldDelegate { void *data; - void (*didBeginEditing)(struct WMTextFieldDelegate *self, - WMNotification *notif); - void (*didChange)(struct WMTextFieldDelegate *self, WMNotification *notif); + void (*didBeginEditing)(struct WMTextFieldDelegate *self, + WMNotification *notif); + void (*didEndEditing)(struct WMTextFieldDelegate *self, WMNotification *notif); diff --git a/WINGs/wtextfield.c b/WINGs/wtextfield.c index 027dedfe..419ee250 100644 --- a/WINGs/wtextfield.c +++ b/WINGs/wtextfield.c @@ -230,7 +230,8 @@ requestHandler(WMWidget *w, Atom selection, Atom target, Atom *type, static void lostHandler(WMWidget *w, Atom selection) { - TextField *tPtr; + TextField *tPtr = (WMTextField*)w; + tPtr->selection.count = 0; paintTextField(tPtr); } diff --git a/WPrefs.app/Paths.c b/WPrefs.app/Paths.c index e376e3fc..122053b8 100644 --- a/WPrefs.app/Paths.c +++ b/WPrefs.app/Paths.c @@ -146,7 +146,7 @@ browseForFile(WMWidget *w, void *data) WMSetFilePanelCanChooseFiles(filePanel, False); if (WMRunModalFilePanelForDirectory(filePanel, panel->win, "/", - _("Select path"), NULL) == True) { + _("Select directory"), NULL) == True) { char *str = WMGetFilePanelFileName(filePanel); if (str) {