Review Request: Some dead code I do not know how to handle
Cyrille Berger Skott
cyb at lepi.org
Thu Jun 30 09:02:46 BST 2011
> On June 30, 2011, 6:38 a.m., Thorsten Zachmann wrote:
> > krita/plugins/filters/blur/kis_blur_filter.cpp, line 81
> > <http://git.reviewboard.kde.org/r/101803/diff/1/?file=25714#file25714line81>
> >
> > Does that give the same result?
> > If not is this chnage correct. Krita guys any idea?
>
> Elvis Stansvik wrote:
> It should. Subtraction is evaluated before a ternary conditional, so the adding of parenthesis is just a clarification. But I wonder, couldn't this one be rewritten as a qMax somehow to make it even more clearer?
>
> Elvis Stansvik wrote:
> But then again, maybe not worth poking at something that works, as there seems to be many such constructs around there.
that one should be:
int strength = 100 - (config->getProperty("strength", value) ? value.toUInt() : 0);
As getProperty returns a bool. I guess the behaviour was buggy before that.
- Cyrille
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/101803/#review4269
-----------------------------------------------------------
On June 29, 2011, 8:32 p.m., Jaime Torres Amate wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/101803/
> -----------------------------------------------------------
>
> (Updated June 29, 2011, 8:32 p.m.)
>
>
> Review request for Calligra.
>
>
> Summary
> -------
>
> the changes are:
> (easy)
> 1. in formulas is to return the FormulaToken& as recommended by C++. (even if there is no a=b=c chain).
> 2. in ustring is to compare with NaN to know when a value is NaN instead of compare to itself.
> 3. in kis_blur_effect is to clarify the priority of - and ?.
> (hard)
> 4. in kotextloader to remove 3 duplicated code. (at least the first and sencond, the third one is sligly different from the previous incarnation of the code).
> They are previously in the same else if chain.
> 5. in kotablerowstyle, remove 1 duplicated code (or is it missing some option?)
> 6. in kodfgraphicstyles, remove 1 dead entry (or it should compare to some other word?)
>
>
> Diffs
> -----
>
> filters/tables/excel/sidewinder/formulas.h 98559c8
> filters/tables/excel/sidewinder/formulas.cpp 5903dd6
> filters/words/msword-odf/wv2/src/ustring.cpp d9f1707
> krita/plugins/filters/blur/kis_blur_filter.cpp 3a45bc2
> libs/kotext/opendocument/KoTextLoader.cpp ce7c7a3
> libs/kotext/styles/KoTableRowStyle.cpp 6fc53c6
> libs/odf/KoOdfGraphicStyles.cpp f5860b9
>
> Diff: http://git.reviewboard.kde.org/r/101803/diff
>
>
> Testing
> -------
>
>
> Thanks,
>
> Jaime Torres
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/calligra-devel/attachments/20110630/5f549dd8/attachment.htm>
More information about the calligra-devel
mailing list