Changes in object model: separate class objects to store vtable. Also, nicer UTF-8 display of big numbers.

This commit is contained in:
Hisham Muhammad
2012-12-05 15:12:20 +00:00
parent 2a73405cd0
commit 00b324bfc1
64 changed files with 662 additions and 566 deletions

View File

@ -52,8 +52,8 @@ ScreenManager* ScreenManager_new(int x1, int y1, int x2, int y2, Orientation ori
this->y2 = y2;
this->fuBar = NULL;
this->orientation = orientation;
this->panels = Vector_new(PANEL_CLASS, owner, DEFAULT_SIZE, NULL);
this->fuBars = Vector_new(FUNCTIONBAR_CLASS, true, DEFAULT_SIZE, NULL);
this->panels = Vector_new(Class(Panel), owner, DEFAULT_SIZE);
this->fuBars = Vector_new(Class(FunctionBar), true, DEFAULT_SIZE);
this->panelCount = 0;
this->header = header;
this->owner = owner;
@ -184,8 +184,8 @@ void ScreenManager_run(ScreenManager* this, Panel** lastFocus, int* lastKey) {
}
}
if (panelFocus->eventHandler) {
HandlerResult result = panelFocus->eventHandler(panelFocus, ch);
if (Panel_eventHandlerFn(panelFocus)) {
HandlerResult result = Panel_eventHandler(panelFocus, ch);
if (result == HANDLED) {
continue;
} else if (result == BREAK_LOOP) {