mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-13 16:37:30 +00:00
40ae7a7f19
The conditional selector performance seems to work nicely, but I've found a mistake with View.window (partly, realizing why my old lib (and probably TV in the first place) had separate textContext and buffers between views and groups).
40 lines
1.1 KiB
Objective-C
40 lines
1.1 KiB
Objective-C
#ifndef __qwaq_group_h
|
|
#define __qwaq_group_h
|
|
|
|
#include <Array.h>
|
|
#include "qwaq-view.h"
|
|
|
|
typedef BOOL condition_func (id object, void *data);
|
|
typedef BOOL condition_func2 (id object, void *anObject, void *data);
|
|
|
|
@interface Array (Group)
|
|
- (void) makeObjectsPerformSelector: (SEL)selector
|
|
if: (condition_func)condition
|
|
with: (void *)data;
|
|
- (void) makeObjectsPerformSelector: (SEL)selector
|
|
withObject: (void *)anObject
|
|
if: (condition_func2)condition
|
|
with: (void *)data;
|
|
- (void) makeReversedObjectsPerformSelector: (SEL)selector;
|
|
- (void) makeReversedObjectsPerformSelector: (SEL)selector
|
|
withObject: (void *)anObject;
|
|
- (void) makeReversedObjectsPerformSelector: (SEL)selector
|
|
if: (condition_func)condition
|
|
with: (void *)data;
|
|
- (void) makeReversedObjectsPerformSelector: (SEL)selector
|
|
withObject: (void *)anObject
|
|
if: (condition_func2)condition
|
|
with: (void *)data;
|
|
@end
|
|
|
|
@interface Group : View
|
|
{
|
|
Array *views;
|
|
int focused;
|
|
struct window_s *window;
|
|
}
|
|
-insert: (View *) view;
|
|
-remove: (View *) view;
|
|
@end
|
|
|
|
#endif//__qwaq_group_h
|