Commit b3150468 authored by Roberto C. Sánchez's avatar Roberto C. Sánchez

[svn-upgrade] Integrating new upstream version, libwx-perl (0.88)

parent 735749bc
Revision history for Perl extension Wx.
0.88 Sun Nov 9 18:03:25 CET 2008
- Skip author tests unless $ENV{AUTHOR_TESTS} is set.
0.87 Fri Nov 7 20:31:09 CET 2008
- Fix segmentation fault when building under Mac in ANSI mode.
0.86 Wed Sep 3 22:57:17 CEST 2008
- Allow binding a method to an event, not just a sub reference.
- Add Wx::SetAlwaysUTF8() to always return character strings from
......
......@@ -4,7 +4,7 @@
// Author: Mattia Barbon
// Modified by:
// Created: 29/10/2000
// RCS-ID: $Id: Constant.xs 2443 2008-08-13 21:08:46Z mbarbon $
// RCS-ID: $Id: Constant.xs 2503 2008-11-06 00:23:45Z mbarbon $
// Copyright: (c) 2000-2008 Mattia Barbon
// Licence: This program is free software; you can redistribute it and/or
// modify it under the same terms as Perl itself
......@@ -529,7 +529,11 @@ static wxPlINH inherit[] =
#endif
I( OwnerDrawnComboBox, ComboCtrl )
I( PlOwnerDrawnComboBox, OwnerDrawnComboBox )
#if WXPERL_W_VERSION_GE( 2, 9, 0 ) && defined( __WXGTK__ )
I( BitmapComboBox, ComboBox )
#else
I( BitmapComboBox, OwnerDrawnComboBox )
#endif
I( GenericCollapsiblePane, Control )
I( CollapsiblePane, GenericCollapsiblePane )
......@@ -584,7 +588,7 @@ static wxPlINH inherit[] =
I( TreeCtrl, GenericTreeCtrl )
#endif
#if defined(__WXGTK__) || \
#if ( defined( __WXGTK__ ) && WXPERL_W_VERSION_LT( 2, 9, 0 ) ) || \
( defined( __WXMAC__ ) && WXPERL_W_VERSION_GE( 2, 5, 1 ) )
I( ComboBox, Control )
#else
......@@ -2749,7 +2753,9 @@ static double constant( const char *name, int arg )
r( wxTE_HT_BELOW ); // textctrl
r( wxTE_HT_BEYOND ); // textctrl
#endif
#if WXPERL_W_VERSION_LT( 2, 9, 0 )
r( wxTE_AUTO_SCROLL ); // textctrl
#endif
#if WXPERL_W_VERSION_GE( 2, 6, 0 )
r( wxTE_CAPITALIZE ); // textctrl
#endif
......
......@@ -4,8 +4,8 @@
// Author: Mattia Barbon
// Modified by:
// Created: 29/10/2000
// RCS-ID: $Id: Event.xs 2274 2007-11-10 22:37:30Z mbarbon $
// Copyright: (c) 2000-2007 Mattia Barbon
// RCS-ID: $Id: Event.xs 2499 2008-11-05 19:47:18Z mbarbon $
// Copyright: (c) 2000-2008 Mattia Barbon
// Licence: This program is free software; you can redistribute it and/or
// modify it under the same terms as Perl itself
/////////////////////////////////////////////////////////////////////////////
......@@ -338,6 +338,23 @@ MODULE=Wx_Evt PACKAGE=Wx::IconizeEvent
bool
wxIconizeEvent::Iconized()
CODE:
#if WXPERL_W_VERSION_LT( 2, 9, 0 )
RETVAL = THIS->Iconized();
#else
RETVAL = THIS->IsIconized();
#endif
OUTPUT: RETVAL
bool
wxIconizeEvent::IsIconized()
CODE:
#if WXPERL_W_VERSION_LT( 2, 9, 0 )
RETVAL = THIS->Iconized();
#else
RETVAL = THIS->IsIconized();
#endif
OUTPUT: RETVAL
MODULE=Wx_Evt PACKAGE=Wx::KeyEvent
......
......@@ -6,7 +6,6 @@ MANIFEST
MANIFEST.SKIP
README.txt
Changes
run
build/Wx/Overload/Driver.pm
build/Wx/Overload/Handle.pm
......
# http://module-build.sourceforge.net/META-spec.html
name: Wx
version: 0.86
version: 0.88
version_from: Wx.pm
installdirs: site
author: Mattia Barbon <mbarbon@cpan.org>
......@@ -12,6 +12,7 @@ build_requires:
Data::Dumper: 0
ExtUtils::MakeMaker: 6.17
File::Spec::Functions: 0.82
if: 0.03
Test::Harness: 2.26
Test::More: 0.45
no_index:
......@@ -28,7 +29,7 @@ configure_requires:
dynamic_config: 1
distribution_type: module
generated_by: ExtUtils::MY_Metafile version 0.09, EUMM-6.44.
generated_by: ExtUtils::MY_Metafile version 0.09, EUMM-6.46.
meta-spec:
version: 1.3
url: http://module-build.sourceforge.net/META-spec-v1.3.html
......@@ -5,7 +5,7 @@
## Author: Mattia Barbon
## Modified by:
## Created: 01/10/2000
## RCS-ID: $Id: Makefile.PL 2331 2008-01-20 10:20:17Z mbarbon $
## RCS-ID: $Id: Makefile.PL 2458 2008-09-03 21:03:04Z mbarbon $
## Copyright: (c) 2000-2008 Mattia Barbon
## Licence: This program is free software; you can redistribute it and/or
## modify it under the same terms as Perl itself
......@@ -39,6 +39,7 @@ my $build_requires =
'Data::Dumper' => 0,
'ExtUtils::MakeMaker' => 6.17,
'Alien::wxWidgets' => 0.25,
'if' => 0.03,
};
eval {
......
......@@ -4,7 +4,7 @@
// Author: Mattia Barbon
// Modified by:
// Created: 29/10/2000
// RCS-ID: $Id: Window.xs 2391 2008-05-14 20:40:24Z mbarbon $
// RCS-ID: $Id: Window.xs 2480 2008-09-17 16:59:02Z mbarbon $
// Copyright: (c) 2000-2002, 2004-2008 Mattia Barbon
// Licence: This program is free software; you can redistribute it and/or
// modify it under the same terms as Perl itself
......@@ -255,7 +255,7 @@ wxWindow::ConvertPixelsSizeToDialog( size )
bool
wxWindow::Destroy()
#if defined( __MSW__ ) \
#if defined( __WXMSW__ ) \
|| ( WXPERL_W_VERSION_GE( 2, 9, 0 ) && !defined( __WXGTK__ ) )
void
......
......@@ -4,7 +4,7 @@
## Author: Mattia Barbon
## Modified by:
## Created: 01/10/2000
## RCS-ID: $Id: Wx.pm 2448 2008-08-24 21:57:04Z mbarbon $
## RCS-ID: $Id: Wx.pm 2497 2008-11-05 19:35:30Z mbarbon $
## Copyright: (c) 2000-2008 Mattia Barbon
## Licence: This program is free software; you can redistribute it and/or
## modify it under the same terms as Perl itself
......@@ -21,7 +21,7 @@ use vars qw(@ISA $VERSION $XS_VERSION $AUTOLOAD @EXPORT_OK %EXPORT_TAGS
$_msw = 1; $_gtk = 2; $_motif = 3; $_mac = 4; $_x11 = 5;
@ISA = qw(Exporter);
$VERSION = '0.86';
$VERSION = '0.88';
$XS_VERSION = $VERSION;
$VERSION = eval $VERSION;
......@@ -182,7 +182,7 @@ eval( "sub wxMAC() { $_platform == $_mac }" );
eval( "sub wxX11() { $_platform == $_x11 }" );
# Mac OS X warning
if( wxMAC() && $^X !~ m{/wxPerl\.app/} ) {
if( wxMAC() && $^X !~ m{/wxPerl\.app/} && !$ENV{HARNESS_ACTIVE} ) {
warn "On Mac OS X please run scripts with the 'wxPerl' interpreter\n";
}
......
......@@ -4,7 +4,7 @@
// Author: Mattia Barbon
// Modified by:
// Created: 01/10/2000
// RCS-ID: $Id: Wx.xs 2457 2008-08-31 15:49:17Z mbarbon $
// RCS-ID: $Id: Wx.xs 2466 2008-09-08 20:12:04Z mbarbon $
// Copyright: (c) 2000-2002, 2004-2008 Mattia Barbon
// Licence: This program is free software; you can redistribute it and/or
// modify it under the same terms as Perl itself
......@@ -274,12 +274,10 @@ Load()
if( wxPerlAppCreated || wxTopLevelWindows.GetCount() > 0 )
return;
// not on first column to avoid tripping up xsubpp
#if defined(DEBUGGING) && !defined(PERL_USE_SAFE_PUTENV)
#if defined(DEBUGGING) && !defined(PERL_USE_SAFE_PUTENV)
// avoid crash on exit in Fedora (and other DEBUGGING Perls)
PL_use_safe_putenv = 1;
#endif
#endif
int argc = 0;
#if wxUSE_UNICODE && WXPERL_W_VERSION_GE( 2, 5, 3 )
......
......@@ -4,8 +4,8 @@
## Author: Matthew "Cheetah" Gabeler-Lee
## Modified by:
## Created: 10/01/2005
## RCS-ID: $Id: ArtProvider.xsp 2285 2007-11-11 21:31:54Z mbarbon $
## Copyright: (c) 2005-2007 Matthew Gabeler-Lee
## RCS-ID: $Id: ArtProvider.xsp 2499 2008-11-05 19:47:18Z mbarbon $
## Copyright: (c) 2005-2008 Matthew Gabeler-Lee
## Licence: This program is free software; you can redistribute it and/or
## modify it under the same terms as Perl itself
#############################################################################
......@@ -155,7 +155,11 @@ void
InsertProvider( provider )
wxArtProvider* provider
CODE:
#if WXPERL_W_VERSION_GE( 2, 9, 0 )
wxArtProvider::PushBack( provider);
#else
wxArtProvider::Insert( provider);
#endif
#endif
......
......@@ -4,8 +4,8 @@
## Author: Mattia Barbon
## Modified by:
## Created: 25/03/2003
## RCS-ID: $Id: IconBundle.xsp 2293 2007-11-25 00:33:03Z mbarbon $
## Copyright: (c) 2003, 2005, 2007 Mattia Barbon
## RCS-ID: $Id: IconBundle.xsp 2503 2008-11-06 00:23:45Z mbarbon $
## Copyright: (c) 2003, 2005, 2007-2008 Mattia Barbon
## Licence: This program is free software; you can redistribute it and/or
## modify it under the same terms as Perl itself
#############################################################################
......@@ -16,15 +16,17 @@
#include <wx/iconbndl.h>
#include "cpp/overload.h"
%typemap{wxBitmapType}{simple};
%name{Wx::IconBundle} class wxIconBundle
{
%name{newEmpty} wxIconBundle();
%name{newFile} wxIconBundle( const wxString& file,
long type = wxBITMAP_TYPE_ANY );
wxBitmapType type = wxBITMAP_TYPE_ANY );
%name{newIcon} wxIconBundle( const wxIcon& icon );
%name{AddIconFile} void AddIcon( const wxString& filr,
long type = wxBITMAP_TYPE_ANY );
wxBitmapType type = wxBITMAP_TYPE_ANY );
%name{AddIconIcon} void AddIcon( const wxIcon& icon );
%name{GetIconSize} const wxIcon& GetIcon( const wxSize& size );
......
......@@ -4,8 +4,8 @@
## Author: Mattia Barbon
## Modified by:
## Created: 02/12/2000
## RCS-ID: $Id: Image.xs 2243 2007-10-14 21:35:20Z mbarbon $
## Copyright: (c) 2000-2003, 2005-2007 Mattia Barbon
## RCS-ID: $Id: Image.xs 2503 2008-11-06 00:23:45Z mbarbon $
## Copyright: (c) 2000-2003, 2005-2008 Mattia Barbon
## Licence: This program is free software; you can redistribute it and/or
## modify it under the same terms as Perl itself
#############################################################################
......@@ -107,7 +107,7 @@ wxImage*
newNameType( CLASS, name, type, index = -1 )
SV* CLASS
wxString name
long type
wxBitmapType type
int index
CODE:
RETVAL = new wxImage( name, type, index );
......@@ -129,7 +129,7 @@ wxImage*
newStreamType( CLASS, stream, type, index = -1 )
SV* CLASS
wxPliInputStream stream
long type
wxBitmapType type
int index
CODE:
RETVAL = new wxImage( stream, type, index );
......@@ -245,7 +245,7 @@ FindHandlerName( name )
wxImageHandler*
FindHandlerExtType( extension, type )
wxString extension
long type
wxBitmapType type
CODE:
RETVAL = wxImage::FindHandler( extension, type );
OUTPUT:
......@@ -253,7 +253,7 @@ FindHandlerExtType( extension, type )
wxImageHandler*
FindHandlerType( type )
long type
wxBitmapType type
CODE:
RETVAL = wxImage::FindHandler( type );
OUTPUT:
......@@ -413,7 +413,7 @@ wxImage::LoadFile( ... )
bool
wxImage::LoadFileType( name, type, index = -1 )
wxString name
long type
wxBitmapType type
int index
CODE:
RETVAL = THIS->LoadFile( name, type, index );
......@@ -433,7 +433,7 @@ wxImage::LoadFileMIME( name, type, index = -1 )
bool
wxImage::LoadStreamType( stream, type, index = -1 )
wxPliInputStream stream
long type
wxBitmapType type
int index
CODE:
RETVAL = THIS->LoadFile( stream, type, index );
......@@ -482,7 +482,7 @@ wxImage::SaveFileOnly( name )
bool
wxImage::SaveFileType( name, type )
wxString name
long type
wxBitmapType type
CODE:
RETVAL = THIS->SaveFile( name, type );
OUTPUT:
......@@ -500,7 +500,7 @@ wxImage::SaveFileMIME( name, type )
bool
wxImage::SaveStreamType( stream, type )
wxPliOutputStream stream
long type
wxBitmapType type
CODE:
RETVAL = THIS->SaveFile( stream, type );
OUTPUT:
......@@ -787,9 +787,18 @@ wxImageHandler::GetName()
wxString
wxImageHandler::GetExtension()
#if WXPERL_W_VERSION_GE( 2, 9, 0 )
wxBitmapType
wxImageHandler::GetType()
#else
long
wxImageHandler::GetType()
#endif
wxString
wxImageHandler::GetMimeType()
......@@ -819,7 +828,7 @@ wxImageHandler::SetMimeType( type )
void
wxImageHandler::SetType( type )
long type
wxBitmapType type
MODULE=Wx PACKAGE=Wx::GIFHandler
......
......@@ -4,8 +4,8 @@
## Author: Mattia Barbon
## Modified by:
## Created: 14/08/2007
## RCS-ID: $Id: ItemContainer.xsp 2163 2007-08-15 22:46:51Z mbarbon $
## Copyright: (c) 2007 Mattia Barbon
## RCS-ID: $Id: ItemContainer.xsp 2504 2008-11-06 00:25:57Z mbarbon $
## Copyright: (c) 2007-2008 Mattia Barbon
## Licence: This program is free software; you can redistribute it and/or
## modify it under the same terms as Perl itself
#############################################################################
......@@ -20,6 +20,8 @@ void
wxItemContainer::Append( ... )
PPCODE:
BEGIN_OVERLOAD()
MATCH_REDISP( wxPliOvl_arr_arr, AppendItemsData )
MATCH_REDISP( wxPliOvl_arr, AppendItems )
MATCH_REDISP( wxPliOvl_s_s, AppendData )
MATCH_REDISP( wxPliOvl_s, AppendString )
END_OVERLOAD( Wx::ItemContainer::Append )
......@@ -28,16 +30,20 @@ wxItemContainer::Append( ... )
%name{AppendString} void Append( const wxString& item );
%name{AppendData} void Append( const wxString& item,
wxPliUserDataCD* data );
## Append( [items] );
## Append( [items], [data] );
## Append( n, [items] );
## Append( n, [items], [data] );
%name{AppendItems} void Append( const wxArrayString& items );
#if WXPERL_W_VERSION_GE( 2, 9, 0 )
%name{AppendItemsData} void Append( const wxArrayString& items,
wxPliUserDataCD** data )
%code%{ THIS->Append( items, (wxClientData**)data ); %};
#endif
%{
void
wxItemContainer::Insert( ... )
PPCODE:
BEGIN_OVERLOAD()
MATCH_REDISP( wxPliOvl_arr_n_arr, InsertItemsData )
MATCH_REDISP( wxPliOvl_arr_n, InsertItems )
MATCH_REDISP( wxPliOvl_s_n_s, InsertData )
MATCH_REDISP( wxPliOvl_s_n, InsertString )
END_OVERLOAD( Wx::ItemContainer::Insert )
......@@ -46,15 +52,33 @@ wxItemContainer::Insert( ... )
%name{InsertString} void Insert( const wxString& item, unsigned int pos );
%name{InsertData} void Insert( const wxString& item, unsigned int pos,
wxPliUserDataCD* data );
## Insert( [items], pos );
## Insert( [items], pos, [data] );
## Insert( n, [items], pos );
## Insert( n, [items], pos, [data] );
#if WXPERL_W_VERSION_GE( 2, 9, 0 )
%name{InsertItems} void Insert( const wxArrayString& items,
unsigned int pos );
%name{InsertItemsData} void Insert( const wxArrayString& items,
unsigned int pos,
wxPliUserDataCD** data )
%code%{ THIS->Insert( items, pos, (wxClientData**)data ); %};
#endif
#if WXPERL_W_VERSION_GE( 2, 9, 0 )
%{
void
wxItemContainer::Set( ... )
PPCODE:
BEGIN_OVERLOAD()
MATCH_REDISP( wxPliOvl_arr_arr, SetItemsData )
MATCH_REDISP( wxPliOvl_arr, SetItems )
END_OVERLOAD( Wx::ItemContainer::Set )
%}
%name{SetItems} void Set( const wxArrayString& items );
%name{SetItemsData} void Set( const wxArrayString& items,
wxPliUserDataCD** data )
%code%{ THIS->Set( items, (wxClientData**)data ); %};
## Set( n, [items] );
## Set( n, [items], [data] );
## Set( n, [items] );
## Set( n, [items], [data] );
#endif
void Clear();
void Delete( int n );
......
......@@ -4,8 +4,8 @@
## Author: Mattia Barbon
## Modified by:
## Created: 08/11/2000
## RCS-ID: $Id: ListBox.xs 2153 2007-08-15 17:37:39Z mbarbon $
## Copyright: (c) 2000-2003, 2006-2007 Mattia Barbon
## RCS-ID: $Id: ListBox.xs 2504 2008-11-06 00:25:57Z mbarbon $
## Copyright: (c) 2000-2003, 2006-2008 Mattia Barbon
## Licence: This program is free software; you can redistribute it and/or
## modify it under the same terms as Perl itself
#############################################################################
......@@ -108,18 +108,14 @@ int
wxListBox::HitTest( point )
wxPoint point
#if WXPERL_W_VERSION_LT( 2, 9, 0 )
void
wxListBox::InsertItems( items, pos )
SV* items
wxArrayString items
int pos
PREINIT:
wxString* its;
int n;
CODE:
n = wxPli_av_2_stringarray( aTHX_ items, &its );
THIS->InsertItems( n, its, pos );
delete[] its;
#endif
bool
wxListBox::IsSelected( n )
......@@ -145,6 +141,10 @@ wxListBox::SetFirstItemString( str )
CODE:
THIS->SetFirstItem( str );
#if WXPERL_W_VERSION_LT( 2, 9, 0 )
void
wxListBox::Set( choices )
wxArrayString choices
#endif
......@@ -4,8 +4,8 @@
## Author: Mattia Barbon
## Modified by:
## Created: 29/10/2000
## RCS-ID: $Id: ToolBar.xs 2293 2007-11-25 00:33:03Z mbarbon $
## Copyright: (c) 2000-2007 Mattia Barbon
## RCS-ID: $Id: ToolBar.xs 2503 2008-11-06 00:23:45Z mbarbon $
## Copyright: (c) 2000-2008 Mattia Barbon
## Licence: This program is free software; you can redistribute it and/or
## modify it under the same terms as Perl itself
#############################################################################
......@@ -201,7 +201,12 @@ wxToolBarBase::AddToolShort( toolId, bitmap1, shortHelp = wxEmptyString, longHel
wxString shortHelp
wxString longHelp
CODE:
#if WXPERL_W_VERSION_GE( 2, 9, 0 )
RETVAL = THIS->AddTool( toolId, wxEmptyString, *bitmap1, wxNullBitmap,
wxITEM_NORMAL, shortHelp, longHelp );
#else
RETVAL = THIS->AddTool( toolId, *bitmap1, shortHelp, longHelp );
#endif
OUTPUT:
RETVAL
......@@ -215,10 +220,18 @@ wxToolBarBase::AddToolLong( toolId, bitmap1, bitmap2 = (wxBitmap*)&wxNullBitmap,
wxString shortHelp
wxString longHelp
CODE:
#if WXPERL_W_VERSION_GE( 2, 9, 0 )
RETVAL = THIS->AddTool( toolId, wxEmptyString, *bitmap1, *bitmap2,
isToggle ? wxITEM_CHECK : wxITEM_NORMAL,
shortHelp, longHelp );
if( clientData )
RETVAL->SetClientData( clientData );
#else
RETVAL = THIS->AddTool( toolId, *bitmap1, *bitmap2, isToggle,
0, shortHelp, longHelp );
if( clientData )
RETVAL->SetClientData( clientData );
#endif
OUTPUT:
RETVAL
......@@ -389,10 +402,18 @@ wxToolBarBase::InsertToolLong( pos, toolId, bitmap1, bitmap2 = (wxBitmap*)&wxNul
wxString shortHelp
wxString longHelp
CODE:
#if WXPERL_W_VERSION_GE( 2, 9, 0 )
RETVAL = THIS->InsertTool( pos, toolId, wxEmptyString, *bitmap1, *bitmap2,
isToggle ? wxITEM_CHECK : wxITEM_NORMAL,
shortHelp, longHelp );
if( clientData )
THIS->SetClientData( clientData );
#else
RETVAL = THIS->InsertTool( pos, toolId, *bitmap1, *bitmap2, isToggle,
0, shortHelp, longHelp );
if( clientData )
THIS->SetClientData( clientData );
#endif
OUTPUT: RETVAL
#if WXPERL_W_VERSION_GE( 2, 5, 3 )
......
......@@ -4,8 +4,8 @@
## Author: Mattia Barbon
## Modified by:
## Created: 17/08/2001
## RCS-ID: $Id: Driver.pm 2256 2007-10-26 21:54:28Z mbarbon $
## Copyright: (c) 2001-2003, 2005-2007 Mattia Barbon
## RCS-ID: $Id: Driver.pm 2500 2008-11-05 22:17:53Z mbarbon $
## Copyright: (c) 2001-2003, 2005-2008 Mattia Barbon
## Licence: This program is free software; you can redistribute it and/or
## modify it under the same terms as Perl itself
#############################################################################
......@@ -189,12 +189,12 @@ EOT
foreach my $i ( sort keys %constants ) {
my $count = scalar @{$constants{$i}};
print $out "const unsigned char wxPliOvl_${i}_arr\[\] = { ";
print $out "const unsigned char wxPliOvl_${i}_datadef\[\] = { ";
print $out join ", ", map { "wxPliOvl$_" } @{$constants{$i}};
print $out " };\n";
print $out <<EOT;
const wxPliPrototype wxPliOvl_${i}
( wxPliOvl\_tnames, wxPliOvl_${i}_arr, $count );
( wxPliOvl\_tnames, wxPliOvl_${i}_datadef, $count );
EOT
}
......
This diff is collapsed.
......@@ -445,7 +445,7 @@ sub print_noconst {
return join( '',
$this->base_type,
( $this->is_pointer ? '*' :
( $this->is_pointer ? ( '*' x $this->is_pointer ) :
$this->is_reference ? '&' : '' ) );
}
......@@ -455,7 +455,7 @@ sub print {
return join( '',
( $this->is_const ? 'const ' : '' ),
$this->base_type,
( $this->is_pointer ? '*' :
( $this->is_pointer ? ( '*' x $this->is_pointer ) :
$this->is_reference ? '&' : '' ) );
}
......
......@@ -156,10 +156,9 @@ perc_file: p_file OPCURLY file_name CLCURLY { $_[3] };
perc_code: p_code special_block { [ code => $_[2] ] };
perc_cleanup: p_cleanup special_block { [ cleanup => $_[2] ] };
type: 'const' type_name STAR { make_cptr( $_[0], $_[2] ) }
| 'const' type_name AMP { make_cref( $_[0], $_[2] ) }
| type_name STAR { make_ptr( $_[0], $_[1] ) }
| type_name AMP { make_ref( $_[0], $_[1] ) }
type: 'const' type { make_const( $_[0], $_[2] ) }
| type STAR { make_ptr( $_[0], $_[1] ) }
| type AMP { make_ref( $_[0], $_[1] ) }
| type_name { make_type( $_[0], $_[1] ) };
type_name: class_name | basic_type | 'unsigned' basic_type;
......@@ -352,13 +351,10 @@ sub yyerror {
")\n";
}
sub make_cptr { Wx::XSP::Node::Type->new( base => $_[1],
const => 1, pointer => 1 ) }
sub make_cref { Wx::XSP::Node::Type->new( base => $_[1],
const => 1, reference => 1 ) }
sub make_ref { Wx::XSP::Node::Type->new( base => $_[1], reference => 1 ) }
sub make_ptr { Wx::XSP::Node::Type->new( base => $_[1], pointer => 1 ) }
sub make_type { Wx::XSP::Node::Type->new( base => $_[1] ) }
sub make_const { $_[1]->{CONST} = 1; $_[1] }
sub make_ref { $_[1]->{REFERENCE} = 1; $_[1] }
sub make_ptr { $_[1]->{POINTER}++; $_[1] }
sub make_type { Wx::XSP::Node::Type->new( base => $_[1] ) }
sub add_data_raw {
my $p = shift;
......
......@@ -4,8 +4,8 @@
// Author: Mattia Barbon
// Modified by:
// Created: 29/10/2000
// RCS-ID: $Id: compat.h 2057 2007-06-18 23:03:00Z mbarbon $
// Copyright: (c) 2000-2003, 2006 Mattia Barbon
// RCS-ID: $Id: compat.h 2498 2008-11-05 19:45:38Z mbarbon $
// Copyright: (c) 2000-2003, 2006, 2008 Mattia Barbon
// Licence: This program is free software; you can redistribute it and/or
// modify it under the same terms as Perl itself
/////////////////////////////////////////////////////////////////////////////
......@@ -131,7 +131,9 @@
#endif
#define WXPLDLL
#if defined( WXPL_EXT ) && !defined( WXPL_STATIC ) && !defined(__WXMAC__)
#define NEEDS_PLI_HELPERS_STRUCT() \
defined( WXPL_EXT ) && !defined( WXPL_STATIC ) && !defined(__WXMAC__)
#if NEEDS_PLI_HELPERS_STRUCT()
# define FUNCPTR( name ) ( * name )
#else
# define FUNCPTR( name ) name
......
......@@ -4,8 +4,8 @@
// Author: Mattia Barbon
// Modified by:
// Created: 17/03/2001
// RCS-ID: $Id: constants.h 2057 2007-06-18 23:03:00Z mbarbon $
// Copyright: (c) 2001-2002, 2005 Mattia Barbon
// RCS-ID: $Id: constants.h 2498 2008-11-05 19:45:38Z mbarbon $
// Copyright: (c) 2001-2002, 2005, 2008 Mattia Barbon
// Licence: This program is free software; you can redistribute it and/or
// modify it under the same terms as Perl itself
/////////////////////////////////////////////////////////////////////////////
......@@ -45,7 +45,7 @@ extern void FUNCPTR( wxPli_remove_constant_function )
inline wxPlConstants::wxPlConstants( PL_CONST_FUNC function )
:m_function( function )
{
#if defined( WXPL_EXT ) && !defined( WXPL_STATIC ) && !defined(__WXMAC__)
#if NEEDS_PLI_HELPERS_STRUCT()
dTHX;
// GRR! init helpers...
SV* wxpli_tmp = get_sv( "Wx::_exports", 1 );
......
......@@ -4,7 +4,7 @@
// Author: Mattia Barbon
// Modified by:
// Created: 29/10/2000
// RCS-ID: $Id: helpers.h 2457 2008-08-31 15:49:17Z mbarbon $
// RCS-ID: $Id: helpers.h 2498 2008-11-05 19:45:38Z mbarbon $
// Copyright: (c) 2000-2008 Mattia Barbon
// Licence: This program is free software; you can redistribute it and/or
// modify it under the same terms as Perl itself
......@@ -117,7 +117,7 @@ inline SV* wxPli_wxString_2_sv( pTHX_ const wxString& str, SV* out )
#else
#ifdef WXPL_EXT
#if NEEDS_PLI_HELPERS_STRUCT()
bool* wxPli_always_utf8;
#else
extern bool wxPli_always_utf8;
......@@ -125,7 +125,7 @@ extern bool wxPli_always_utf8;
inline SV* wxPli_wxChar_2_sv( pTHX_ const wxChar* str, SV* out )
{
#ifdef WXPL_EXT
#if NEEDS_PLI_HELPERS_STRUCT()
if( *wxPli_always_utf8 )
#else
if( wxPli_always_utf8 )
......@@ -144,7 +144,7 @@ inline SV* wxPli_wxChar_2_sv( pTHX_ const wxChar* str, SV* out )
inline SV* wxPli_wxString_2_sv( pTHX_ const wxString& str, SV* out )
{
#ifdef WXPL_EXT
#if NEEDS_PLI_HELPERS_STRUCT()
if( *wxPli_always_utf8 )
#else
if( wxPli_always_utf8 )
......@@ -566,7 +566,7 @@ wxPliHelpers name = { &wxPli_sv_2_object, \
&wxPli_objlist_push, &wxPliOutputStream_ctor, &wxPli_stringarray_push \
}
#if defined( WXPL_EXT ) && !defined( WXPL_STATIC ) && !defined(__WXMAC__)
#if NEEDS_PLI_HELPERS_STRUCT()
#define INIT_PLI_HELPERS( name ) \
SV* wxpli_tmp = get_sv( "Wx::_exports", 1 ); \
......
......@@ -4,14 +4,16 @@
## Author: Mattia Barbon
## Modified by:
## Created: 08/12/2001
## RCS-ID: $Id: GridEvent.xs 2057 2007-06-18 23:03:00Z mbarbon $
## Copyright: (c) 2001-2004 Mattia Barbon
## RCS-ID: $Id: GridEvent.xs 2503 2008-11-06 00:23:45Z mbarbon $
## Copyright: (c) 2001-2004, 2008 Mattia Barbon
## Licence: This program is free software; you can redistribute it and/or
## modify it under the same terms as Perl itself
#############################################################################
MODULE=Wx PACKAGE=Wx::GridEvent
#if 0
wxGridEvent*
wxGridEvent::new( id, type, obj, row = -1, col = -1, x = -1, y = -1, sel = true, control = true, shift = true, alt = true, meta = true )
int id
......@@ -27,6 +29,8 @@ wxGridEvent::new( id, type, obj, row = -1, col = -1, x = -1, y = -1, sel = true,
bool alt
bool meta
#endif
int
wxGridEvent::GetRow()
......@@ -57,6 +61,8 @@ wxGridEvent::ShiftDown()
MODULE=Wx PACKAGE=Wx::GridSizeEvent
#if 0
wxGridSizeEvent*
wxGridSizeEvent::new( id, type, obj, rowOrCol = -1, x = -1, y = -1, control = true, shift = true, alt = true, meta = true )
int id
......@@ -70,6 +76,8 @@ wxGridSizeEvent::new( id, type, obj, rowOrCol = -1, x = -1, y = -1, control = tr
bool alt
bool meta
#endif
int
wxGridSizeEvent::GetRowOrCol()
......@@ -94,6 +102,8 @@ wxGridSizeEvent::ShiftDown()
MODULE=Wx PACKAGE=Wx::GridRangeSelectEvent
#if 0
wxGridRangeSelectEvent*
wxGridRangeSelectEvent::new( id, type, obj, topLeft, bottomRight, sel = true, control = false, shift = false, alt = false, meta = false )
int id
......@@ -112,6 +122,8 @@ wxGridRangeSelectEvent::new( id, type, obj, topLeft, bottomRight, sel = true, co
OUTPUT:
RETVAL
#endif
wxGridCellCoords*
wxGridRangeSelectEvent::GetTopLeftCoords()
CODE:
......
......@@ -4,8 +4,8 @@
## Author: Mattia Barbon
## Modified by:
## Created: 29/10/2000
## RCS-ID: $Id: Event.pm 2213 2007-08-25 23:15:15Z mbarbon $
## Copyright: (c) 2000-2007 Mattia Barbon
## RCS-ID: $Id: Event.pm 2462 2008-09-07 10:50:08Z mbarbon $
## Copyright: (c) 2000-2008 Mattia Barbon