When TabItem loses focus, all controls on TabItem GET focus

2 posts, 0 answers
  1. C Bates
    C Bates avatar
    33 posts
    Member since:
    Oct 2009

    Posted 09 Feb 2010 Link to this post

    I have put together a simple app to demonstrate the problem.  I have a RadTabItem with several TextBox controls on it.
    If I:
    - click in a TextBox
    - click on another tab header in the same group
    All the TextBox controls on the first TabItem receive a "GotFocus" event.
    Very undesirable, since every time certain controls in our real application gets focus it initiates a round-trip to the server.
    The xaml:
            <dock:RadDocking x:Name="docking" Grid.Row="1"
                    <dock:RadSplitContainer x:Name="mapContainer1"
                        <dock:RadPaneGroup x:Name="leftGroup" GotFocus="Group_GotFocus"
                            <dock:RadPane x:Name="leftPane" GotFocus="Pane_GotFocus"
                                <tab:RadTabControl x:Name="leftTabControl"  GotFocus="TabControl_GotFocus" > 
                                    <tab:RadTabItem Header="tab1" GotFocus="RadTabItem_GotFocus"
                                            <TextBox x:Name="tb1" Text="tb1"  GotFocus="TextBox_GotFocus" /> 
                                            <TextBox x:Name="tb2" Text="tb2" GotFocus="TextBox_GotFocus" /> 
                                            <TextBox x:Name="tb3" Text="tb3"  GotFocus="TextBox_GotFocus" /> 
                                            <TextBox x:Name="tb4" Text="tb4" GotFocus="TextBox_GotFocus" /> 
                                            <TextBox x:Name="tb5" Text="tb5" GotFocus="TextBox_GotFocus" /> 
                                            <TextBox x:Name="tb6" Text="tb6" GotFocus="TextBox_GotFocus" /> 
                                    <tab:RadTabItem Header="tab2" GotFocus="RadTabItem_GotFocus"
                                            <TextBox x:Name="tb7" Text="tb7" GotFocus="TextBox_GotFocus" /> 
                                            <TextBox x:Name="tb8" Text="tb8" GotFocus="TextBox_GotFocus" /> 
                                            <TextBox x:Name="tb9" Text="tb9" GotFocus="TextBox_GotFocus" /> 
    Is this a bug?  Is there a work-around?
    (In the screenshot, I started the app, clicked on tb1, then clicked on tab2.  tb1 - tb6 received GotFocus events.)

    Update:  If I click on tb1, then click on tab1 (does nothing, since tab1 is already the selected tab), then click on tab2, tb1 - tb6  _don't_ get all the GotFocus events.  Weird.

  2. Ivan
    Ivan avatar
    519 posts

    Posted 14 Feb 2010 Link to this post

    Hi Bates,

    Thank you for reporting the issue.

    We confirm the observable effect - it is related to the tab-page that is becoming invisible.

    According your report we updated your Telerik points.

    Best wishes,
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  3. DevCraft banner
Back to Top