User "Amire80" posted a comment on MediaWiki.r96944. Full URL: http://www.mediawiki.org/wiki/Special:Code/MediaWiki/96944#c22426 Commit summary:
(bug 20919) Search & Replace: Change "Replace Next" functionality to "Replace" functionality. Patch by Amir E. Aharoni. Submitter's comment: "Replace next" now replaces the currently selected text instead of finding the next occurrence and replacing it. To keep the location of the current occurrence, i added matchIndex to $(this).data. I added some comments renamed a couple of variable for readability: * s to textRemainder * replace to actualReplacement This is my first significant jQuery-style patch so it may have embarrassing mistakes - constructive criticism is welcome. Comment: I already have a comment: the "Replace next" button should be greyed out until the first occurrence is found using "Find next". What's the right way to do it? _______________________________________________ MediaWiki-CodeReview mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/mediawiki-codereview
