Mercurial > dwindows
changeset 727:f190b5c2ce16
Fixed 2 errors in the tree select event handler. Also removed unused experimental code.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Mon, 14 Mar 2011 21:43:28 +0000 |
parents | ecf47778caff |
children | 55f22b39ab57 |
files | mac/dw.m |
diffstat | 1 files changed, 3 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/mac/dw.m Mon Mar 14 19:30:36 2011 +0000 +++ b/mac/dw.m Mon Mar 14 21:43:28 2011 +0000 @@ -279,8 +279,7 @@ item = (id)event; NSString *nstr = [item pointerAtIndex:1]; - user = [item pointerAtIndex:3]; - if(user) + if(nstr) { text = strdup([nstr UTF8String]); } @@ -288,6 +287,7 @@ { text = NULL; } + user = [item pointerAtIndex:2]; int result = treeselectfunc(handler->window, item, text, handler->data, user); if(text) { @@ -6755,12 +6755,7 @@ HMTX dw_mutex_new(void) { HMTX mutex = malloc(sizeof(pthread_mutex_t)); -#if 0 - pthread_mutexattr_t attr; - - pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE); - pthread_mutex_init(mutex, &attr); -#endif + pthread_mutex_init(mutex, NULL); return mutex; }