Index: /extras/pLoader/trunk/src/Uploader/GUI/wxApp.pm
===================================================================
--- /extras/pLoader/trunk/src/Uploader/GUI/wxApp.pm	(revision 3283)
+++ /extras/pLoader/trunk/src/Uploader/GUI/wxApp.pm	(revision 3284)
@@ -306,4 +306,5 @@
           use_offline
           login_dlg
+          branding
       / 
 );
@@ -357,4 +358,5 @@
         $self->{site_url}
     );
+    
 
     $self->site_username(
@@ -527,4 +529,5 @@
       	th_quality       => 90,
         auto_rotate      => 1,
+        remove_uploaded_from_selection => 1,
         interlace        => 'Line',
         create_resized   => 1,
@@ -535,5 +538,5 @@
         userdata_dir     => $self->userdata_dir,
         default_photo_name => gettext('File name'),
-        default_name_prefix => 'Photo',
+        default_name_prefix => gettext('Photo'),
         upload_rejects   =>  [],
         image_sums       => {},
@@ -571,4 +574,7 @@
     $self->login_dlg->Show(0);
 
+    $self->_init_branding;
+
+
     $self->pwg(
         # get these parameters from dialog or from file
@@ -578,4 +584,5 @@
                 site_username  => $self->site_username,
                 site_password  => $self->site_password,
+                branding       => $self->branding,
             }
         )
@@ -818,5 +825,44 @@
 }
 
-
+# some labels differ with branding ( piwigo.com or piwigo.org )
+sub _init_branding {
+    my ( $self ) =@_;
+    
+    if( $self->site_url =~ /\.piwigo\.com/ ){
+        $self->branding(
+            {
+                category  => gettext("album"),	
+                Category  => gettext("Album"),	
+                categories => gettext("albums"),	
+                Categories => gettext("Albums"),
+                'Add new category' => gettext("Add new album"),	
+            }
+        );
+    }
+    else{
+        $self->branding(
+            {
+                categorie  => gettext("categorie"),	
+                Categorie  => gettext("Categorie"),	
+                categories => gettext("categories"),	
+                Categories => gettext("Categories"),	
+                'Add new category' => gettext("Add new category"),	
+            }
+        );
+    }	
+}
+
+sub SaveConfig {
+    my ( $self, $params ) = @_;	
+
+   my $config = Wx::ConfigBase::Get;
+
+   map {
+       $config->WriteInt( $_, $params->{$_} )
+   } keys %$params;
+
+   $config->Write( 'Perspective', $params->{Perspective} )
+	
+}
 
 
@@ -830,6 +876,9 @@
     my $w = $config->ReadInt( "Width", 1024 );
     my $h = $config->ReadInt( "height", 768 );
-    my $sv = $config->ReadInt( "splitVertical", 150 );
-    my $sh = $config->ReadInt( "splitHorizontal", 300 );
+    my $prev_w = $config->ReadInt( "PreviewWidth", 400 );
+    my $prev_h = $config->ReadInt( "PreviewHeight", 300 );
+    my $perspective = $config->Read( "Perspective" );
+    
+    #printf("Config x %s, y %s, w %s, h %s, prev_w %s, prev_h %s\n", $x, $y, $w, $h, $prev_w, $prev_h);
     
     my $url = $self->site_url;
@@ -848,9 +897,11 @@
             pwg       => $self->pwg,
             imagelist => $self->imagelist,
+            preview_w => $prev_w,
+            preview_h => $prev_h,
+            perspective => $perspective,
         }
     );
 	
-	#printf("Config x %s, y %s, w %s, h %s\n", $x, $y, $w, $h);
-	#$frame->SetSize( $x, $y, $w, $h );
+    $frame->SetSize( $x, $y, $w, $h );
     $frame->Show( 1 );
     $self->SetTopWindow( $frame );
Index: /extras/pLoader/trunk/src/Uploader/GUI/wxFrameAUI.pm
===================================================================
--- /extras/pLoader/trunk/src/Uploader/GUI/wxFrameAUI.pm	(revision 3283)
+++ /extras/pLoader/trunk/src/Uploader/GUI/wxFrameAUI.pm	(revision 3284)
@@ -335,4 +335,8 @@
           preview_settings
           toolbar
+          branding
+          preview_w
+          preview_h
+          perspective
       /;
 __PACKAGE__->mk_accessors( @properties );
@@ -345,4 +349,5 @@
           EVT_LIST_END_LABEL_EDIT
           EVT_LIST_ITEM_SELECTED
+          EVT_LIST_ITEM_ACTIVATED
           EVT_TREE_ITEM_RIGHT_CLICK
           EVT_LIST_KEY_DOWN
