set the view3d used layer to be an unsigned int, mask out localview layers to avoid flag mismatch when checking if it changed.
This commit is contained in:
@@ -533,16 +533,16 @@ static void view3d_recalc_used_layers(ARegion *ar, wmNotifier *wmn, Scene *scene
|
||||
{
|
||||
wmWindow *win= wmn->wm->winactive;
|
||||
ScrArea *sa;
|
||||
int lay_used= 0;
|
||||
unsigned int lay_used= 0;
|
||||
Base *base;
|
||||
|
||||
if (!win) return;
|
||||
|
||||
base= scene->base.first;
|
||||
while(base) {
|
||||
lay_used|= base->lay;
|
||||
lay_used |= base->lay & ((1<<20)-1); /* ignore localview */
|
||||
|
||||
if ((lay_used & ((1<<20)-1)) == (1<<20)-1)
|
||||
if (lay_used == (1<<20)-1)
|
||||
break;
|
||||
|
||||
base= base->next;
|
||||
|
||||
@@ -2214,7 +2214,8 @@ void view3d_main_area_draw(const bContext *C, ARegion *ar)
|
||||
Base *base;
|
||||
Object *ob;
|
||||
float backcol[3];
|
||||
int retopo= 0, sculptparticle= 0, lay_used= 0;
|
||||
int retopo= 0, sculptparticle= 0;
|
||||
unsigned int lay_used;
|
||||
Object *obact = OBACT;
|
||||
char *grid_unit= NULL;
|
||||
|
||||
@@ -2321,7 +2322,7 @@ void view3d_main_area_draw(const bContext *C, ARegion *ar)
|
||||
|
||||
/* then draw not selected and the duplis, but skip editmode object */
|
||||
for(base= scene->base.first; base; base= base->next) {
|
||||
lay_used |= base->lay;
|
||||
lay_used |= base->lay & ((1<<20)-1);
|
||||
|
||||
if(v3d->lay & base->lay) {
|
||||
|
||||
|
||||
@@ -139,7 +139,7 @@ typedef struct View3D {
|
||||
|
||||
float viewquat[4], dist, pad1; /* XXX depricated */
|
||||
|
||||
int lay_used; /* used while drawing */
|
||||
unsigned int lay_used; /* used while drawing */
|
||||
|
||||
short persp; /* XXX depricated */
|
||||
short view; /* XXX depricated */
|
||||
|
||||
Reference in New Issue
Block a user