Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    1. COIndeed that was what I was thinking, my code was too tightly coupled to a particular UI control. Actually what I had in mind was having a textbox as a search field which would update the contents of the listbox/listview. There would be a select/commit button, but the user should also be able to press the arrow keys (with the textbox selected) to change the selection in the list, and then press enter to commit. If I am not to expose selected index or have some logic in the view, what do I do then? Perhaps I should have MoveSelectionDown() and MoveSelectionUp() which the presenter could call?
      singulars
    2. COBut this would all change if your view used completely different controls? Your presenter should be unaware of any UI specifics. Maybe you should let your presenter's unit tests drive what functionality you put into the presenter and what can remain in the view. Why does your presenter need to change what's selected, doesn't the user do that and then just click something?
      singulars
    3. COYes, the user can click something. But I also wanted the user to be able to only use the keyboard (without tabbing his way around). So when when the view popped up the search box would be selected, the user would then type something to search and the just press the arrows keys (up/down) and then Enter when he had selected what he wanted. All of this would happen with the search box selected. I am leaning towards just having some logic in the view and simply raise an event (which the presenter can subscribe to) to say the user made a selection.
      singulars
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload