| 1 | [[BackLinksMenu]] |
| 2 | |
| 3 | [[TicketQuery(summary=TASK_NAME_HERE, format=table, col=summary|owner|status|type|component|priority|effort|importance, rows=description|analysis_owners|analysis_reviewers|analysis_score|design_owners|design_reviewers|design_score|implementation_owners|implementation_reviewers|implementation_score|test_owners|test_reviewers|test_score|)]] |
| 4 | |
| 5 | = Analysis = |
| 6 | |
| 7 | == Overview == |
| 8 | * The goal of this task is to remove some code smells from controllers: |
| 9 | * Inconsistent naming in event and handlers. |
| 10 | * Inconsistent location of controllers - some related controllers are in sepaerate files, some are nested in the corresponding view, others - not, etc. |
| 11 | * Menu items have {{{clicked}}} method instead of firing an R3 event. For some items it is trivial to switch to R3 Logic. |
| 12 | * Not all menu items will be refactored. |
| 13 | * No new functionality is going to be added. |
| 14 | |
| 15 | == Task requirements == |
| 16 | * Rename all nested enums that contain event IDs to {{{EventIds}}}. |
| 17 | * In logic enums, names of all items should begin with "ON_", followed by the event ID, where possible. |
| 18 | * For example, the event CLICK can be handled by ON_CLICK. |
| 19 | * Check for inconsistent names - for example, {{{FRAME_REMOVED}}} is not a good name if the frame is removed during the handling of the event. {{{FRAME_REMOVE}}} is a better name. |
| 20 | * In {{{main.app.commons}}} logics should not be in separated subpackage. Instead, move each logic enum to the package with the corresponding views. |
| 21 | * For halo buttons, extract logics and group them by functionality. |
| 22 | * For example, create {{{org.sophie2.main.app.halos.grouping.GroupHalosLogic}}} which handles events from all halo buttons related to grouping. |
| 23 | * In menu items deprecate the method {{{clicked}}}. |
| 24 | * Create a new event CLICKED that should be fired when a menu item is clicked. |
| 25 | * For all menu items, that just fire R3 event, remove the {{{clicked}}} method and change the filter in the controllers - it should listen for {{{MenuItem.EventIds.CLICKED}}}. |
| 26 | |
| 27 | == Task result == |
| 28 | * Source code |
| 29 | |
| 30 | == Implementation idea == |
| 31 | ^(Provide some rough implementation idea(s).)^ |
| 32 | |
| 33 | == Related == |
| 34 | ^(Add links to related tasks that could be useful or helpful.)^ |
| 35 | |
| 36 | == How to demo == |
| 37 | * The task has no visible result. |
| 38 | |
| 39 | = Design = |
| 40 | ^(Describe your design here.)^ |
| 41 | |
| 42 | = Implementation = |
| 43 | ^(Describe and link the implementation results here (from the wiki or the repository).)^ |
| 44 | |
| 45 | = Testing = |
| 46 | ^(Place the testing results here.)^ |
| 47 | |
| 48 | = Comments = |
| 49 | ^(Write comments for this or later revisions here.) |