#include "wx/dcclient.h"
#endif //WX_PRECOMP
+#if defined(__WXMAC__) && wxUSE_SCROLLBAR
+ #include "wx/scrolbar.h"
+#endif
+
#if wxUSE_CONSTRAINTS
#include "wx/layout.h"
#endif // wxUSE_CONSTRAINTS
EVT_MIDDLE_DOWN(wxWindowBase::OnMiddleClick)
#if wxUSE_HELP
- EVT_HELP(-1, wxWindowBase::OnHelp)
+ EVT_HELP(wxID_ANY, wxWindowBase::OnHelp)
#endif // wxUSE_HELP
END_EVENT_TABLE()
// ----------------------------------------------------------------------------
// the default initialization
-void wxWindowBase::InitBase()
+wxWindowBase::wxWindowBase()
{
// no window yet, no parent nor children
m_parent = (wxWindow *)NULL;
- m_windowId = -1;
+ m_windowId = wxID_ANY;
// no constraints on the minimal window size
m_minWidth =
m_maxWidth =
m_maxHeight = -1;
- // window is created enabled but it's not visible yet
- m_isShown = FALSE;
- m_isEnabled = TRUE;
+ // window are created enabled and visible by default
+ m_isShown =
+ m_isEnabled = true;
// the default event handler is just this window
m_eventHandler = this;
m_windowValidator = (wxValidator *) NULL;
#endif // wxUSE_VALIDATORS
- // use the system default colours
- m_backgroundColour = wxSystemSettings::GetColour(wxSYS_COLOUR_BTNFACE);
- m_foregroundColour = wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOWTEXT);
-
- // don't set the font here for wxMSW as we don't call WM_SETFONT here and
- // so the font is *not* really set - but calls to SetFont() later won't do
- // anything because m_font appears to be already set!
-#ifndef __WXMSW__
- m_font = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
-#endif // __WXMSW__
-
- // the colours/fonts are default for now
+ // the colours/fonts are default for now, so leave m_font,
+ // m_backgroundColour and m_foregroundColour uninitialized and set those
m_hasBgCol =
m_hasFgCol =
- m_hasFont = FALSE;
-
- m_isBeingDeleted = FALSE;
+ m_hasFont = false;
// no style bits
m_exStyle =
m_windowSizer = (wxSizer *) NULL;
m_containingSizer = (wxSizer *) NULL;
- m_autoLayout = FALSE;
+ m_autoLayout = false;
#if wxUSE_DRAG_AND_DROP
m_dropTarget = (wxDropTarget *)NULL;
#endif // wxUSE_CARET
#if wxUSE_PALETTE
- m_hasCustomPalette = FALSE;
+ m_hasCustomPalette = false;
#endif // wxUSE_PALETTE
#if wxUSE_ACCESSIBILITY
m_maxVirtualWidth =
m_maxVirtualHeight = -1;
+ m_windowVariant = wxWINDOW_VARIANT_NORMAL;
+
// Whether we're using the current theme for this window (wxGTK only for now)
- m_themeEnabled = FALSE;
+ m_themeEnabled = false;
+
+ // VZ: this one shouldn't exist...
+ m_isBeingDeleted = false;
}
// common part of window creation process
const wxPoint& WXUNUSED(pos),
const wxSize& WXUNUSED(size),
long style,
- const wxValidator& validator,
+ const wxValidator& wxVALIDATOR_PARAM(validator),
const wxString& name)
{
#if wxUSE_STATBOX
SetExtraStyle(GetExtraStyle() | wxWS_EX_VALIDATE_RECURSIVELY);
}
- return TRUE;
+ return true;
}
// ----------------------------------------------------------------------------
{
delete this;
- return TRUE;
+ return true;
}
bool wxWindowBase::Close(bool force)
event.SetEventObject(this);
event.SetCanVeto(!force);
- // return FALSE if window wasn't closed because the application vetoed the
+ // return false if window wasn't closed because the application vetoed the
// close event
return GetEventHandler()->ProcessEvent(event) && !event.GetVeto();
}
wxWindow *child = node->GetData();
- child->Destroy();
+ // note that we really want to call delete and not ->Destroy() here
+ // because we want to delete the child immediately, before we are
+ // deleted, and delayed deletion would result in problems as our (top
+ // level) child could outlive its parent
+ delete child;
wxASSERT_MSG( !GetChildren().Find(child),
wxT("child didn't remove itself using RemoveChild()") );
}
- return TRUE;
+ return true;
}
// ----------------------------------------------------------------------------
}
}
+// On Mac, scrollbars are explicitly children.
+#ifdef __WXMAC__
+static bool wxHasRealChildren(const wxWindowBase* win)
+{
+ int realChildCount = 0;
+
+ for ( wxWindowList::compatibility_iterator node = win->GetChildren().GetFirst();
+ node;
+ node = node->GetNext() )
+ {
+ wxWindow *win = node->GetData();
+ if ( !win->IsTopLevel() && win->IsShown() && !win->IsKindOf(CLASSINFO(wxScrollBar)))
+ realChildCount ++;
+ }
+ return (realChildCount > 0);
+}
+#endif
+
// return the size best suited for the current window
wxSize wxWindowBase::DoGetBestSize() const
{
return wxSize(maxX, maxY);
}
#endif // wxUSE_CONSTRAINTS
- else if ( GetChildren().GetCount() > 0 )
+ else if ( !GetChildren().empty()
+#ifdef __WXMAC__
+ && wxHasRealChildren(this)
+#endif
+ )
{
- // our minimal acceptable size is such that all our windows fit inside
+ // our minimal acceptable size is such that all our visible child windows fit inside
int maxX = 0,
maxY = 0;
node = node->GetNext() )
{
wxWindow *win = node->GetData();
- if ( win->IsTopLevel()
+ if ( win->IsTopLevel() || ( ! win->IsShown() )
#if wxUSE_STATUSBAR
|| wxDynamicCast(win, wxStatusBar)
#endif // wxUSE_STATUSBAR
return wxSize(maxX, maxY);
}
- else
+ else // ! has children
{
- // for a generic window there is no natural best size - just use the
- // current one
- return GetSize();
+ // for a generic window there is no natural best size - just use either the
+ // minimum size if there is one, or the current size
+ if ( GetMinSize().IsFullySpecified() )
+ return GetMinSize();
+ else
+ return GetSize();
}
}
+void wxWindowBase::SetBestSize(const wxSize& size)
+{
+ // the size only needs to be changed if the current size is incomplete,
+ // i.e. one of the components was specified as default -- so if both
+ // were given, simply don't do anything and in particular don't call
+ // potentially expensive DoGetBestSize()
+ wxSize sizeBest;
+ if ( size.x == -1 || size.y == -1 )
+ {
+ sizeBest = DoGetBestSize();
+ if ( size.x != -1 )
+ sizeBest.x = size.x;
+ if ( size.y != -1 )
+ sizeBest.y = size.y;
+
+ SetSize(sizeBest);
+ }
+ else // have explicit size
+ {
+ sizeBest = size;
+ }
+
+ // don't shrink the control below its best size
+ m_minWidth = sizeBest.x;
+ m_minHeight = sizeBest.y;
+}
+
// by default the origin is not shifted
wxPoint wxWindowBase::GetClientAreaOrigin() const
{
m_maxHeight = maxH;
}
+void wxWindowBase::SetWindowVariant( wxWindowVariant variant )
+{
+ if ( m_windowVariant != variant )
+ {
+ m_windowVariant = variant;
+
+ DoSetWindowVariant(variant);
+ }
+}
+
+void wxWindowBase::DoSetWindowVariant( wxWindowVariant variant )
+{
+ // adjust the font height to correspond to our new variant (notice that
+ // we're only called if something really changed)
+ wxFont font = GetFont();
+ int size = font.GetPointSize();
+ switch ( variant )
+ {
+ case wxWINDOW_VARIANT_NORMAL:
+ break;
+
+ case wxWINDOW_VARIANT_SMALL:
+ size *= 3;
+ size /= 4;
+ break;
+
+ case wxWINDOW_VARIANT_MINI:
+ size *= 2;
+ size /= 3;
+ break;
+
+ case wxWINDOW_VARIANT_LARGE:
+ size *= 5;
+ size /= 4;
+ break;
+
+ default:
+ wxFAIL_MSG(_T("unexpected window variant"));
+ break;
+ }
+
+ font.SetPointSize(size);
+ SetFont(font);
+}
+
void wxWindowBase::SetVirtualSizeHints( int minW, int minH,
int maxW, int maxH )
{
{
m_isShown = show;
- return TRUE;
+ return true;
}
else
{
- return FALSE;
+ return false;
}
}
{
m_isEnabled = enable;
- return TRUE;
+ return true;
}
else
{
- return FALSE;
+ return false;
}
}
// ----------------------------------------------------------------------------
bool wxWindowBase::IsTopLevel() const
{
- return FALSE;
+ return false;
}
// ----------------------------------------------------------------------------
if ( newParent == oldParent )
{
// nothing done
- return FALSE;
+ return false;
}
// unlink this window from the existing parent.
wxTopLevelWindows.Append((wxWindow *)this);
}
- return TRUE;
+ return true;
}
// ----------------------------------------------------------------------------
bool wxWindowBase::RemoveEventHandler(wxEvtHandler *handler)
{
- wxCHECK_MSG( handler, FALSE, _T("RemoveEventHandler(NULL) called") );
+ wxCHECK_MSG( handler, false, _T("RemoveEventHandler(NULL) called") );
wxEvtHandler *handlerPrev = NULL,
*handlerCur = GetEventHandler();
{
handlerNext->SetPreviousHandler ( handlerPrev );
}
+
handler->SetNextHandler(NULL);
+ handler->SetPreviousHandler(NULL);
- return TRUE;
+ return true;
}
handlerPrev = handlerCur;
wxFAIL_MSG( _T("where has the event handler gone?") );
- return FALSE;
+ return false;
}
// ----------------------------------------------------------------------------
-// cursors, fonts &c
+// colours, fonts &c
// ----------------------------------------------------------------------------
+void wxWindowBase::InheritAttributes()
+{
+ const wxWindowBase * const parent = GetParent();
+ if ( !parent )
+ return;
+
+ // we only inherit attributes which had been explicitly set for the parent
+ // which ensures that this only happens if the user really wants it and
+ // not by default which wouldn't make any sense in modern GUIs where the
+ // controls don't all use the same fonts (nor colours)
+ if ( parent->m_hasFont && !m_hasFont )
+ SetFont(parent->GetFont());
+
+ // in addition, there is a possibility to explicitly forbid inheriting
+ // colours at each class level by overriding ShouldInheritColours()
+ if ( ShouldInheritColours() )
+ {
+ if ( parent->m_hasFgCol && !m_hasFgCol )
+ SetForegroundColour(parent->GetForegroundColour());
+
+ if ( parent->m_hasBgCol && !m_hasBgCol )
+ SetBackgroundColour(parent->GetBackgroundColour());
+ }
+}
+
+/* static */ wxVisualAttributes
+wxWindowBase::GetClassDefaultAttributes(wxWindowVariant WXUNUSED(variant))
+{
+ // it is important to return valid values for all attributes from here,
+ // GetXXX() below rely on this
+ wxVisualAttributes attrs;
+ attrs.font = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
+ attrs.colFg = wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOWTEXT);
+ attrs.colBg = wxSystemSettings::GetColour(wxSYS_COLOUR_BTNFACE);
+
+ return attrs;
+}
+
+wxColour wxWindowBase::GetBackgroundColour() const
+{
+ if ( !m_backgroundColour.Ok() )
+ {
+ wxASSERT_MSG( !m_hasBgCol, _T("we have invalid explicit bg colour?") );
+
+ // get our default background colour
+ wxColour colBg = GetDefaultAttributes().colBg;
+
+ // we must return some valid colour to avoid redoing this every time
+ // and also to avoid surprizing the applications written for older
+ // wxWindows versions where GetBackgroundColour() always returned
+ // something -- so give them something even if it doesn't make sense
+ // for this window (e.g. it has a themed background)
+ if ( !colBg.Ok() )
+ colBg = GetClassDefaultAttributes().colBg;
+
+ // cache it for the next call
+ wxConstCast(this, wxWindowBase)->m_backgroundColour = colBg;
+ }
+
+ return m_backgroundColour;
+}
+
+wxColour wxWindowBase::GetForegroundColour() const
+{
+ // logic is the same as above
+ if ( !m_hasFgCol && !m_foregroundColour.Ok() )
+ {
+ wxASSERT_MSG( !m_hasFgCol, _T("we have invalid explicit fg colour?") );
+
+ wxColour colFg = GetDefaultAttributes().colFg;
+
+ if ( !colFg.Ok() )
+ colFg = GetClassDefaultAttributes().colFg;
+
+ wxConstCast(this, wxWindowBase)->m_foregroundColour = colFg;
+ }
+
+ return m_foregroundColour;
+}
+
bool wxWindowBase::SetBackgroundColour( const wxColour &colour )
{
if ( !colour.Ok() || (colour == m_backgroundColour) )
- return FALSE;
+ return false;
m_backgroundColour = colour;
- m_hasBgCol = TRUE;
+ m_hasBgCol = true;
- return TRUE;
+ return true;
}
bool wxWindowBase::SetForegroundColour( const wxColour &colour )
{
if ( !colour.Ok() || (colour == m_foregroundColour) )
- return FALSE;
+ return false;
m_foregroundColour = colour;
- m_hasFgCol = TRUE;
+ m_hasFgCol = true;
- return TRUE;
+ return true;
}
bool wxWindowBase::SetCursor(const wxCursor& cursor)
if ( m_cursor == cursor )
{
// no change
- return FALSE;
+ return false;
}
m_cursor = cursor;
- return TRUE;
+ return true;
+}
+
+wxFont& wxWindowBase::DoGetFont() const
+{
+ // logic is the same as in GetBackgroundColour()
+ if ( !m_font.Ok() )
+ {
+ wxASSERT_MSG( !m_hasFont, _T("we have invalid explicit font?") );
+
+ wxFont font = GetDefaultAttributes().font;
+ if ( !font.Ok() )
+ font = GetClassDefaultAttributes().font;
+
+ wxConstCast(this, wxWindowBase)->m_font = font;
+ }
+
+ // cast is here for non-const GetFont() convenience
+ return wxConstCast(this, wxWindowBase)->m_font;
}
bool wxWindowBase::SetFont(const wxFont& font)
{
- // don't try to set invalid font, always fall back to the default
- const wxFont& fontOk = font.Ok() ? font : *wxSWISS_FONT;
+ if ( !font.Ok() )
+ return false;
- if ( fontOk == m_font )
+ if ( font == m_font )
{
// no change
- return FALSE;
+ return false;
}
- m_font = fontOk;
+ m_font = font;
- m_hasFont = TRUE;
+ m_hasFont = true;
- return TRUE;
+ return true;
}
#if wxUSE_PALETTE
void wxWindowBase::SetPalette(const wxPalette& pal)
{
- m_hasCustomPalette = TRUE;
+ m_hasCustomPalette = true;
m_palette = pal;
// VZ: can anyone explain me what do we do here?
m_windowValidator = (wxValidator *)validator.Clone();
if ( m_windowValidator )
- m_windowValidator->SetWindow(this) ;
+ m_windowValidator->SetWindow(this);
}
#endif // wxUSE_VALIDATORS
wxValidator *validator = child->GetValidator();
if ( validator && !validator->Validate((wxWindow *)this) )
{
- return FALSE;
+ return false;
}
if ( recurse && !child->Validate() )
{
- return FALSE;
+ return false;
}
}
#endif // wxUSE_VALIDATORS
- return TRUE;
+ return true;
}
bool wxWindowBase::TransferDataToWindow()
wxLog::FlushActive();
#endif // wxUSE_LOG
- return FALSE;
+ return false;
}
if ( recurse )
if ( !child->TransferDataToWindow() )
{
// warning already given
- return FALSE;
+ return false;
}
}
}
#endif // wxUSE_VALIDATORS
- return TRUE;
+ return true;
}
bool wxWindowBase::TransferDataFromWindow()
// nop warning here because the application is supposed to give
// one itself - we don't know here what might have gone wrongly
- return FALSE;
+ return false;
}
if ( recurse )
if ( !child->TransferDataFromWindow() )
{
// warning already given
- return FALSE;
+ return false;
}
}
}
#endif // wxUSE_VALIDATORS
- return TRUE;
+ return true;
}
void wxWindowBase::InitDialog()
void wxWindowBase::SetSizer(wxSizer *sizer, bool deleteOld)
{
+ if ( sizer == m_windowSizer)
+ return;
+
if ( deleteOld )
delete m_windowSizer;
sizer->SetSizeHints( (wxWindow*) this );
}
+
+void wxWindowBase::SetContainingSizer(wxSizer* sizer)
+{
+ // adding a window to a sizer twice is going to result in fatal and
+ // hard to debug problems later because when deleting the second
+ // associated wxSizerItem we're going to dereference a dangling
+ // pointer; so try to detect this as early as possible
+ wxASSERT_MSG( !sizer || m_containingSizer != sizer,
+ _T("Adding a window to the same sizer twice?") );
+
+ m_containingSizer = sizer;
+}
+
#if wxUSE_CONSTRAINTS
void wxWindowBase::SatisfyConstraints()
}
#endif
- return TRUE;
+ return true;
}
#if wxUSE_CONSTRAINTS
// Layout grand children
DoPhase(2);
- return TRUE;
+ return true;
}
// Do a phase of evaluating child constraints
}
}
- return TRUE;
+ return true;
}
void wxWindowBase::ResetConstraints()
wxLayoutConstraints *constr = GetConstraints();
if ( constr )
{
- constr->left.SetDone(FALSE);
- constr->top.SetDone(FALSE);
- constr->right.SetDone(FALSE);
- constr->bottom.SetDone(FALSE);
- constr->width.SetDone(FALSE);
- constr->height.SetDone(FALSE);
- constr->centreX.SetDone(FALSE);
- constr->centreY.SetDone(FALSE);
+ constr->left.SetDone(false);
+ constr->top.SetDone(false);
+ constr->right.SetDone(false);
+ constr->bottom.SetDone(false);
+ constr->width.SetDone(false);
+ constr->height.SetDone(false);
+ constr->centreX.SetDone(false);
+ constr->centreY.SetDone(false);
}
wxWindowList::compatibility_iterator node = GetChildren().GetFirst();
if ( x != -1 )
{
constr->left.SetValue(x);
- constr->left.SetDone(TRUE);
+ constr->left.SetDone(true);
}
if ( y != -1 )
{
constr->top.SetValue(y);
- constr->top.SetDone(TRUE);
+ constr->top.SetDone(true);
}
if ( w != -1 )
{
constr->width.SetValue(w);
- constr->width.SetDone(TRUE);
+ constr->width.SetDone(true);
}
if ( h != -1 )
{
constr->height.SetValue(h);
- constr->height.SetDone(TRUE);
+ constr->height.SetDone(true);
}
}
}
if ( x != -1 )
{
constr->left.SetValue(x);
- constr->left.SetDone(TRUE);
+ constr->left.SetDone(true);
}
if ( y != -1 )
{
constr->top.SetValue(y);
- constr->top.SetDone(TRUE);
+ constr->top.SetDone(true);
}
}
}
{
if ( event.GetSetEnabled() )
Enable(event.GetEnabled());
-
+
#if wxUSE_CONTROLS
if ( event.GetSetText() )
{
radiobtn->SetValue(event.GetChecked());
}
#endif // wxUSE_RADIOBTN
- }
+ }
#endif
}
int charHeight = GetCharHeight();
wxPoint pt2(-1, -1);
if (pt.x != -1)
- pt2.x = (int) ((pt.x * 4) / charWidth) ;
+ pt2.x = (int) ((pt.x * 4) / charWidth);
if (pt.y != -1)
- pt2.y = (int) ((pt.y * 8) / charHeight) ;
+ pt2.y = (int) ((pt.y * 8) / charHeight);
return pt2;
}
int charHeight = GetCharHeight();
wxPoint pt2(-1, -1);
if (pt.x != -1)
- pt2.x = (int) ((pt.x * charWidth) / 4) ;
+ pt2.x = (int) ((pt.x * charWidth) / 4);
if (pt.y != -1)
- pt2.y = (int) ((pt.y * charHeight) / 8) ;
+ pt2.y = (int) ((pt.y * charHeight) / 8);
return pt2;
}
void wxWindowBase::OnInitDialog( wxInitDialogEvent &WXUNUSED(event) )
{
TransferDataToWindow();
-
+
// Update the UI at this point
UpdateWindowUI(wxUPDATE_UI_RECURSE);
}
//else: stack is empty, no previous capture
wxLogTrace(_T("mousecapture"),
- _T("After ReleaseMouse() mouse is captured by %p"),
- GetCapture());
+ (const wxChar *) _T("After ReleaseMouse() mouse is captured by %p"),
+ GetCapture());
}
#if wxUSE_HOTKEY
// event processing
// ----------------------------------------------------------------------------
-bool wxWindowBase::TryValidator(wxEvent& event)
+bool wxWindowBase::TryValidator(wxEvent& wxVALIDATOR_PARAM(event))
{
#if wxUSE_VALIDATORS
// Can only use the validator of the window which
// Can return either a child object, or an integer
// representing the child element, starting from 1.
-wxAccStatus wxWindowAccessible::HitTest(const wxPoint& pt, int* childId, wxAccessible** childObject)
+wxAccStatus wxWindowAccessible::HitTest(const wxPoint& WXUNUSED(pt), int* WXUNUSED(childId), wxAccessible** WXUNUSED(childObject))
{
wxASSERT( GetWindow() != NULL );
if (!GetWindow())
// Navigates from fromId to toId/toObject.
wxAccStatus wxWindowAccessible::Navigate(wxNavDir navDir, int fromId,
- int* toId, wxAccessible** toObject)
+ int* WXUNUSED(toId), wxAccessible** toObject)
{
wxASSERT( GetWindow() != NULL );
if (!GetWindow())
title = ((wxButton*) GetWindow())->GetLabel();
else
title = GetWindow()->GetName();
-
+
if (!title.IsEmpty())
{
*name = title;
// or > 0 (the action for a child).
// Return wxACC_NOT_SUPPORTED if there is no default action for this
// window (e.g. an edit control).
-wxAccStatus wxWindowAccessible::DoDefaultAction(int childId)
+wxAccStatus wxWindowAccessible::DoDefaultAction(int WXUNUSED(childId))
{
wxASSERT( GetWindow() != NULL );
if (!GetWindow())
// The retrieved string describes the action that is performed on an object,
// not what the object does as a result. For example, a toolbar button that prints
// a document has a default action of "Press" rather than "Prints the current document."
-wxAccStatus wxWindowAccessible::GetDefaultAction(int childId, wxString* actionName)
+wxAccStatus wxWindowAccessible::GetDefaultAction(int WXUNUSED(childId), wxString* WXUNUSED(actionName))
{
wxASSERT( GetWindow() != NULL );
if (!GetWindow())
}
// Returns the description for this object or a child.
-wxAccStatus wxWindowAccessible::GetDescription(int childId, wxString* description)
+wxAccStatus wxWindowAccessible::GetDescription(int WXUNUSED(childId), wxString* description)
{
wxASSERT( GetWindow() != NULL );
if (!GetWindow())
}
// Returns help text for this object or a child, similar to tooltip text.
-wxAccStatus wxWindowAccessible::GetHelpText(int childId, wxString* helpText)
+wxAccStatus wxWindowAccessible::GetHelpText(int WXUNUSED(childId), wxString* helpText)
{
wxASSERT( GetWindow() != NULL );
if (!GetWindow())
// Returns the keyboard shortcut for this object or child.
// Return e.g. ALT+K
-wxAccStatus wxWindowAccessible::GetKeyboardShortcut(int childId, wxString* shortcut)
+wxAccStatus wxWindowAccessible::GetKeyboardShortcut(int WXUNUSED(childId), wxString* WXUNUSED(shortcut))
{
wxASSERT( GetWindow() != NULL );
if (!GetWindow())
*role = wxROLE_SYSTEM_CLIENT;
return wxACC_OK;
+ #if 0
return wxACC_NOT_IMPLEMENTED;
+ #endif
}
// Returns a state constant.
*state = 0;
return wxACC_OK;
+ #if 0
return wxACC_NOT_IMPLEMENTED;
+ #endif
}
// Returns a localized string representing the value for the object
// or child.
-wxAccStatus wxWindowAccessible::GetValue(int childId, wxString* strValue)
+wxAccStatus wxWindowAccessible::GetValue(int WXUNUSED(childId), wxString* WXUNUSED(strValue))
{
wxASSERT( GetWindow() != NULL );
if (!GetWindow())
}
// Selects the object or child.
-wxAccStatus wxWindowAccessible::Select(int childId, wxAccSelectionFlags selectFlags)
+wxAccStatus wxWindowAccessible::Select(int WXUNUSED(childId), wxAccSelectionFlags WXUNUSED(selectFlags))
{
wxASSERT( GetWindow() != NULL );
if (!GetWindow())
// If childId is 0 and child is NULL, no object in
// this subhierarchy has the focus.
// If this object has the focus, child should be 'this'.
-wxAccStatus wxWindowAccessible::GetFocus(int* childId, wxAccessible** child)
+wxAccStatus wxWindowAccessible::GetFocus(int* WXUNUSED(childId), wxAccessible** WXUNUSED(child))
{
wxASSERT( GetWindow() != NULL );
if (!GetWindow())
// - an integer representing the selected child element,
// or 0 if this object is selected (GetType() == wxT("long")
// - a "void*" pointer to a wxAccessible child object
-wxAccStatus wxWindowAccessible::GetSelections(wxVariant* selections)
+wxAccStatus wxWindowAccessible::GetSelections(wxVariant* WXUNUSED(selections))
{
wxASSERT( GetWindow() != NULL );
if (!GetWindow())