@@ -374,4 +379,16 @@
                                       wxDEFAULT_FRAME_STYLE|wxMAXIMIZE
                                    );
+    $self->preview_w(
+        $params->{preview_w}||400
+    );
+
+    $self->preview_h(
+        $params->{preview_h}||300
+    );
+    
+    $self->perspective(
+        $params->{perspective}
+    );
+
     $self->pwg( $params->{pwg} );
     $self->imagelist( $params->{imagelist} );
@@ -426,5 +443,7 @@
     );
 
+
     $self->manager( Wx::AuiManager->new );
+    $self->manager->SetDockSizeConstraint(1, 1);
     $self->manager->SetManagedWindow( $self );
     $self->_set_setting_properties;
@@ -436,4 +455,5 @@
 }
 
+
 sub _initImgTypes {
     my ( $self ) = @_;
@@ -461,5 +481,5 @@
         [
             {
-                label => "Photo name :",
+                label => gettext("Photo caption :"),
                 value => sub { $self->imagelist->current_image->site_name(@_) },
             },
@@ -548,5 +568,5 @@
             },
             {
-                label     => gettext("Default photo name :"),
+                label     => gettext("Default photo caption :"),
                 type      => 'Choice',
                 value	=> sub { $self->imagelist->default_photo_name(@_) },
@@ -563,5 +583,5 @@
             },
             {
-                label     => gettext("Photo name  prefix :"),
+                label     => gettext("Photo caption  prefix :"),
                 value	=> sub { $self->imagelist->default_name_prefix(@_) },
             },
@@ -581,4 +601,9 @@
                 value	=> sub { $self->imagelist->upload_high(@_) },
             },
+#            {
+#                label     => gettext("Remove uploaded photo from selection :"),
+#                type      => 'Bool',
+#                value	=> sub { $self->imagelist->remove_uploaded_from_selection(@_) },
+#            },
         ]    
     );
@@ -822,5 +847,4 @@
         )    
     );    
-
     
     $self->general_settings_panel->Show(0);
@@ -830,13 +854,11 @@
             $self,
             -1,
-            wxNullBitmap
+            wxNullBitmap,
+            wxDefaultPosition,
+            [$self->preview_w, $self->preview_h]
         )
     );
 
-
-
     $self->image_prop_piwigo->Show(0);
-
-        
     
     $self->image_prop_exif->Show(0);
@@ -890,5 +912,5 @@
 sub init_aui {
     my ( $self ) = @_;
-    
+
     my $url = wxTheApp->site_url;
     
@@ -901,5 +923,5 @@
     $self->manager->AddPane
       ( $self->create_tree, Wx::AuiPaneInfo->new->Name( "categories" )->Caption(
-          sprintf("%s - %s", gettext("Piwigo categories"), $url )
+          sprintf("%s - %s", sprintf("Piwigo %s", wxTheApp->branding->{categories}), $url )
       )
         ->Right->Position( 0 )->Resizable->CloseButton(0) );
@@ -920,4 +942,8 @@
         ->ToolbarPane->Top->Row( 1 )->LeftDockable( 0 )->RightDockable( 0 ) ) if defined $self->toolbar;
 
+    if( $self->perspective){
+        $self->manager->LoadPerspective($self->perspective);
+    }
+    
     $self->manager->Update;
 
@@ -929,18 +955,29 @@
     $self->manager->AddPane
       ( $self->create_notebook_image_properties, Wx::AuiPaneInfo->new->Name( "photo_properties" )->Caption(gettext("Photo properties"))
-        ->Right->Position( 1 )->Resizable->CloseButton(0) );
+        ->Floatable(1)->Resizable->CloseButton(1) );
 
     $self->manager->AddPane
       ( $self->create_notebook_global_settings, Wx::AuiPaneInfo->new->Name( "global_settings" )->Caption(gettext("Global settings"))
-        ->Right->Position( 2 )->Resizable->CloseButton(1) );
-
+        ->Floatable(1)->Resizable->CloseButton(1) );
+
+    $self->manager->GetPane("photo_properties")->Show(0);
     $self->manager->GetPane("global_settings")->Show(0);
 	
 }
 
+sub OnPhotoProperties {
+    my ( $self ) = @_;
+
+    $self->manager->GetPane("photo_properties")->Float;
+    $self->manager->GetPane("photo_properties")->Show(1);
+    $self->manager->Update();    
+	
+}
+
 sub OnGlobalSettings {
     my ( $self ) = @_;
 
     $self->toolbar->EnableTool(104, 0 );
+    $self->manager->GetPane("global_settings")->Float;
     $self->manager->GetPane("global_settings")->Show(1);
     $self->manager->Update();    
@@ -1115,18 +1152,4 @@
 }
 
