After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 768534 - editor-frame: Prevent search position label flickering during replace
editor-frame: Prevent search position label flickering during replace
Status: RESOLVED FIXED
Product: gnome-builder
Classification: Other
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: GNOME Builder Maintainers
GNOME Builder Maintainers
Depends on:
Blocks:
 
 
Reported: 2016-07-07 21:18 UTC by Matthew Leeds
Modified: 2016-07-08 20:43 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
editor-frame: Prevent search position label flickering during replace (1.76 KB, patch)
2016-07-07 21:18 UTC, Matthew Leeds
accepted-commit_now Details | Review

Description Matthew Leeds 2016-07-07 21:18:10 UTC
This fixes one of the flickering bugs slaf pointed out. The other is
that the replaced text itself flickers when it's replaced if the replace
text contains the search text in it. I haven't been able to figure that
one out.
Comment 1 Matthew Leeds 2016-07-07 21:18:13 UTC
Created attachment 331031 [details] [review]
editor-frame: Prevent search position label flickering during replace

In ide_editor_frame_actions_replace, when the replace is executed the
deletion and insertion in the buffer cause the search position label
(e.g. "1 of 29") to be updated, but at that time the occurrences-count
is unknown since that part of the buffer needs to be re-scanned, so the
label is set to NULL. Only once the scan finishes can the corect label
be set. So this commit prevents the search position label from being
updated when the cursor moves during the replacement, which prevents
ugly flickering for the user.
Comment 2 Christian Hergert 2016-07-08 01:54:49 UTC
Review of attachment 331031 [details] [review]:

LGTM
Comment 3 Matthew Leeds 2016-07-08 20:43:20 UTC
Pushed as commit 39a74ba23fa5f0003d474fd30aa8211b957fbd87