fixing warnings in osx cocoa
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@59778 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -23,13 +23,13 @@
|
||||
#include "wx/osx/private.h"
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateBitmapButton( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxBitmap& bitmap,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSButton* v = [[wxNSButton alloc] initWithFrame:r];
|
||||
|
@@ -166,13 +166,13 @@ wxSize wxButton::GetDefaultSize()
|
||||
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateButton( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID id,
|
||||
const wxString& label,
|
||||
const wxString& WXUNUSED(label),
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(style),
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSButton* v = [[wxNSButton alloc] initWithFrame:r];
|
||||
@@ -253,13 +253,13 @@ void wxWidgetCocoaImpl::PerformClick()
|
||||
}
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateDisclosureTriangle( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxString& label,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(style),
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSButton* v = [[wxNSButton alloc] initWithFrame:r];
|
||||
|
@@ -17,13 +17,13 @@
|
||||
#include "wx/osx/private.h"
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateCheckBox( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
const wxString& label,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxString& WXUNUSED(label),
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSButton* v = [[wxNSButton alloc] initWithFrame:r];
|
||||
|
@@ -53,13 +53,13 @@
|
||||
@end
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateChoice( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
wxMenu* menu,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStylew)
|
||||
long WXUNUSED(style),
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSPopUpButton* v = [[wxNSPopUpButton alloc] initWithFrame:r pullsDown:NO];
|
||||
|
@@ -37,8 +37,8 @@
|
||||
IMPLEMENT_CLASS(wxDirDialog, wxDialog)
|
||||
|
||||
wxDirDialog::wxDirDialog(wxWindow *parent, const wxString& message,
|
||||
const wxString& defaultPath, long style, const wxPoint& pos,
|
||||
const wxSize& size, const wxString& name)
|
||||
const wxString& defaultPath, long style, const wxPoint& WXUNUSED(pos),
|
||||
const wxSize& WXUNUSED(size), const wxString& WXUNUSED(name))
|
||||
{
|
||||
m_parent = parent;
|
||||
|
||||
|
@@ -78,15 +78,15 @@ protected:
|
||||
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateGauge( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
wxInt32 value,
|
||||
wxInt32 minimum,
|
||||
wxInt32 maximum,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(style),
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSProgressIndicator* v = [[wxNSProgressIndicator alloc] initWithFrame:r];
|
||||
|
@@ -239,6 +239,7 @@ protected:
|
||||
|
||||
- (NSInteger)numberOfRowsInTableView:(NSTableView *)aTableView
|
||||
{
|
||||
wxUnusedVar(aTableView);
|
||||
if ( impl )
|
||||
return impl->ListGetCount();
|
||||
return 0;
|
||||
@@ -248,6 +249,7 @@ protected:
|
||||
objectValueForTableColumn:(NSTableColumn *)aTableColumn
|
||||
row:(NSInteger)rowIndex
|
||||
{
|
||||
wxUnusedVar(aTableView);
|
||||
wxNSTableColumn* tablecol = (wxNSTableColumn *)aTableColumn;
|
||||
wxListBox* lb = dynamic_cast<wxListBox*>(impl->GetWXPeer());
|
||||
wxCocoaTableColumn* col = [tablecol column];
|
||||
@@ -261,6 +263,7 @@ protected:
|
||||
setObjectValue:(id)value forTableColumn:(NSTableColumn *)aTableColumn
|
||||
row:(NSInteger)rowIndex
|
||||
{
|
||||
wxUnusedVar(aTableView);
|
||||
wxNSTableColumn* tablecol = (wxNSTableColumn *)aTableColumn;
|
||||
wxListBox* lb = dynamic_cast<wxListBox*>(impl->GetWXPeer());
|
||||
wxCocoaTableColumn* col = [tablecol column];
|
||||
@@ -309,8 +312,8 @@ unsigned int wxListWidgetCocoaImpl::ListGetCount() const
|
||||
// columns
|
||||
//
|
||||
|
||||
wxListWidgetColumn* wxListWidgetCocoaImpl::InsertTextColumn( unsigned pos, const wxString& title, bool editable,
|
||||
wxAlignment just, int defaultWidth)
|
||||
wxListWidgetColumn* wxListWidgetCocoaImpl::InsertTextColumn( unsigned pos, const wxString& WXUNUSED(title), bool editable,
|
||||
wxAlignment WXUNUSED(just), int defaultWidth)
|
||||
{
|
||||
wxNSTableColumn* col1 = [[wxNSTableColumn alloc] init];
|
||||
[col1 setEditable:editable];
|
||||
@@ -345,8 +348,8 @@ wxListWidgetColumn* wxListWidgetCocoaImpl::InsertTextColumn( unsigned pos, const
|
||||
return wxcol;
|
||||
}
|
||||
|
||||
wxListWidgetColumn* wxListWidgetCocoaImpl::InsertCheckColumn( unsigned pos , const wxString& title, bool editable,
|
||||
wxAlignment just, int defaultWidth )
|
||||
wxListWidgetColumn* wxListWidgetCocoaImpl::InsertCheckColumn( unsigned pos , const wxString& WXUNUSED(title), bool editable,
|
||||
wxAlignment WXUNUSED(just), int defaultWidth )
|
||||
{
|
||||
wxNSTableColumn* col1 = [[wxNSTableColumn alloc] init];
|
||||
[col1 setEditable:editable];
|
||||
@@ -386,31 +389,12 @@ wxListWidgetColumn* wxListWidgetCocoaImpl::InsertCheckColumn( unsigned pos , con
|
||||
// inserting / removing lines
|
||||
//
|
||||
|
||||
void wxListWidgetCocoaImpl::ListInsert( unsigned int n )
|
||||
void wxListWidgetCocoaImpl::ListInsert( unsigned int WXUNUSED(n) )
|
||||
{
|
||||
#if 0
|
||||
{
|
||||
wxListBoxCocoaLine* line = new wxListBoxCocoaLine();
|
||||
line->SetLabel(items[i]);
|
||||
if ( m_items.size() <= n+i )
|
||||
m_items.push_back( line );
|
||||
else
|
||||
m_items.insert(m_items.begin()+n, line);
|
||||
/*
|
||||
NSMutableDictionary* line = [[NSMutableDictionary alloc] init];
|
||||
[line setObject:wxCFStringRef(items[i]).AsNSString() forKey:column1];
|
||||
NSMutableArray* array = [m_dataSource items];
|
||||
if ( [array count] <= n+i )
|
||||
[array addObject:line];
|
||||
else
|
||||
[array insertObject:line atIndex:n];
|
||||
*/
|
||||
}
|
||||
#endif
|
||||
[m_tableView reloadData];
|
||||
}
|
||||
|
||||
void wxListWidgetCocoaImpl::ListDelete( unsigned int n )
|
||||
void wxListWidgetCocoaImpl::ListDelete( unsigned int WXUNUSED(n) )
|
||||
{
|
||||
[m_tableView reloadData];
|
||||
}
|
||||
@@ -470,19 +454,19 @@ void wxListWidgetCocoaImpl::ListScrollTo( unsigned int n )
|
||||
}
|
||||
|
||||
|
||||
void wxListWidgetCocoaImpl::UpdateLine( unsigned int n, wxListWidgetColumn* col )
|
||||
void wxListWidgetCocoaImpl::UpdateLine( unsigned int WXUNUSED(n), wxListWidgetColumn* WXUNUSED(col) )
|
||||
{
|
||||
// TODO optimize
|
||||
[m_tableView reloadData];
|
||||
}
|
||||
|
||||
void wxListWidgetCocoaImpl::UpdateLineToEnd( unsigned int n)
|
||||
void wxListWidgetCocoaImpl::UpdateLineToEnd( unsigned int WXUNUSED(n))
|
||||
{
|
||||
// TODO optimize
|
||||
[m_tableView reloadData];
|
||||
}
|
||||
|
||||
void wxListWidgetCocoaImpl::controlAction(WXWidget slf,void* _cmd, void *sender)
|
||||
void wxListWidgetCocoaImpl::controlAction(WXWidget WXUNUSED(slf),void* WXUNUSED(_cmd), void *WXUNUSED(sender))
|
||||
{
|
||||
wxListBox *list = static_cast<wxListBox*> ( GetWXPeer());
|
||||
wxCHECK_RET( list != NULL , wxT("Listbox expected"));
|
||||
@@ -496,7 +480,7 @@ void wxListWidgetCocoaImpl::controlAction(WXWidget slf,void* _cmd, void *sender)
|
||||
list->HandleLineEvent( sel, false );
|
||||
}
|
||||
|
||||
void wxListWidgetCocoaImpl::controlDoubleAction(WXWidget slf,void* _cmd, void *sender)
|
||||
void wxListWidgetCocoaImpl::controlDoubleAction(WXWidget WXUNUSED(slf),void* WXUNUSED(_cmd), void *WXUNUSED(sender))
|
||||
{
|
||||
wxListBox *list = static_cast<wxListBox*> ( GetWXPeer());
|
||||
wxCHECK_RET( list != NULL , wxT("Listbox expected"));
|
||||
@@ -512,12 +496,12 @@ void wxListWidgetCocoaImpl::controlDoubleAction(WXWidget slf,void* _cmd, void *s
|
||||
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateListBox( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
NSScrollView* scrollview = [[NSScrollView alloc] initWithFrame:r];
|
||||
@@ -561,7 +545,7 @@ wxWidgetImplType* wxWidgetImpl::CreateListBox( wxWindowMac* wxpeer,
|
||||
return c;
|
||||
}
|
||||
|
||||
int wxListBox::DoListHitTest(const wxPoint& inpoint) const
|
||||
int wxListBox::DoListHitTest(const wxPoint& WXUNUSED(inpoint)) const
|
||||
{
|
||||
#if wxOSX_USE_CARBON
|
||||
OSStatus err;
|
||||
|
@@ -156,7 +156,7 @@ public :
|
||||
[NSApp setAppleMenu:[[m_osxMenu itemAtIndex:0] submenu]];
|
||||
}
|
||||
|
||||
virtual void Enable( bool enable )
|
||||
virtual void Enable( bool WXUNUSED(enable) )
|
||||
{
|
||||
}
|
||||
|
||||
|
@@ -32,6 +32,7 @@
|
||||
|
||||
- (void) clickedAction: (id) sender
|
||||
{
|
||||
wxUnusedVar(sender);
|
||||
if ( impl )
|
||||
{
|
||||
impl->GetWXPeer()->GetMenu()->HandleCommandProcess(impl->GetWXPeer());
|
||||
@@ -40,6 +41,7 @@
|
||||
|
||||
- (BOOL)validateMenuItem:(NSMenuItem *) menuItem
|
||||
{
|
||||
wxUnusedVar(menuItem);
|
||||
if( impl )
|
||||
{
|
||||
impl->GetWXPeer()->GetMenu()->HandleCommandUpdateStatus(impl->GetWXPeer());
|
||||
@@ -225,10 +227,10 @@ wxMenuItemCocoaImpl::~wxMenuItemCocoaImpl()
|
||||
|
||||
|
||||
wxMenuItemImpl* wxMenuItemImpl::Create( wxMenuItem* peer, wxMenu *pParentMenu,
|
||||
int id,
|
||||
int WXUNUSED(id),
|
||||
const wxString& text,
|
||||
wxAcceleratorEntry *entry,
|
||||
const wxString& strHelp,
|
||||
const wxString& WXUNUSED(strHelp),
|
||||
wxItemKind kind,
|
||||
wxMenu *pSubMenu )
|
||||
{
|
||||
|
@@ -55,6 +55,7 @@
|
||||
|
||||
- (BOOL)tabView:(NSTabView *)tabView shouldSelectTabViewItem:(NSTabViewItem *)tabViewItem
|
||||
{
|
||||
wxUnusedVar(tabViewItem);
|
||||
wxNSTabView* view = (wxNSTabView*) tabView;
|
||||
wxWidgetCocoaImpl* viewimpl = (wxWidgetCocoaImpl* ) wxWidgetImpl::FindFromWXWidget( view );
|
||||
|
||||
@@ -68,6 +69,7 @@
|
||||
- (void)tabView:(NSTabView *)tabView didSelectTabViewItem:(NSTabViewItem *)tabViewItem;
|
||||
|
||||
{
|
||||
wxUnusedVar(tabViewItem);
|
||||
wxNSTabView* view = (wxNSTabView*) tabView;
|
||||
wxWidgetCocoaImpl* viewimpl = (wxWidgetCocoaImpl* ) wxWidgetImpl::FindFromWXWidget( view );
|
||||
if ( viewimpl )
|
||||
@@ -225,12 +227,12 @@ public:
|
||||
#endif
|
||||
*/
|
||||
wxWidgetImplType* wxWidgetImpl::CreateTabView( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
static wxTabViewController* controller = NULL;
|
||||
|
||||
|
@@ -17,13 +17,13 @@
|
||||
#include "wx/osx/private.h"
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateRadioButton( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
const wxString& label,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxString& WXUNUSED(label),
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(style),
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSButton* v = [[wxNSButton alloc] initWithFrame:r];
|
||||
|
@@ -87,7 +87,7 @@ protected:
|
||||
// to thumbtrack and only after super mouseDown
|
||||
// returns we will call the thumbrelease
|
||||
|
||||
void wxOSXScrollBarCocoaImpl::controlAction( WXWidget slf, void *_cmd, void *sender)
|
||||
void wxOSXScrollBarCocoaImpl::controlAction( WXWidget WXUNUSED(slf), void *WXUNUSED(_cmd), void *WXUNUSED(sender))
|
||||
{
|
||||
wxEventType scrollEvent = wxEVT_NULL;
|
||||
switch ([(NSScroller*)m_osxView hitPart])
|
||||
@@ -136,12 +136,12 @@ void wxOSXScrollBarCocoaImpl::mouseEvent(WX_NSEvent event, WXWidget slf, void *_
|
||||
}
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateScrollBar( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(style),
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSScroller* v = [[wxNSScroller alloc] initWithFrame:r];
|
||||
|
@@ -57,7 +57,7 @@ public :
|
||||
// to thumbtrack and only after super mouseDown
|
||||
// returns we will call the thumbrelease
|
||||
|
||||
void wxSliderCocoaImpl::controlAction( WXWidget slf, void *_cmd, void *sender)
|
||||
void wxSliderCocoaImpl::controlAction( WXWidget WXUNUSED(slf), void *WXUNUSED(_cmd), void *WXUNUSED(sender))
|
||||
{
|
||||
wxWindow* wxpeer = (wxWindow*) GetWXPeer();
|
||||
if ( wxpeer )
|
||||
@@ -79,15 +79,15 @@ void wxSliderCocoaImpl::mouseEvent(WX_NSEvent event, WXWidget slf, void *_cmd)
|
||||
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateSlider( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
wxInt32 value,
|
||||
wxInt32 minimum,
|
||||
wxInt32 maximum,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSSlider* v = [[wxNSSlider alloc] initWithFrame:r];
|
||||
|
@@ -66,7 +66,7 @@ void wxSpinButtonCocoaImpl::mouseEvent(WX_NSEvent event, WXWidget slf, void *_cm
|
||||
wxWidgetCocoaImpl::mouseEvent(event, slf, _cmd);
|
||||
}
|
||||
|
||||
void wxSpinButtonCocoaImpl::controlAction( WXWidget slf, void *_cmd, void *sender)
|
||||
void wxSpinButtonCocoaImpl::controlAction( WXWidget WXUNUSED(slf), void *WXUNUSED(_cmd), void *WXUNUSED(sender))
|
||||
{
|
||||
wxWindow* wxpeer = (wxWindow*) GetWXPeer();
|
||||
if ( wxpeer )
|
||||
@@ -94,15 +94,15 @@ void wxSpinButtonCocoaImpl::controlAction( WXWidget slf, void *_cmd, void *sende
|
||||
}
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateSpinButton( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
wxInt32 value,
|
||||
wxInt32 minimum,
|
||||
wxInt32 maximum,
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSStepper* v = [[wxNSStepper alloc] initWithFrame:r];
|
||||
|
@@ -31,13 +31,13 @@
|
||||
@end
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateGroupBox( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
const wxString& label,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxString& WXUNUSED(label),
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(style),
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSBox* v = [[wxNSBox alloc] initWithFrame:r];
|
||||
|
@@ -34,12 +34,12 @@
|
||||
#include "wx/osx/private.h"
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateStaticLine( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(style),
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSBox* v = [[wxNSBox alloc] initWithFrame:r];
|
||||
|
@@ -60,7 +60,7 @@ public:
|
||||
wxNSStaticTextView* v = (wxNSStaticTextView*)GetWXWidget();
|
||||
wxWindow* wxpeer = GetWXPeer();
|
||||
NSCell* cell = [v cell];
|
||||
wxCFStringRef text( title , wxpeer->GetFont().GetEncoding() );
|
||||
wxCFStringRef text( title , encoding );
|
||||
|
||||
NSMutableParagraphStyle *paragraphStyle = [[NSMutableParagraphStyle alloc] init];
|
||||
[paragraphStyle setLineBreakMode:m_lineBreak];
|
||||
@@ -86,13 +86,13 @@ wxSize wxStaticText::DoGetBestSize() const
|
||||
}
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateStaticText( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
const wxString& label,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxString& WXUNUSED(label),
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSStaticTextView* v = [[wxNSStaticTextView alloc] initWithFrame:r];
|
||||
|
@@ -231,7 +231,7 @@ WX_NSMenu wxTaskBarIconDockImpl::CocoaDoGetDockNSMenu()
|
||||
return (WX_NSMenu)dockMenu->GetHMenu();
|
||||
}
|
||||
|
||||
bool wxTaskBarIconDockImpl::SetIcon(const wxIcon& icon, const wxString& tooltip)
|
||||
bool wxTaskBarIconDockImpl::SetIcon(const wxIcon& WXUNUSED(icon), const wxString& WXUNUSED(tooltip))
|
||||
{
|
||||
wxMacAutoreleasePool pool;
|
||||
m_originalDockIcon = [[[NSApplication sharedApplication] applicationIconImage] retain];
|
||||
@@ -246,7 +246,7 @@ bool wxTaskBarIconDockImpl::RemoveIcon()
|
||||
return true;
|
||||
}
|
||||
|
||||
bool wxTaskBarIconDockImpl::PopupMenu(wxMenu *menu)
|
||||
bool wxTaskBarIconDockImpl::PopupMenu(wxMenu *WXUNUSED(menu))
|
||||
{
|
||||
wxFAIL_MSG(wxT("You cannot force the Dock icon menu to popup"));
|
||||
return false;
|
||||
@@ -266,7 +266,7 @@ wxTaskBarIconCustomStatusItemImpl::~wxTaskBarIconCustomStatusItemImpl()
|
||||
{
|
||||
}
|
||||
|
||||
bool wxTaskBarIconCustomStatusItemImpl::SetIcon(const wxIcon& icon, const wxString& tooltip)
|
||||
bool wxTaskBarIconCustomStatusItemImpl::SetIcon(const wxIcon& icon, const wxString& WXUNUSED(tooltip))
|
||||
{
|
||||
wxMacAutoreleasePool pool;
|
||||
if(!m_cocoaNSStatusItem)
|
||||
@@ -359,7 +359,7 @@ void wxTaskBarIconWindowCustom::OnMouseEvent(wxMouseEvent &event)
|
||||
m_taskBarIconImpl->GetTaskBarIcon()->ProcessEvent(tbiEvent);
|
||||
}
|
||||
|
||||
void wxTaskBarIconWindowCustom::OnPaint(wxPaintEvent &event)
|
||||
void wxTaskBarIconWindowCustom::OnPaint(wxPaintEvent &WXUNUSED(event))
|
||||
{
|
||||
wxPaintDC dc(this);
|
||||
// FIXME: This is a temporary hack until we can see real icons
|
||||
|
@@ -26,13 +26,13 @@
|
||||
#include "wx/osx/private.h"
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateToggleButton( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
const wxString& label,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxString& WXUNUSED(label),
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(style),
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSButton* v = [[wxNSButton alloc] initWithFrame:r];
|
||||
@@ -44,13 +44,13 @@ wxWidgetImplType* wxWidgetImpl::CreateToggleButton( wxWindowMac* wxpeer,
|
||||
}
|
||||
|
||||
wxWidgetImplType* wxWidgetImpl::CreateBitmapToggleButton( wxWindowMac* wxpeer,
|
||||
wxWindowMac* parent,
|
||||
wxWindowID id,
|
||||
const wxBitmap& label,
|
||||
wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id),
|
||||
const wxBitmap& WXUNUSED(label),
|
||||
const wxPoint& pos,
|
||||
const wxSize& size,
|
||||
long style,
|
||||
long extraStyle)
|
||||
long WXUNUSED(style),
|
||||
long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSButton* v = [[wxNSButton alloc] initWithFrame:r];
|
||||
|
@@ -315,6 +315,7 @@ private:
|
||||
|
||||
- (void) clickedAction: (id) sender
|
||||
{
|
||||
wxUnusedVar(sender);
|
||||
if ( impl )
|
||||
{
|
||||
impl->Action();
|
||||
@@ -337,21 +338,25 @@ private:
|
||||
|
||||
- (NSArray *)toolbarDefaultItemIdentifiers:(NSToolbar*)toolbar
|
||||
{
|
||||
wxUnusedVar(toolbar);
|
||||
return nil;
|
||||
}
|
||||
|
||||
- (NSArray *)toolbarAllowedItemIdentifiers:(NSToolbar*)toolbar
|
||||
{
|
||||
wxUnusedVar(toolbar);
|
||||
return nil;
|
||||
}
|
||||
|
||||
- (NSArray *)toolbarSelectableItemIdentifiers:(NSToolbar *)toolbar
|
||||
{
|
||||
wxUnusedVar(toolbar);
|
||||
return nil;
|
||||
}
|
||||
|
||||
- (NSToolbarItem*) toolbar:(NSToolbar*) toolbar itemForItemIdentifier:(NSString*) itemIdentifier willBeInsertedIntoToolbar:(BOOL) flag
|
||||
{
|
||||
wxUnusedVar(toolbar);
|
||||
#ifdef __LP64__
|
||||
wxToolBarTool* tool = (wxToolBarTool*) [itemIdentifier longLongValue];
|
||||
#else
|
||||
@@ -393,6 +398,7 @@ private:
|
||||
|
||||
- (void) clickedAction: (id) sender
|
||||
{
|
||||
wxUnusedVar(sender);
|
||||
if ( impl )
|
||||
{
|
||||
impl->Action();
|
||||
@@ -699,7 +705,7 @@ void wxToolBar::DoGetSize( int *width, int *height ) const
|
||||
{
|
||||
WXWindow tlw = MacGetTopLevelWindowRef();
|
||||
float toolbarHeight = 0.0;
|
||||
NSRect windowFrame;
|
||||
NSRect windowFrame = NSMakeRect(0, 0, 0, 0);
|
||||
|
||||
if(m_macToolbar && [(NSToolbar*)m_macToolbar isVisible])
|
||||
{
|
||||
|
@@ -54,11 +54,11 @@ void wxToolTip::SetWindow( wxWindow *win )
|
||||
m_window = win ;
|
||||
}
|
||||
|
||||
void wxToolTip::Enable( bool flag )
|
||||
void wxToolTip::Enable( bool WXUNUSED(flag) )
|
||||
{
|
||||
}
|
||||
|
||||
void wxToolTip::SetDelay( long msecs )
|
||||
void wxToolTip::SetDelay( long WXUNUSED(msecs) )
|
||||
{
|
||||
}
|
||||
|
||||
@@ -70,7 +70,7 @@ void wxToolTip::SetReshow( long WXUNUSED(msecs) )
|
||||
{
|
||||
}
|
||||
|
||||
void wxToolTip::RelayEvent( wxWindow *win , wxMouseEvent &event )
|
||||
void wxToolTip::RelayEvent( wxWindow *WXUNUSED(win) , wxMouseEvent &WXUNUSED(event) )
|
||||
{
|
||||
}
|
||||
|
||||
@@ -79,7 +79,7 @@ void wxToolTip::RemoveToolTips()
|
||||
}
|
||||
|
||||
// --- mac specific
|
||||
void wxToolTip::NotifyWindowDelete( WXHWND win )
|
||||
void wxToolTip::NotifyWindowDelete( WXHWND WXUNUSED(win) )
|
||||
{
|
||||
}
|
||||
|
||||
|
@@ -76,12 +76,14 @@ void wxMacWakeUp()
|
||||
|
||||
- (BOOL)applicationShouldTerminateAfterLastWindowClosed:(NSApplication *)sender
|
||||
{
|
||||
wxUnusedVar(sender);
|
||||
// let wx do this, not cocoa
|
||||
return NO;
|
||||
}
|
||||
|
||||
- (BOOL)application:(NSApplication *)sender openFile:(NSString *)filename;
|
||||
{
|
||||
wxUnusedVar(sender);
|
||||
wxCFStringRef cf(wxCFRetain(filename));
|
||||
wxTheApp->MacOpenFile(cf.AsString()) ;
|
||||
return YES;
|
||||
@@ -89,12 +91,14 @@ void wxMacWakeUp()
|
||||
|
||||
- (BOOL)applicationShouldOpenUntitledFile:(NSApplication *)sender;
|
||||
{
|
||||
wxUnusedVar(sender);
|
||||
wxTheApp->MacNewFile() ;
|
||||
return NO;
|
||||
}
|
||||
|
||||
- (BOOL)application:(NSApplication *)sender printFile:(NSString *)filename
|
||||
{
|
||||
wxUnusedVar(sender);
|
||||
wxCFStringRef cf(wxCFRetain(filename));
|
||||
wxTheApp->MacPrintFile(cf.AsString()) ;
|
||||
return YES;
|
||||
@@ -109,6 +113,7 @@ void wxMacWakeUp()
|
||||
*/
|
||||
- (NSApplicationTerminateReply)applicationShouldTerminate:(NSApplication *)sender
|
||||
{
|
||||
wxUnusedVar(sender);
|
||||
wxWindow* win = wxTheApp->GetTopWindow() ;
|
||||
if ( win )
|
||||
{
|
||||
@@ -125,6 +130,8 @@ void wxMacWakeUp()
|
||||
|
||||
- (BOOL)applicationShouldHandleReopen:(NSApplication *)sender hasVisibleWindows:(BOOL)flag
|
||||
{
|
||||
wxUnusedVar(flag);
|
||||
wxUnusedVar(sender);
|
||||
wxTheApp->MacReopenApp() ;
|
||||
return NO;
|
||||
}
|
||||
@@ -132,6 +139,7 @@ void wxMacWakeUp()
|
||||
- (void)handleGetURLEvent:(NSAppleEventDescriptor *)event
|
||||
withReplyEvent:(NSAppleEventDescriptor *)replyEvent
|
||||
{
|
||||
wxUnusedVar(replyEvent);
|
||||
NSString* url = [[event descriptorAtIndex:1] stringValue];
|
||||
wxCFStringRef cf(wxCFRetain(url));
|
||||
wxTheApp->MacOpenURL(cf.AsString()) ;
|
||||
@@ -171,6 +179,7 @@ void wxMacWakeUp()
|
||||
|
||||
- (void)sheetDidEnd:(NSWindow *)sheet returnCode:(int)returnCode contextInfo:(void *)contextInfo
|
||||
{
|
||||
wxUnusedVar(contextInfo);
|
||||
resultCode = returnCode;
|
||||
sheetFinished = YES;
|
||||
// NSAlerts don't need nor respond to orderOut
|
||||
@@ -268,14 +277,6 @@ bool wxIsBusy()
|
||||
return (gs_wxBusyCursorCount > 0);
|
||||
}
|
||||
|
||||
void wxMacGlobalToLocal( WindowRef window , Point*pt )
|
||||
{
|
||||
}
|
||||
|
||||
void wxMacLocalToGlobal( WindowRef window , Point*pt )
|
||||
{
|
||||
}
|
||||
|
||||
wxBitmap wxWindowDCImpl::DoGetAsBitmap(const wxRect *subrect) const
|
||||
{
|
||||
// wxScreenDC is derived from wxWindowDC, so a screen dc will
|
||||
|
@@ -609,7 +609,7 @@ void wxOSX_controlDoubleAction(NSView* self, SEL _cmd, id sender)
|
||||
impl->controlDoubleAction(self, _cmd, sender);
|
||||
}
|
||||
|
||||
unsigned int wxWidgetCocoaImpl::draggingEntered(void* s, WXWidget slf, void *_cmd)
|
||||
unsigned int wxWidgetCocoaImpl::draggingEntered(void* s, WXWidget WXUNUSED(slf), void *WXUNUSED(_cmd))
|
||||
{
|
||||
id <NSDraggingInfo>sender = (id <NSDraggingInfo>) s;
|
||||
NSPasteboard *pboard = [sender draggingPasteboard];
|
||||
@@ -654,7 +654,7 @@ unsigned int wxWidgetCocoaImpl::draggingEntered(void* s, WXWidget slf, void *_cm
|
||||
return nsresult;
|
||||
}
|
||||
|
||||
void wxWidgetCocoaImpl::draggingExited(void* s, WXWidget slf, void *_cmd)
|
||||
void wxWidgetCocoaImpl::draggingExited(void* s, WXWidget WXUNUSED(slf), void *WXUNUSED(_cmd))
|
||||
{
|
||||
id <NSDraggingInfo>sender = (id <NSDraggingInfo>) s;
|
||||
NSPasteboard *pboard = [sender draggingPasteboard];
|
||||
@@ -674,7 +674,7 @@ void wxWidgetCocoaImpl::draggingExited(void* s, WXWidget slf, void *_cmd)
|
||||
CFRelease(pboardRef);
|
||||
}
|
||||
|
||||
unsigned int wxWidgetCocoaImpl::draggingUpdated(void* s, WXWidget slf, void *_cmd)
|
||||
unsigned int wxWidgetCocoaImpl::draggingUpdated(void* s, WXWidget WXUNUSED(slf), void *WXUNUSED(_cmd))
|
||||
{
|
||||
id <NSDraggingInfo>sender = (id <NSDraggingInfo>) s;
|
||||
NSPasteboard *pboard = [sender draggingPasteboard];
|
||||
@@ -719,7 +719,7 @@ unsigned int wxWidgetCocoaImpl::draggingUpdated(void* s, WXWidget slf, void *_cm
|
||||
return nsresult;
|
||||
}
|
||||
|
||||
bool wxWidgetCocoaImpl::performDragOperation(void* s, WXWidget slf, void *_cmd)
|
||||
bool wxWidgetCocoaImpl::performDragOperation(void* s, WXWidget WXUNUSED(slf), void *WXUNUSED(_cmd))
|
||||
{
|
||||
id <NSDraggingInfo>sender = (id <NSDraggingInfo>) s;
|
||||
|
||||
@@ -844,7 +844,7 @@ void wxWidgetCocoaImpl::resetCursorRects(WXWidget slf, void *_cmd)
|
||||
}
|
||||
}
|
||||
|
||||
bool wxWidgetCocoaImpl::isFlipped(WXWidget slf, void *_cmd)
|
||||
bool wxWidgetCocoaImpl::isFlipped(WXWidget WXUNUSED(slf), void *WXUNUSED(_cmd))
|
||||
{
|
||||
return m_isFlipped;
|
||||
}
|
||||
@@ -852,7 +852,7 @@ bool wxWidgetCocoaImpl::isFlipped(WXWidget slf, void *_cmd)
|
||||
|
||||
#define OSX_DEBUG_DRAWING 0
|
||||
|
||||
void wxWidgetCocoaImpl::drawRect(void* rect, WXWidget slf, void *_cmd)
|
||||
void wxWidgetCocoaImpl::drawRect(void* rect, WXWidget slf, void *WXUNUSED(_cmd))
|
||||
{
|
||||
CGContextRef context = (CGContextRef) [[NSGraphicsContext currentContext] graphicsPort];
|
||||
CGContextSaveGState( context );
|
||||
@@ -911,14 +911,14 @@ void wxWidgetCocoaImpl::drawRect(void* rect, WXWidget slf, void *_cmd)
|
||||
CGContextRestoreGState( context );
|
||||
}
|
||||
|
||||
void wxWidgetCocoaImpl::controlAction( WXWidget slf, void *_cmd, void *sender)
|
||||
void wxWidgetCocoaImpl::controlAction( WXWidget WXUNUSED(slf), void *WXUNUSED(_cmd), void *WXUNUSED(sender))
|
||||
{
|
||||
wxWindow* wxpeer = (wxWindow*) GetWXPeer();
|
||||
if ( wxpeer )
|
||||
wxpeer->OSXHandleClicked(0);
|
||||
}
|
||||
|
||||
void wxWidgetCocoaImpl::controlDoubleAction( WXWidget slf, void *_cmd, void *sender)
|
||||
void wxWidgetCocoaImpl::controlDoubleAction( WXWidget WXUNUSED(slf), void *WXUNUSED(_cmd), void *WXUNUSED(sender))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -1059,7 +1059,7 @@ void wxWidgetCocoaImpl::Lower()
|
||||
{
|
||||
}
|
||||
|
||||
void wxWidgetCocoaImpl::ScrollRect( const wxRect *rect, int dx, int dy )
|
||||
void wxWidgetCocoaImpl::ScrollRect( const wxRect *WXUNUSED(rect), int WXUNUSED(dx), int WXUNUSED(dy) )
|
||||
{
|
||||
#if 1
|
||||
SetNeedsDisplay() ;
|
||||
@@ -1197,12 +1197,12 @@ void wxWidgetCocoaImpl::SetLabel( const wxString& title, wxFontEncoding encoding
|
||||
{
|
||||
if ( [m_osxView respondsToSelector:@selector(setTitle:) ] )
|
||||
{
|
||||
wxCFStringRef cf( title , m_wxPeer->GetFont().GetEncoding() );
|
||||
wxCFStringRef cf( title , encoding );
|
||||
[m_osxView setTitle:cf.AsNSString()];
|
||||
}
|
||||
else if ( [m_osxView respondsToSelector:@selector(setStringValue:) ] )
|
||||
{
|
||||
wxCFStringRef cf( title , m_wxPeer->GetFont().GetEncoding() );
|
||||
wxCFStringRef cf( title , encoding );
|
||||
[m_osxView setStringValue:cf.AsNSString()];
|
||||
}
|
||||
}
|
||||
@@ -1278,7 +1278,7 @@ void wxWidgetCocoaImpl::SetBitmap( const wxBitmap& bitmap )
|
||||
}
|
||||
}
|
||||
|
||||
void wxWidgetCocoaImpl::SetupTabs( const wxNotebook& notebook)
|
||||
void wxWidgetCocoaImpl::SetupTabs( const wxNotebook& WXUNUSED(notebook))
|
||||
{
|
||||
// implementation in subclass
|
||||
}
|
||||
@@ -1315,7 +1315,7 @@ void wxWidgetCocoaImpl::PulseGauge()
|
||||
{
|
||||
}
|
||||
|
||||
void wxWidgetCocoaImpl::SetScrollThumb( wxInt32 val, wxInt32 view )
|
||||
void wxWidgetCocoaImpl::SetScrollThumb( wxInt32 WXUNUSED(val), wxInt32 WXUNUSED(view) )
|
||||
{
|
||||
}
|
||||
|
||||
@@ -1485,8 +1485,9 @@ void wxWidgetCocoaImpl::SetFlipped(bool flipped)
|
||||
// Factory methods
|
||||
//
|
||||
|
||||
wxWidgetImpl* wxWidgetImpl::CreateUserPane( wxWindowMac* wxpeer, wxWindowMac* parent, wxWindowID id, const wxPoint& pos, const wxSize& size,
|
||||
long style, long extraStyle)
|
||||
wxWidgetImpl* wxWidgetImpl::CreateUserPane( wxWindowMac* wxpeer, wxWindowMac* WXUNUSED(parent),
|
||||
wxWindowID WXUNUSED(id), const wxPoint& pos, const wxSize& size,
|
||||
long WXUNUSED(style), long WXUNUSED(extraStyle))
|
||||
{
|
||||
NSRect r = wxOSXGetFrameForControl( wxpeer, pos , size ) ;
|
||||
wxNSView* v = [[wxNSView alloc] initWithFrame:r];
|
||||
|
Reference in New Issue
Block a user