-#$tree_items is a list of anonymous arrays
-# [ itemLabel, undef, rootInfo, ImageIndex, SelImageIndex ] for the root
-
-# [ itemLabel, 
-#       [ childItemLabel, 
-#           [...], 
-#           childItemdata, 
-#           childImageIndex, 
-#           childSelImageIndex
-#       ], 
-#    Itemdata, 
-#    ImageIndex, 
-#    SelImageIndex 
-# ]
 
 # returns a valid itemData
@@ -1217,4 +1240,5 @@
     EVT_TREE_ITEM_RIGHT_CLICK( $self->tree, $self->tree, \&OnTreeItemRightClick );
     EVT_LIST_END_LABEL_EDIT( $self, $self->imageviewer, \&OnImageViewerEndLabelEdit );
+    EVT_LIST_ITEM_ACTIVATED( $self, $self->imageviewer, \&OnImageViewerItemActivated );
     EVT_LIST_ITEM_SELECTED($self, $self->imageviewer, \&OnImageViewerItemSelected) ;
     EVT_LIST_KEY_DOWN($self, $self->imageviewer, \&OnImageViewerKeyDown) ;
@@ -1234,6 +1258,6 @@
     my( $self, $event ) = @_;
     my $dialog = Wx::FileDialog->new
-      ( $self, "Select photos to send", $prevfile, $prevdir,
-        "JPEG files (*.jpg)|*.jpg|All(*.*)|*.*",
+      ( $self, gettext("Select photos for upload"), $prevfile, $prevdir,
+        sprintf("%s (*.jpg)|*.jpg|All(*.*)|*.*", gettext("JPEG files")),
         wxFD_OPEN|wxFD_MULTIPLE );
 
@@ -1332,6 +1356,23 @@
     }
     (
-        [1+$ID_TREE_CTX_MENU, "Add new category","Add a new category to the current selected category."],
-        [2+$ID_TREE_CTX_MENU, "Refresh","Refresh category list."],
+        [
+            1+$ID_TREE_CTX_MENU, 
+            wxTheApp->branding->{'Add new category'},
+            sprintf(
+                "%s %s %s %s", 
+                gettext("Add a new"), 
+                wxTheApp->branding->{category},
+                gettext("to the currently selected"),
+                wxTheApp->branding->{category},
+            )
+        ],
+        [
+            2+$ID_TREE_CTX_MENU, 
+            "Refresh",
+            sprintf(
+                "Refresh %s list.",
+                wxTheApp->branding->{category},
+            )
+        ],
     );
     $self->PopupMenu($ctx_mnu, $point);
@@ -1351,7 +1392,7 @@
     my $dialog = Wx::TextEntryDialog->new( 
         $self, 
-        gettext("Category name :"), 
-        gettext("Add new category"),
-        gettext("New category"), 
+        sprintf("Category name :", wxTheApp->branding->{Category}), 
+        sprintf("Add new %s", wxTheApp->branding->{category}),
+        sprintf("New %s", wxTheApp->branding->{category}), 
     );
 
@@ -1390,4 +1431,10 @@
     	
     $self->image_prop_piwigo->Refresh;
+}
+
+sub OnImageViewerItemActivated {
+    my( $self, $event ) = @_;
+
+    $self->OnPhotoProperties;
 }
 
@@ -1591,5 +1638,7 @@
         Wx::MessageBox( 
             sprintf(
-                gettext("Please select a valid target category"),
+                "%s %s", 
+                gettext("Please select a valid target"),
+                wxTheApp->branding->{category}
             ),
             gettext("Piwigo upload error"),
@@ -1632,4 +1681,5 @@
   my $self = shift;
 
+
     # Restaure previous log wnd
     Wx::Log::SetActiveTarget( $self->oldlogwnd );
@@ -1641,4 +1691,15 @@
     $self->imagelist->Store;
     wxTheApp->login_dlg->Destroy;	
+
+    my $params = {};
+
+    ( $params->{'X'}, $params->{'Y'} ) = $self->GetPositionXY ;
+    ( $params->{'Width'}, $params->{'Height'} ) = $self->GetSizeWH ;
+    ( $params->{'PreviewWidth'}, $params->{'PreviewHeight'} ) = $self->image_preview->GetSizeWH ;
+    $params->{Perspective} = $self->manager->SavePerspective;
+    
+
+    wxTheApp->SaveConfig( $params );
+
     $self->Destroy;
 }
