Divelements Community
Customer discussion of all Divelements products

Issue with popup control within a document window

Latest post 11-03-2008 11:16 by Melianos. 2 replies.
  • 10-06-2008 15:04

    Issue with popup control within a document window

    Hi,

    I am opening a popup control on click of a button, but the elements within the popup window do not seem to get focussed.

    XAMl -

    <Window x:Class="DemoApplication.Window1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
     xmlns:sd="clr-namespace:Divelements.SandDock;assembly=Divelements.SandDock"
            xmlns:local="clr-namespace:DemoApplication"
        Title="SandDock Demonstration Application" Width="1024" Height="768" SnapsToDevicePixels="True" WindowStartupLocation="CenterScreen"     >
        <sd:DockSite>

            <sd:DocumentContainer x:Name="documentContainer"  >

                <sd:SplitContainer>
                    <sd:WindowGroup>
                        <sd:DocumentWindow  Title="Welcome" Name="welcomeDocument" >
                            <Grid>
                                <StackPanel>
                                    <TextBox></TextBox>
                                    <Button   Click="Button_Click">Lookup</Button>


                                    <Popup x:Name="popup" Placement="MousePoint"    StaysOpen="False" >
                                        <sd:DockableWindow x:Name="test"   Title="EM" >

            <StackPanel >
                <CheckBox Grid.Column="0" Grid.Row="0" Margin="8"  Width="20" x:Name="chk" ></CheckBox>
                <TextBox Grid.Row="0" Grid.Column="1" Margin="5" Width="50" ></TextBox>
                            <TextBox Grid.Row="0" Grid.Column="2" Margin="5" Width="50"></TextBox>
                       </StackPanel>   

                           
                       
                    </sd:DockableWindow>

                                    </Popup>

                                </StackPanel>
                            </Grid>
                        </sd:DocumentWindow>
                    </sd:WindowGroup>
                </sd:SplitContainer>
            </sd:DocumentContainer>
        </sd:DockSite>
    </Window>

     

    As you can see the popup contains a textbox and checkbox. The checkbox never seems to retain focus.

  • 11-03-2008 11:15 In reply to

    Re: Issue with popup control within a document window

    hI Meghavi

     

    Why are you embedding a dockableWindow Within a popup ? Placing your controls inside a popup control is sufficient enough to do what you want

    If you try with this code then its fine (at least for me...)

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

    <

    Window x:Class="popupInsideDocumentWindow.Window1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x

    =http://schemas.microsoft.com/winfx/2006/xaml

    xmlns:sd="clr-namespace:Divelements.SandDock;assembly=Divelements.SandDock"

     

     

    xmlns:local="clr-namespace:popupInsideDocumentWindow"

     

     

    Title="SandDock Demonstration Application" Width="1024" Height="768" SnapsToDevicePixels="True" WindowStartupLocation="CenterScreen"

    >

     

     

    <sd:DockSite>

     

     

    <sd:DocumentContainer x:Name="documentContainer" >

     

     

    <sd:SplitContainer>

     

     

    <sd:WindowGroup>

     

     

    <sd:DocumentWindow Title="Welcome" Name="welcomeDocument" >

     

     

    <Grid>

     

     

    <StackPanel>

     

     

    <TextBox></TextBox>

     

     

    <Button Click="Button_Click">Lookup</Button>

     

     

     

    <Popup x:Name="popup" Placement="MousePoint" StaysOpen="False" >

     

     

    <StackPanel >

     

     

    <CheckBox Width="20" x:Name="chk" ></CheckBox>

     

     

    <TextBox Width="50" ></TextBox>

     

     

    <TextBox Width="50"></TextBox>

     

     

    </StackPanel>

     

     

    </Popup>

     

     

    </StackPanel>

     

     

    </Grid>

     

     

    </sd:DocumentWindow>

     

     

    </sd:WindowGroup>

     

     

    </sd:SplitContainer>

     

     

    </sd:DocumentContainer>

     

     

    </sd:DockSite>

    </

    Window>

  • 11-03-2008 11:16 In reply to

    Re: Issue with popup control within a document window

    Sorry for the horrible layout, there is now way to edit my post back so....Confused

Page 1 of 1 (3 items) | RSS
Copyright © 2008 Divelements Limited
Powered by Community Server (Commercial Edition), by Telligent Systems