29#define _Class _TableRowView
55 if (strcmp(
"selected", simpleSelector->
pattern) == 0) {
63#pragma mark - TableRowView
73 $(self->
cells, addObject, cell);
87 const Array *columns = (Array *)
tableView->columns;
89 self->
cells = $$(Array, arrayWithCapacity, columns->count);
123 $(self->
cells, removeObject, cell);
140#pragma mark - Class lifecycle
147 ((ObjectInterface *) clazz->interface)->dealloc =
dealloc;
149 ((ViewInterface *) clazz->interface)->matchesSelector =
matchesSelector;
151 ((TableRowViewInterface *) clazz->interface)->addCell =
addCell;
152 ((TableRowViewInterface *) clazz->interface)->initWithTableView =
initWithTableView;
153 ((TableRowViewInterface *) clazz->interface)->removeAllCells =
removeAllCells;
154 ((TableRowViewInterface *) clazz->interface)->removeCell =
removeCell;
155 ((TableRowViewInterface *) clazz->interface)->setSelected =
setSelected;
167 clazz = _initialize(&(
const ClassDef) {
168 .name =
"TableRowView",
171 .interfaceSize =
sizeof(TableRowViewInterface),
static void initialize(Class *clazz)
static void dealloc(Object *self)
static void setSelected(CollectionItemView *self, bool isSelected)
static bool matchesSelector(const View *self, const SimpleSelector *simpleSelector)
static bool isSelected(const Control *self)
@ SimpleSelectorTypePseudo
Class * _TableRowView(void)
static void removeCell(TableRowView *self, TableCellView *cell)
static void addCell(TableRowView *self, TableCellView *cell)
static void setSelected(TableRowView *self, bool isSelected)
static bool matchesSelector(const View *self, const SimpleSelector *simpleSelector)
static TableRowView * initWithTableView(TableRowView *self, TableView *tableView)
static void dealloc(Object *self)
static void removeAllCells_enumerate(const Array *array, ident obj, ident data)
ArrayEnumerator to remove TableCellViews from the row.
static void initialize(Class *clazz)
static void removeAllCells(TableRowView *self)
TableViews provide sortable, tabular presentations of data.
static void removeFromSuperview(View *self)
SimpleSelectorType type
The SimpleSelectorType.
char * pattern
The pattern, as provided by the user.
StackViews are containers that manage the arrangement of their subviews.
StackView * initWithFrame(StackView *self, const SDL_Rect *frame)
Initializes this StackView with the specified frame.
Each row in a TableView is comprised of TableCellViews.
bool isSelected
True when this row is selected, false otherwise.
TableView * tableView
The table.
TableViews provide sortable, tabular presentations of data.
Views are the fundamental building blocks of ObjectivelyMVC user interfaces.
void invalidateStyle(View *self)
Invalidates the computed Style for this View and its descendants.
void addSubview(View *self, View *subview)
Adds a subview to this view, to be drawn above its siblings.
void removeSubview(View *self, View *subview)
Removes the given subview from this View.