Changeset 5403 for extensions/pLoader


Ignore:
Timestamp:
Mar 27, 2010, 11:38:11 AM (14 years ago)
Author:
ronosman
Message:

Fix sizer issues on photo properties layout : categories treectrl expands vertically depending on number of categories.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/pLoader/trunk/src/Uploader/GUI/Layout/PhotoPropertiesCategoriesTags.pm

    r5394 r5403  
    5353
    5454    # defines minimum size
    55     my( $item2 ) = Wx::Notebook->new( $parent, $main::PHOTO_PROPERTIES_NB, wxDefaultPosition, [450,160], 0 );
     55    my( $item2 ) = Wx::Notebook->new( $parent, $main::PHOTO_PROPERTIES_NB, wxDefaultPosition, [450,-1], 0 );
    5656    my( $item1 ) = $item2;
    5757    if( Wx->VERSION < 0.21 ) {
     
    7272    );
    7373    $tree_categories->Populate;
    74     $topsizer->AddWindow( $tree_categories, 1, wxEXPAND|wxALL, 5 );
     74    my( $cat_sizer ) = Wx::BoxSizer->new( wxHORIZONTAL );
     75    $cat_sizer->Add( $tree_categories, 1, wxEXPAND|wxALL, 5 );
     76
     77    $topsizer->Add( $cat_sizer, 1, wxEXPAND|wxALL, 5 );
    7578
    7679    my( $item4 ) = Wx::StaticLine->new( $parent, $main::ID_LINE, wxDefaultPosition, [20,-1], wxLI_HORIZONTAL );
     
    8487
    8588    $parent->SetSizer( $topsizer );
    86     $topsizer->SetSizeHints( $parent );
     89    $topsizer->Fit( $parent );
    8790
    8891    $topsizer;
     
    9598    my( $topsizer ) = Wx::BoxSizer->new( wxVERTICAL );
    9699   
    97     my( $item1 ) = Wx::StaticText->new( $parent, $main::TAGS, "text", wxDefaultPosition, wxDefaultSize, 0 );
    98     $topsizer->AddWindow( $item1, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM, 5 );
    99 
    100100    $tags->{parentwnd}=$parent;
    101101    my( $panel ) = Uploader::GUI::wxChoiceFilteredPanel->new($tags);
    102102    # the panel has adaptive size : stretch factor 1, wxEXPAND
    103     $topsizer->AddWindow( $panel, 1, wxEXPAND|wxALIGN_CENTER_VERTICAL|wxALL, 5 );
     103    $topsizer->AddWindow( $panel, 1, wxEXPAND|wxALL, 5 );
    104104
    105105    $parent->SetSizer( $topsizer );
    106     $topsizer->SetSizeHints( $parent );
     106    $topsizer->Fit( $parent );
    107107   
    108108    $topsizer;
     
    198198
    199199    $parent->SetSizer( $topsizer );
    200     $topsizer->SetSizeHints( $parent );
     200    $topsizer->Fit( $parent );
    201201   
    202202    $topsizer;
Note: See TracChangeset for help on using the changeset viewer.