Deprecated wxSizer::Remove( wxWindow* ), s/Remove/Detach/ in most places.

Made wxSizer child list typesafe.  I've not added the wxList implicit
conversion kludge yet, let's see who complains first perhaps..

Deprecated wxSizer::{G,S}etOption in favour of {G,S}etProportion in line
with the parameter name change in the docs.

Added {G,S}etSpacer consistent with the accessors for windows/sizers.

Made all wxSizer index parameters size_t -- we support no sensible
interpretation for negative indexes in them.  Hopefully this will
cause no real problems, but code doing (eg. Remove( 0 )) will need
to change to use 0u to resolve the ambiguity with overloaded members.
This is probably a Good Thing though, ymmv.

s/FALSE/false/g ; s/TRUE/true/g ; s/wxASSERT/wxASSERT_MSG/g in sizer.{cpp,h}

Fixed (I hope) the brokenness in wxSizer::Show -- I have no code to test
this yet, so it's a blind change, but spacers should now be hidden correctly
instead of ignored, and it should be properly reversable over multiple
calls now too.

removed pointless private scoping around DECLARE_CLASS macros.

Replace 0's I added previously with NULL -- not like that will end the
email thread either..

Added Add( wxSizerItem * ) & co.  There are probably a couple of other
places we can usefully do something like this too.  Stopped short of
refactoring everything to raise some issues about sizer method recursion
on -dev.

Updated wxSizer docs some more, they are still incomplete but getting
better.

wrapped KeyCode in wxDEPRECATED, converted all (gtk build) instances
to GetKeyCode.  There may be a few left for other ports.

Fixed a couple of other random compile warnings along the way.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@18616 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Ron Lee
2003-01-07 10:22:07 +00:00
parent db50ec5a50
commit 12a3f2275c
37 changed files with 569 additions and 381 deletions

View File

@@ -923,7 +923,7 @@ void wxGridCellNumberEditor::StartingKey(wxKeyEvent& event)
{
if ( !HasRange() )
{
int keycode = (int) event.KeyCode();
int keycode = event.GetKeyCode();
if ( isdigit(keycode) || keycode == '+' || keycode == '-'
|| keycode == WXK_NUMPAD0
|| keycode == WXK_NUMPAD1
@@ -1063,7 +1063,7 @@ void wxGridCellFloatEditor::Reset()
void wxGridCellFloatEditor::StartingKey(wxKeyEvent& event)
{
int keycode = (int)event.KeyCode();
int keycode = event.GetKeyCode();
if ( isdigit(keycode) || keycode == '+' || keycode == '-' || keycode == '.'
|| keycode == WXK_NUMPAD0
|| keycode == WXK_NUMPAD1
@@ -1495,7 +1495,7 @@ wxString wxGridCellChoiceEditor::GetValue() const
void wxGridCellEditorEvtHandler::OnKeyDown(wxKeyEvent& event)
{
switch ( event.KeyCode() )
switch ( event.GetKeyCode() )
{
case WXK_ESCAPE:
m_editor->Reset();
@@ -1520,7 +1520,7 @@ void wxGridCellEditorEvtHandler::OnKeyDown(wxKeyEvent& event)
void wxGridCellEditorEvtHandler::OnChar(wxKeyEvent& event)
{
switch ( event.KeyCode() )
switch ( event.GetKeyCode() )
{
case WXK_ESCAPE:
case WXK_TAB:
@@ -6082,7 +6082,7 @@ void wxGrid::OnKeyDown( wxKeyEvent& event )
// try local handlers
//
switch ( event.KeyCode() )
switch ( event.GetKeyCode() )
{
case WXK_UP:
if ( event.ControlDown() )
@@ -6247,7 +6247,7 @@ void wxGrid::OnKeyDown( wxKeyEvent& event )
// <F2> is special and will always start editing, for
// other keys - ask the editor itself
if ( (event.KeyCode() == WXK_F2 && !event.HasModifiers())
if ( (event.GetKeyCode() == WXK_F2 && !event.HasModifiers())
|| editor->IsAcceptedKey(event) )
{
// ensure cell is visble
@@ -6285,7 +6285,7 @@ void wxGrid::OnKeyUp( wxKeyEvent& event )
{
// try local handlers
//
if ( event.KeyCode() == WXK_SHIFT )
if ( event.GetKeyCode() == WXK_SHIFT )
{
if ( m_selectingTopLeft != wxGridNoCellCoords &&
m_selectingBottomRight != wxGridNoCellCoords )