Skip to content

Commit

Permalink
Client: Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
skyjake committed Jul 8, 2013
1 parent eaaf07e commit 6017c87
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 19 deletions.
8 changes: 4 additions & 4 deletions doomsday/client/src/ui/widgets/guiwidget.cpp
Expand Up @@ -70,10 +70,10 @@ DENG2_PIMPL(GuiWidget)
marginId("gap"),
blurInited(false),
uBlurMvpMatrix("uMvpMatrix", GLUniform::Mat4),
uBlurColor("uColor", GLUniform::Vec4),
uBlurTex("uTex", GLUniform::Sampler2D),
uBlurStep("uBlurStep", GLUniform::Vec2),
uBlurWindow("uWindow", GLUniform::Vec4)
uBlurColor ("uColor", GLUniform::Vec4),
uBlurTex ("uTex", GLUniform::Sampler2D),
uBlurStep ("uBlurStep", GLUniform::Vec2),
uBlurWindow ("uWindow", GLUniform::Vec4)
{
#ifdef DENG2_DEBUG
self.audienceForParentChange += this;
Expand Down
20 changes: 5 additions & 15 deletions doomsday/client/src/ui/widgets/menuwidget.cpp
Expand Up @@ -147,9 +147,7 @@ DENG2_PIMPL(MenuWidget)
}
else
{
Rule const *old = total;
total = holdRef(OperatorRule::maximum(*total, item->rule().width()));
releaseRef(old);
changeRef(total, OperatorRule::maximum(*total, item->rule().width()));
}
}
if(!total) return new ConstantRule(0);
Expand All @@ -172,9 +170,7 @@ DENG2_PIMPL(MenuWidget)
}
else
{
Rule const *old = total;
total = holdRef(OperatorRule::maximum(*total, item->rule().height()));
releaseRef(old);
changeRef(total, OperatorRule::maximum(*total, item->rule().height()));
}
}
if(!total) return new ConstantRule(0);
Expand All @@ -194,9 +190,7 @@ DENG2_PIMPL(MenuWidget)
}
else
{
Rule const *old = total;
total = holdRef(*total + *fullColumnWidth(i));
releaseRef(old);
changeRef(total, *total + *fullColumnWidth(i));
}
}
if(!total) return new ConstantRule(0);
Expand All @@ -216,9 +210,7 @@ DENG2_PIMPL(MenuWidget)
}
else
{
Rule const *old = total;
total = holdRef(*total + *fullRowHeight(i));
releaseRef(old);
changeRef(total, *total + *fullRowHeight(i));
}
}
if(!total) return new ConstantRule(0);
Expand Down Expand Up @@ -332,9 +324,7 @@ void MenuWidget::updateLayout()
}
else
{
Rule const *old = rowBottom;
rowBottom = new OperatorRule(OperatorRule::Maximum, widget->rule().bottom(), *old);
releaseRef(old);
changeRef(rowBottom, OperatorRule::maximum(widget->rule().bottom(), *rowBottom));
}

previous = widget;
Expand Down

0 comments on commit 6017c87

Please sign in to comment.