d22aae888b247f7aeedbe0592e431af74c192515 braney Thu Jan 30 17:34:20 2020 -0800 fix problem with group autoscale and collections with add or subtract as merge type. Also fix long existing problem of using right click to change merge type from add/subtract to something else. diff --git src/hg/hgTracks/wigTrack.c src/hg/hgTracks/wigTrack.c index 803e98d..27ffea1 100644 --- src/hg/hgTracks/wigTrack.c +++ src/hg/hgTracks/wigTrack.c @@ -1301,30 +1301,33 @@ preDrawAutoScale(preDraw, preDrawZero, width, wigCart->autoScale, wigCart->windowingFunction, &preContainer->graphUpperLimit, &preContainer->graphLowerLimit, &epsilon, tg->lineHeight, wigCart->maxY, wigCart->minY, wigCart->alwaysZero); } graphUpperLimit = preContainer->graphUpperLimit; graphLowerLimit = preContainer->graphLowerLimit; if (retGraphUpperLimit != NULL) *retGraphUpperLimit = graphUpperLimit; if (retGraphLowerLimit != NULL) *retGraphLowerLimit = graphLowerLimit; +if (sameString(tg->tdb->type, "mathWig") && (wigCart->autoScale == wiggleScaleCumulative)) + wigCart->autoScale = wiggleScaleAuto; + if (wigCart->autoScale == wiggleScaleCumulative) setMinMax(tg, graphLowerLimit, graphUpperLimit); } void wigDrawPredraw(struct track *tg, int seqStart, int seqEnd, struct hvGfx *hvg, int xOff, int yOff, int width, MgFont *font, Color color, enum trackVisibility vis, struct preDrawContainer *preContainer, int preDrawZero, int preDrawSize, double graphUpperLimit, double graphLowerLimit) /* Draw once we've figured out predraw (numerical values to graph) we draw it here. * This code is shared by wig, bigWig, and bedGraph drawers. */ { struct wigCartOptions *wigCart = (struct wigCartOptions *) tg->wigCartData; double graphRange; /* scaling choice will set this */