Fwd: [ktexteditor] src/render: Fix "Clazy fix" mistake that broke selection handling/layout cache

Dominik Haumann dhaumann at kde.org
Sat Mar 26 13:11:32 GMT 2016


Dear KDE packagers,

if you package KDE Frameworks 5.20, please consider
applying the fix below for the KTextEditor framework - it makes text
selection in Kate work again.

This fix will be included in the next release automatically.

Thanks,
Dominik


On Fri, Mar 25, 2016 at 10:42 PM, Kåre Särs <kare.sars at iki.fi> wrote:
> Git commit f7f330b21aa394a62ac95ea9bee075f372ff6d9c by Kåre Särs.
> Committed on 25/03/2016 at 21:32.
> Pushed by sars into branch 'master'.
>
> Fix "Clazy fix" mistake that broke selection handling/layout cache
>
> Among the Clazy warning fixes, was one "count() -> !isEmpty()" that
> should not have been there in katelayoutcache.cpp
>
> CCMAIL: kwrite-devel at kde.org
>
> M  +1    -1    src/render/katelayoutcache.cpp
>
> http://commits.kde.org/ktexteditor/f7f330b21aa394a62ac95ea9bee075f372ff6d9c
>
> diff --git a/src/render/katelayoutcache.cpp b/src/render/katelayoutcache.cpp
> index 33781fe..3eb268f 100644
> --- a/src/render/katelayoutcache.cpp
> +++ b/src/render/katelayoutcache.cpp
> @@ -165,7 +165,7 @@ void KateLayoutCache::updateViewCache(const KTextEditor::Cursor &startPos, int n
>  {
>      //qCDebug(LOG_KTE) << startPos << " nvlc " << newViewLineCount << " vls " << viewLinesScrolled;
>
> -    int oldViewLineCount = !m_textLayouts.isEmpty();
> +    int oldViewLineCount = m_textLayouts.count();
>      if (newViewLineCount == -1) {
>          newViewLineCount = oldViewLineCount;
>      }
> _______________________________________________
> KWrite-Devel mailing list
> KWrite-Devel at kde.org
> https://mail.kde.org/mailman/listinfo/kwrite-devel



More information about the Distributions mailing list