2.5
- Brought back (most of) buttons in TimeLine window. They don't work yet though! Waiting for Brecht to commit callbacks for menus and ui-blocks - Area headers hilite again when mouse is inside.
This commit is contained in:
@@ -98,8 +98,7 @@ void ED_region_pixelspace(const bContext *C, ARegion *ar)
|
||||
int height= ar->winrct.ymax-ar->winrct.ymin+1;
|
||||
|
||||
wmOrtho2(C->window, -0.375, (float)width-0.375, -0.375, (float)height-0.375);
|
||||
wmLoadIdentity(C->window);
|
||||
|
||||
wmLoadIdentity(C->window);
|
||||
}
|
||||
|
||||
void ED_region_do_listen(ARegion *ar, wmNotifier *note)
|
||||
|
||||
@@ -958,6 +958,7 @@ void ED_screen_set_subwinactive(wmWindow *win)
|
||||
if(win->screen) {
|
||||
wmEvent *event= win->eventstate;
|
||||
ScrArea *sa;
|
||||
int oldswin= win->screen->subwinactive;
|
||||
|
||||
for(sa= win->screen->areabase.first; sa; sa= sa->next) {
|
||||
if(event->x > sa->totrct.xmin && event->x < sa->totrct.xmax)
|
||||
@@ -974,7 +975,34 @@ void ED_screen_set_subwinactive(wmWindow *win)
|
||||
else
|
||||
win->screen->subwinactive= win->screen->mainwin;
|
||||
|
||||
/* check for redraw headers */
|
||||
if(oldswin!=win->screen->subwinactive) {
|
||||
|
||||
for(sa= win->screen->areabase.first; sa; sa= sa->next) {
|
||||
ARegion *ar;
|
||||
int do_draw= 0;
|
||||
|
||||
for(ar= sa->regionbase.first; ar; ar= ar->next)
|
||||
if(ar->swinid==oldswin || ar->swinid==win->screen->subwinactive)
|
||||
do_draw= 1;
|
||||
|
||||
if(do_draw)
|
||||
for(ar= sa->regionbase.first; ar; ar= ar->next)
|
||||
if(ar->regiontype==RGN_TYPE_HEADER)
|
||||
ar->do_draw= 1; /* XXX */
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
int ED_screen_area_active(const bContext *C)
|
||||
{
|
||||
|
||||
if(C->screen && C->area) {
|
||||
ARegion *ar;
|
||||
for(ar= C->area->regionbase.first; ar; ar= ar->next)
|
||||
if(ar->swinid == C->screen->subwinactive)
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user