1
0
mirror of https://github.com/gryf/wmaker.git synced 2026-01-27 02:05:47 +01:00

- added WMRemoveFromArrayMatching(array, match, cdata), which will remove the

first element in the array that is matched by match(item, cdata)==True.
- added WMArrayFirst(), WMArrayLast(), WMArrayNext() and WMArrayPrevious()
  functions and also WM_ITERATE_ARRAY() and WM_ETARETI_ARRAY() macros, to make
  interfaces to WMBag and WMArray similar and to make life a little simpler
  when iterating through all elements of an array.
- replaced bags with arrays wherever appropriate. This will improve
  performance a bit.
- replaced some recursive code with iterative code in WINGs/selection.c
- some code cleanup is src/
This commit is contained in:
dan
2001-04-15 01:22:56 +00:00
parent a41b8993e5
commit 046403dbbb
27 changed files with 581 additions and 662 deletions

View File

@@ -132,7 +132,7 @@ createView(W_Screen *screen, W_View *parent)
view->refCount = 1;
view->eventHandlers = WMCreateBag(4);
view->eventHandlers = WMCreateArrayWithDestructor(4, wfree);
return view;
}
@@ -441,9 +441,8 @@ destroyView(W_View *view)
/* remove self from parent's children list */
unparentView(view);
W_CleanUpEvents(view);
WMFreeBag(view->eventHandlers);
/* the array has a wfree() destructor that will be called automatically */
WMFreeArray(view->eventHandlers);
view->eventHandlers = NULL;
WMUnregisterViewDraggedTypes(view);