<div dir="ltr">Hello!<br><br>This is a follow-up to the changes I sent in April ("Refactoring proposal for Browser>>classList"). The goal of these changes is to improve the separation between content and presentation in the browser. Last time I worked on the class list, and now the attached changesets apply the same idea to the message categories and methods lists, by giving each list a single extension point where the presentation of their items can be defined.<br><br>I kept the same conventions of the previous changes, where the messages for the class list were <span style="font-family:monospace">#classList</span> (returns a collection of classes), <span style="font-family:monospace">#classItems</span> (returns labels), and <span style="font-family:monospace">#labelForClass:</span> (returns the label for each class).<br>In this case we have something similar: <span style="font-family:monospace">#messageCategoryList/#messageList</span> return symbols, <span style="font-family:monospace">#messageCategoryItems/#messageItems</span> return labels, and <span style="font-family:monospace">#labelForCategory:/#labelForSelector:</span> return the label specific for one category/selector.<br><br><div>To help during review, I split the work into small sequential change sets, each of which also migrates the windows already open in the image. Here's a summary of the changes:</div><ol><li><i>implement_labelForCategory_for_browser</i>: the extension point for the message categories list.</li><li><i>implement_labelForSelector_for_browser</i>: the extension point for the methods list. The coloring that <span style="font-family:monospace">CodeFileBrowser</span> used to do inside <span style="font-family:monospace">#messageList</span> moves to its <span style="font-family:monospace">#labelForSelector:</span> override, so the <span style="font-family:monospace">#messageList</span> override is no longer needed. I also adjusted <span style="font-family:monospace">#categorizeUnderCategoryAt:selector:</span> because drag and drop now passes it an item, not a selector.</li><li><i>use_labelForSelector_from_ChangeSorter</i>: the <span style="font-family:monospace">ChangeSorter</span> method list is now a regular <span style="font-family:monospace">PluggableListMorph</span> over <span style="font-family:monospace">#messageItems</span>, so the index methods now translate between the index and <span style="font-family:monospace">#currentSelector</span>.</li><li><i>implement_labelForSelector_for_MethodSet</i>: the same extension point for <span style="font-family:monospace">MethodSet</span>. I also included a small cleanup of a redundant assignment in <span style="font-family:monospace">MessageNames>>messageList</span>.</li><li><i>haveFun</i>: this last one is not meant for integration, but it's useful to test the changes. It overrides the three label methods to show icons and colors in all of the lists, to demonstrate what the extension points make possible.</li></ol><br>Cheers!<br>Facu</div>