views:

41

answers:

0

Using CompositeWPF I have the following setup:

<Window x:Name="MainWindow">
  <View x:Name="MainView">
    <View x:Name="CurrentSelectedView"/>
  </View>
</Window>

MainView is a view containing a menu structure. CurrentSelectedView changes depending on the menu selection you make. For this example lets assume the CurrentSelectedView contains a Grid with several custom made ComboBox controls.

The problem is that I need to be able to navigate the entire screen using 4 keyboard buttons: Enter, Cancel, Tab and Shift-tab. So, at startup the first menu item is selected, you use Tab to navigate to the next, press Enter, a menu popup opens, you select one using Tab (which uses Cycle to loop through the items, that's nice), press Enter to select one and the corresponding view is loaded. I would like the first control (or the one I can mark as first) to be selected and select the first item in the view. I can use movefocus to change the focus, but when I hit Tab I'm still positioned in the menu and not within the view.

How can I move the selection to a given item in my view, preferably limit the Tab usage so it cycles through the elements on my view, until I press cancel and the menu is focused again. Is this even possible, without spending days and days making modifications in every control and every view and viewmodel? The internet is filled with focus issues, but none seem to be specific enough for what I need to do.