Changeset 4718 for extensions/pLoader/trunk
- Timestamp:
- Jan 21, 2010, 11:36:13 PM (15 years ago)
- Location:
- extensions/pLoader/trunk
- Files:
-
- 3 added
- 1 deleted
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/pLoader/trunk/res/global_settings_wdr.pl
r4616 r4718 140 140 $parent->{sb_thumbnail} = $item14; 141 141 142 my( $item16 ) = Wx::CollapsiblePane->new( $parent, $main::CPANE_THUMBNAIL, "", wxDefaultPosition, wxDefaultSize, 0|wxCP_DEFAULT_STYLE );142 my( $item16 ) = Wx::CollapsiblePane->new( $parent, $main::CPANE_THUMBNAIL, "", wxDefaultPosition, [300,-1], 0|wxCP_DEFAULT_STYLE ); 143 143 my( $oldparent ) = $parent; 144 144 $parent = $item16->GetPane(); -
extensions/pLoader/trunk/src/Uploader/GUI/wxApp.pm
r4632 r4718 56 56 wxLANGUAGE_SPANISH 57 57 /; 58 use Uploader::GUI::wxFrameAUI;59 58 use File::Slurp ; 60 59 use Data::Dumper; … … 98 97 branding 99 98 frame 100 perspective101 99 imageviewerIndex 102 100 frameLayout … … 159 157 160 158 $self->version( 161 '2.0.7 b'159 '2.0.7c' 162 160 ); 163 161 164 162 # to check if we can use stored cache 165 163 $self->imagelist_version( 166 '1 1'164 '13' 167 165 ); 168 166 … … 257 255 $self->_init_thumbimagelist; 258 256 $self->_set_stored_layout; 259 $self->_init_frame;257 #$self->_init_frame; 260 258 } 261 259 … … 509 507 } 510 508 qw/ 511 perspective512 509 imageviewerIndex 513 510 frameLayout … … 966 963 } keys %$params; 967 964 968 $config->Write( 'Perspective', $params->{Perspective} )969 965 970 966 } 971 967 972 968 973 sub _init_frame {974 my ( $self ) = @_;969 sub SetFrame { 970 my ( $self, $frame ) = @_; 975 971 976 972 my $url = $self->site_url; … … 980 976 } 981 977 982 $self->frame( 983 Uploader::GUI::wxFrameAUI->new( 984 { 985 title => sprintf("pLoader - Piwigo uploader %s - [%s]", $self->version, $url), 986 pwg => $self->pwg, 987 imagelist => $self->imagelist, 988 perspective => $self->perspective, 989 imageviewer_index => $self->imageviewerIndex, 990 frameLayout => $self->frameLayout, 991 } 992 ) 993 ); 994 995 $self->frame->Show( 1 ); 996 $self->SetTopWindow( $self->frame ); 978 $self->frame($frame); 997 979 998 980 my $icon = Wx::Icon->new(); -
extensions/pLoader/trunk/src/Uploader/GUI/wxGlobalSettings.pm
r4616 r4718 30 30 wxVERTICAL 31 31 wxFULL_REPAINT_ON_RESIZE 32 wxCLIP_CHILDREN 33 wxDEFAULT_DIALOG_STYLE 34 wxCAPTION 35 wxCLOSE_BOX 36 wxMAXIMIZE_BOX 37 wxMINIMIZE_BOX 38 wxRESIZE_BORDER 39 wxSTAY_ON_TOP 32 40 /; 33 use base qw/Wx:: PanelUploader::GUI::DlgCommon/;41 use base qw/Wx::Dialog Uploader::GUI::DlgCommon/; 34 42 use Wx::Event qw/ 35 43 EVT_CLOSE … … 45 53 46 54 47 my $self = $class->SUPER::new( $params->{parentwnd}, -1, wxDefaultPosition, wxDefaultSize, wxFULL_REPAINT_ON_RESIZE ); 55 my $self = $class->SUPER::new( 56 undef, 57 -1, 58 $params->{caption}, 59 wxDefaultPosition, 60 wxDefaultSize, 61 wxCAPTION| 62 wxCLOSE_BOX| 63 wxMAXIMIZE_BOX| 64 wxMINIMIZE_BOX| 65 wxRESIZE_BORDER| 66 wxDEFAULT_DIALOG_STYLE| 67 wxSTAY_ON_TOP 68 ); 69 70 71 72 48 73 $self->{tags} = $params->{tags}; 49 74 $self->{orientation} = $params->{orientation}||wxVERTICAL; … … 68 93 $self->{cpane_transfert_advanced} = $self->FindWindow($main::CPANE_TRANSFERT_ADVANCED); 69 94 95 $self->{gs_close} = $self->FindWindow($main::GS_CLOSE); 96 70 97 $self->InitLabels(); 71 98 $self->InitChoices(); … … 90 117 my ( $self ) = @_; 91 118 92 EVT_CLOSE( $self, \&OnClose );119 Wx::Event::EVT_BUTTON( $self, $self->{gs_close}, \&OnClose ); 93 120 Wx::Event::EVT_COLLAPSIBLEPANE_CHANGED( $self, $self->{cpane_thumbnail}, \&OnPaneChanged ); 94 121 Wx::Event::EVT_COLLAPSIBLEPANE_CHANGED( $self, $self->{cpane_resize}, \&OnPaneChanged ); … … 112 139 113 140 114 $self-> Destroy;141 $self->Hide; 115 142 } 116 143 … … 118 145 my( $self, $event ) = @_; 119 146 120 $self->_layout;147 #$self->_layout; 121 148 $event->Skip; 122 149 } … … 173 200 174 201 $self->{cpane_resize}->Collapse($b); 175 $self->_layout;202 #$self->_layout; 176 203 $event->Skip; 177 204 … … 192 219 } 193 220 $self->{cpane_hd}->Collapse($b); 194 $self->_layout;221 #$self->_layout; 195 222 $event->Skip; 196 223 } … … 206 233 207 234 $self->{cpane_watermark}->Collapse($b); 208 $self->_layout;235 #$self->_layout; 209 236 $event->Skip; 210 237 } -
extensions/pLoader/trunk/src/Uploader/GUI/wxImageListCtrl.pm
r4632 r4718 83 83 -1, 84 84 wxDefaultPosition, 85 wxDefaultSize, 86 wxNO_BORDER 85 [ 180, -1], 87 86 ); 88 87 … … 197 196 $image->$_ 198 197 ) if defined $image; 198 $self->SetColumnWidth($col, -1); 199 199 $col++; 200 200 } -
extensions/pLoader/trunk/src/Uploader/GUI/wxImagePreview.pm
r4587 r4718 1 1 package Uploader::GUI::wxImagePreview; 2 2 use strict; 3 use base qw/Wx:: PanelClass::Accessor::Fast/;3 use base qw/Wx::Dialog Class::Accessor::Fast/; 4 4 use Wx qw/ 5 5 wxDefaultPosition 6 6 wxDefaultSize 7 7 wxBG_STYLE_CUSTOM 8 8 9 wxIMAGE_QUALITY_HIGH 10 11 wxRESIZE_BORDER 12 13 wxDIALOG_EX_METAL 14 15 wxDIALOG_NO_PARENT 16 wxDEFAULT_DIALOG_STYLE 17 18 wxMAXIMIZE_BOX 19 wxMINIMIZE_BOX 20 21 wxSTAY_ON_TOP 9 22 /; 10 23 … … 25 38 my( $class, $params ) = @_; 26 39 my( $self ) = $class->SUPER::new( 27 $params->{parentwnd},40 undef, 28 41 -1, 42 "Preview", 29 43 wxDefaultPosition, 30 wxDefaultSize, 44 [400,300], 45 wxMAXIMIZE_BOX| 46 wxMINIMIZE_BOX| 47 wxRESIZE_BORDER| 48 wxDEFAULT_DIALOG_STYLE| 49 wxSTAY_ON_TOP| 50 wxDIALOG_NO_PARENT 31 51 ); 32 52 -
extensions/pLoader/trunk/src/Uploader/GUI/wxImageProcessingProgressDlg.pm
r4279 r4718 26 26 wxID_OK 27 27 wxGREEN 28 wxDIALOG_NO_PARENT 29 wxDEFAULT_DIALOG_STYLE 30 31 wxMAXIMIZE_BOX 32 wxMINIMIZE_BOX 33 34 wxSTAY_ON_TOP 28 35 /; 29 36 use base qw/Wx::Dialog Class::Accessor::Fast/; … … 55 62 56 63 57 my $self = $class->SUPER::new( undef, -1, $params->{title}, wxDefaultPosition, wxDefaultSize); 64 my $self = $class->SUPER::new( 65 undef, 66 -1, 67 $params->{title}, 68 wxDefaultPosition, 69 wxDefaultSize, 70 wxDIALOG_NO_PARENT| 71 wxDEFAULT_DIALOG_STYLE| 72 73 wxMAXIMIZE_BOX| 74 wxMINIMIZE_BOX| 75 wxSTAY_ON_TOP 76 77 ); 58 78 # load controls 59 79 eval { -
extensions/pLoader/trunk/src/Uploader/GUI/wxPhotoProperties.pm
r4477 r4718 23 23 wxDefaultSize 24 24 wxDefaultPosition 25 25 wxTAB_TRAVERSAL 26 26 wxID_CANCEL 27 27 wxID_OK … … 32 32 EVT_UPDATE_UI 33 33 EVT_BUTTON 34 34 EVT_CLOSE 35 35 /; 36 36 … … 43 43 44 44 45 # my $self = $class->SUPER::new( $params->{parentwnd}, -1, wxDefaultPosition, [600, 350]); 46 my $self = $class->SUPER::new( $params->{parentwnd}, -1, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); 47 #$self->SetMinSize([600, 350]); 45 my $self = $class->SUPER::new( $params->{parentwnd}, -1, wxDefaultPosition, [-1, -1], wxTAB_TRAVERSAL ); 48 46 # load controls 49 47 eval { … … 54 52 ); 55 53 56 #$self->_init_values;57 54 $self->InitLabels(); 58 55 $self->InitChoices(); -
extensions/pLoader/trunk/src/Uploader/GUI/wxPropertyGridPanel.pm
r4322 r4718 25 25 /; 26 26 use Wx::Locale qw/:default/; 27 use base qw/Wx:: GridUploader::Object2/;27 use base qw/Wx::Dialog Uploader::Object2/; 28 28 29 29 use Wx::Event qw/ … … 36 36 editor 37 37 properties 38 grid 38 39 / 39 40 ); … … 47 48 48 49 49 my $self = $class->SUPER::new( $params->{parentwnd}, -1, wxDefaultPosition, wxDefaultSize ); 50 my $self = $class->SUPER::new( undef, -1, "PropertyGrid", wxDefaultPosition, wxDefaultSize ); 51 $self->grid( 52 Wx::Grid->new($self, -1, wxDefaultPosition, wxDefaultSize) 53 ); 50 54 51 55 $self->renderer( … … 75 79 $self->Initialize; 76 80 77 EVT_GRID_CMD_CELL_CHANGE( $self, $self , \&OnCellChanged );81 EVT_GRID_CMD_CELL_CHANGE( $self, $self->grid, \&OnCellChanged ); 78 82 $self; 79 83 } … … 83 87 84 88 85 $self-> CreateGrid( scalar @{$self->properties}, 2 );89 $self->grid->CreateGrid( scalar @{$self->properties}, 2 ); 86 90 87 91 88 $self-> SetRowLabelSize(0);89 $self-> SetColLabelSize(0);90 $self-> SetColSize( 0, 200 );91 $self-> SetColSize( 1, 200 );92 $self->grid->SetRowLabelSize(0); 93 $self->grid->SetColLabelSize(0); 94 $self->grid->SetColSize( 0, 200 ); 95 $self->grid->SetColSize( 1, 200 ); 92 96 93 97 $self->_init_property_grid(); … … 98 102 my ( $self ) = @_; 99 103 100 $self-> ClearGrid;104 $self->grid->ClearGrid; 101 105 102 106 my $row = 0; … … 104 108 eval { 105 109 106 $self-> SetCellValue(110 $self->grid->SetCellValue( 107 111 $row, 108 112 0, … … 111 115 112 116 113 $self-> SetCellValue(117 $self->grid->SetCellValue( 114 118 $row, 115 119 1, … … 132 136 map { 133 137 eval { 134 $self-> SetCellEditor(138 $self->grid->SetCellEditor( 135 139 $row, 136 140 1, … … 142 146 ) if $self->editor->{$_->{type}}; 143 147 144 $self-> SetCellRenderer(148 $self->grid->SetCellRenderer( 145 149 $row, 146 150 1, … … 152 156 ) if $self->renderer->{$_->{type}}; 153 157 154 $self-> SetReadOnly(158 $self->grid->SetReadOnly( 155 159 $row, 156 160 0, 157 161 ); 158 162 159 $self-> SetCellValue(163 $self->grid->SetCellValue( 160 164 $row, 161 165 0, … … 163 167 ); 164 168 165 $self-> SetCellValue(169 $self->grid->SetCellValue( 166 170 $row, 167 171 1, … … 169 173 ); 170 174 171 $self-> SetReadOnly(175 $self->grid->SetReadOnly( 172 176 $row, 173 177 1, … … 189 193 ); 190 194 191 my $value = $self-> GetCellValue(195 my $value = $self->grid->GetCellValue( 192 196 $row, 193 197 $col, -
extensions/pLoader/trunk/src/ploader.pl
r4632 r4718 27 27 use Class::Accessor::Fast; 28 28 use Uploader::GUI::wxApp; 29 use Uploader::GUI::Frame; 29 30 use JSON; 30 31 use Wx::Locale qw/:default/; … … 39 40 require 'reupload_wdr.pl'; 40 41 require 'photo_properties_wdr.pl'; 42 require 'image_properties_exif_wdr.pl'; 41 43 42 44 eval { … … 47 49 locale_dir => 'locale', 48 50 } 51 ); 52 $app->SetFrame( 53 Uploader::GUI::Frame->new( 54 { 55 title => sprintf("pLoader - Piwigo uploader %s - [%s]", $app->version, $app->site_url), 56 pwg => $app->pwg, 57 imagelist => $app->imagelist, 58 imageviewer_index => $app->imageviewerIndex, 59 frameLayout => $app->frameLayout, 60 } 61 ) 49 62 ); 50 63 $app->MainLoop();
Note: See TracChangeset
for help on using the changeset viewer.