[haiku-commits] Re: haiku: hrev44406 - src/apps/stylededit

  • From: Jérôme Duval <korli@xxxxxxxxxxxxxxxx>
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Wed, 25 Jul 2012 19:52:17 +0200

2012/7/25  <humdingerb@xxxxxxxxxxxxxx>:
> +       // start from the beginning of text
> +       fTextView->Select(0,0);
> +
> +       int32 start, finish;
> +
> +       // iterate occurences of findThis without wrapping around
> +       while (_Search(findThis, caseSensitive, false, false, false)) {
>                 if (first) {
>                         _UpdateCleanUndoRedoSaveRevert();
>                         first = false;
>                 }
> -               int32 start, finish;
> +
>                 fTextView->GetSelection(&start, &finish);

There was no need to move start and finish declarations outside out of the loop.

Bye,
Jérôme

Other related posts: