tags:

views:

64

answers:

1

Hello, I'm having some trouble getting a SplitLayoutPanel to display using UiBinder. It seems like the SplitLayoutPanel is hidden when the page loads. Thanks

Here's my code:

<!DOCTYPE ui:UiBinder SYSTEM "http://dl.google.com/gwt/DTD/xhtml.ent"&gt;
<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
    xmlns:g="urn:import:com.google.gwt.user.client.ui"
    xmlns:z="urn:import:com.zimfly.filebox.client"
    >
    <ui:style>
            .mainPanel {
                    background-image: url("images/bg.jpg");
                    background-repeat:repeat-x;
            }
    </ui:style>


    <g:ScrollPanel styleName="{style.mainPanel}">

            <g:HTMLPanel>

                    <br></br>

                    <g:VerticalPanel>
                            <g:HorizontalPanel>
                                    <g:HTML>&nbsp;&nbsp;</g:HTML>
                                    <g:Button ui:field="btnToggleUpload">Show Upload Form</g:Button>
                                    <g:HTML>&nbsp;&nbsp;</g:HTML>
                                    <g:Button ui:field='btnNewFolder'>New Folder</g:Button>
                            </g:HorizontalPanel>


                    </g:VerticalPanel>

                    <br></br>

                    <g:SplitLayoutPanel>    
                            <g:west size="300" unit='EM'>   
                                    <z:FilesTree ui:field="filesTree" />
                            </g:west>
                            <g:center>
                                    <z:FilesGrid ui:field="filesGrid" />
                            </g:center>
                    </g:SplitLayoutPanel>
            </g:HTMLPanel>
    </g:ScrollPanel>
</ui:UiBinder>
+1  A: 

First, check that the DOCTYPE declaration on your host page instructs the browsers to use standards mode.

EDIT: looks like the SplitLayoutPanel in your case needs a defined height value.

<!DOCTYPE html>

Strelok
The host page in the war directory has <!DOCTYPE html>thanks
clarity
I added a height and width and the SplitLayoutPanel was displayed
clarity