don't use annoying and unneeded in C++ casts of NULL to "T *" in all other files neither
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58227 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -85,7 +85,7 @@
|
||||
bool g_mainThreadLocked = false;
|
||||
gint g_pendingTag = 0;
|
||||
|
||||
static GtkWidget *gs_RootWindow = (GtkWidget*) NULL;
|
||||
static GtkWidget *gs_RootWindow = NULL;
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// idle system
|
||||
@@ -453,8 +453,8 @@ wxApp::wxApp()
|
||||
m_colorCube = (unsigned char*) NULL;
|
||||
|
||||
// this is NULL for a "regular" wxApp, but is set (and freed) by a wxGLApp
|
||||
m_glVisualInfo = (void *) NULL;
|
||||
m_glFBCInfo = (void *) NULL;
|
||||
m_glVisualInfo = NULL;
|
||||
m_glFBCInfo = NULL;
|
||||
}
|
||||
|
||||
wxApp::~wxApp()
|
||||
|
||||
@@ -54,26 +54,26 @@ IMPLEMENT_DYNAMIC_CLASS(wxMask,wxObject)
|
||||
|
||||
wxMask::wxMask()
|
||||
{
|
||||
m_bitmap = (GdkBitmap *) NULL;
|
||||
m_bitmap = NULL;
|
||||
}
|
||||
|
||||
wxMask::wxMask( const wxBitmap& bitmap, const wxColour& colour )
|
||||
{
|
||||
m_bitmap = (GdkBitmap *) NULL;
|
||||
m_bitmap = NULL;
|
||||
Create( bitmap, colour );
|
||||
}
|
||||
|
||||
#if wxUSE_PALETTE
|
||||
wxMask::wxMask( const wxBitmap& bitmap, int paletteIndex )
|
||||
{
|
||||
m_bitmap = (GdkBitmap *) NULL;
|
||||
m_bitmap = NULL;
|
||||
Create( bitmap, paletteIndex );
|
||||
}
|
||||
#endif // wxUSE_PALETTE
|
||||
|
||||
wxMask::wxMask( const wxBitmap& bitmap )
|
||||
{
|
||||
m_bitmap = (GdkBitmap *) NULL;
|
||||
m_bitmap = NULL;
|
||||
Create( bitmap );
|
||||
}
|
||||
|
||||
@@ -89,7 +89,7 @@ bool wxMask::Create( const wxBitmap& bitmap,
|
||||
if (m_bitmap)
|
||||
{
|
||||
gdk_bitmap_unref( m_bitmap );
|
||||
m_bitmap = (GdkBitmap*) NULL;
|
||||
m_bitmap = NULL;
|
||||
}
|
||||
|
||||
wxImage image = bitmap.ConvertToImage();
|
||||
@@ -195,7 +195,7 @@ bool wxMask::Create( const wxBitmap& bitmap )
|
||||
if (m_bitmap)
|
||||
{
|
||||
gdk_bitmap_unref( m_bitmap );
|
||||
m_bitmap = (GdkBitmap*) NULL;
|
||||
m_bitmap = NULL;
|
||||
}
|
||||
|
||||
if (!bitmap.Ok()) return false;
|
||||
@@ -247,14 +247,14 @@ public:
|
||||
|
||||
wxBitmapRefData::wxBitmapRefData()
|
||||
{
|
||||
m_pixmap = (GdkPixmap *) NULL;
|
||||
m_bitmap = (GdkBitmap *) NULL;
|
||||
m_mask = (wxMask *) NULL;
|
||||
m_pixmap = NULL;
|
||||
m_bitmap = NULL;
|
||||
m_mask = NULL;
|
||||
m_width = 0;
|
||||
m_height = 0;
|
||||
m_bpp = 0;
|
||||
#if wxUSE_PALETTE
|
||||
m_palette = (wxPalette *) NULL;
|
||||
m_palette = NULL;
|
||||
#endif // wxUSE_PALETTE
|
||||
}
|
||||
|
||||
@@ -393,7 +393,7 @@ wxBitmap::wxBitmap(const char* const* bits)
|
||||
|
||||
m_refData = new wxBitmapRefData();
|
||||
|
||||
GdkBitmap *mask = (GdkBitmap*) NULL;
|
||||
GdkBitmap *mask = NULL;
|
||||
|
||||
M_BMPDATA->m_pixmap = gdk_pixmap_create_from_xpm_d( wxGetRootWindow()->window, &mask, NULL, (gchar **) bits );
|
||||
|
||||
@@ -424,7 +424,7 @@ wxBitmap wxBitmap::Rescale( int clipx, int clipy, int clipwidth, int clipheight,
|
||||
|
||||
wxBitmap bmp;
|
||||
|
||||
GdkImage *img = (GdkImage*) NULL;
|
||||
GdkImage *img = NULL;
|
||||
if (GetPixmap())
|
||||
img = gdk_image_get( GetPixmap(), 0, 0, GetWidth(), GetHeight() );
|
||||
else if (GetBitmap())
|
||||
@@ -643,7 +643,7 @@ bool wxBitmap::CreateFromImageAsBitmap(const wxImage& img)
|
||||
|
||||
// Create mask image
|
||||
|
||||
GdkImage *mask_image = (GdkImage*) NULL;
|
||||
GdkImage *mask_image = NULL;
|
||||
|
||||
if (image.HasMask())
|
||||
{
|
||||
@@ -779,7 +779,7 @@ bool wxBitmap::CreateFromImageAsPixmap(const wxImage& img)
|
||||
|
||||
// Create mask image
|
||||
|
||||
GdkImage *mask_image = (GdkImage*) NULL;
|
||||
GdkImage *mask_image = NULL;
|
||||
|
||||
if (image.HasMask())
|
||||
{
|
||||
@@ -977,7 +977,7 @@ wxImage wxBitmap::ConvertToImage() const
|
||||
static const int MASK_BLUE = 3;
|
||||
static const int MASK_BLUE_REPLACEMENT = 2;
|
||||
|
||||
GdkImage *gdk_image = (GdkImage*) NULL;
|
||||
GdkImage *gdk_image = NULL;
|
||||
|
||||
if (HasPixmap())
|
||||
{
|
||||
@@ -998,7 +998,7 @@ wxImage wxBitmap::ConvertToImage() const
|
||||
|
||||
wxCHECK_MSG( gdk_image, wxNullImage, wxT("couldn't create image") );
|
||||
|
||||
GdkImage *gdk_image_mask = (GdkImage*) NULL;
|
||||
GdkImage *gdk_image_mask = NULL;
|
||||
if (GetMask())
|
||||
{
|
||||
gdk_image_mask = gdk_image_get( GetMask()->GetBitmap(),
|
||||
@@ -1119,7 +1119,7 @@ wxBitmap::wxBitmap( const char bits[], int width, int height, int WXUNUSED(depth
|
||||
{
|
||||
m_refData = new wxBitmapRefData();
|
||||
|
||||
M_BMPDATA->m_mask = (wxMask *) NULL;
|
||||
M_BMPDATA->m_mask = NULL;
|
||||
M_BMPDATA->m_bitmap = gdk_bitmap_create_from_data
|
||||
(
|
||||
wxGetRootWindow()->window,
|
||||
@@ -1162,7 +1162,7 @@ int wxBitmap::GetDepth() const
|
||||
|
||||
wxMask *wxBitmap::GetMask() const
|
||||
{
|
||||
wxCHECK_MSG( Ok(), (wxMask *) NULL, wxT("invalid bitmap") );
|
||||
wxCHECK_MSG( Ok(), NULL, wxT("invalid bitmap") );
|
||||
|
||||
return M_BMPDATA->m_mask;
|
||||
}
|
||||
@@ -1257,7 +1257,7 @@ bool wxBitmap::LoadFile( const wxString &name, wxBitmapType type )
|
||||
{
|
||||
m_refData = new wxBitmapRefData();
|
||||
|
||||
GdkBitmap *mask = (GdkBitmap*) NULL;
|
||||
GdkBitmap *mask = NULL;
|
||||
|
||||
M_BMPDATA->m_pixmap = gdk_pixmap_create_from_xpm
|
||||
(
|
||||
@@ -1293,7 +1293,7 @@ bool wxBitmap::LoadFile( const wxString &name, wxBitmapType type )
|
||||
wxPalette *wxBitmap::GetPalette() const
|
||||
{
|
||||
if (!Ok())
|
||||
return (wxPalette *) NULL;
|
||||
return NULL;
|
||||
|
||||
return M_BMPDATA->m_palette;
|
||||
}
|
||||
@@ -1340,7 +1340,7 @@ void wxBitmap::SetBitmap( GdkPixmap *bitmap )
|
||||
|
||||
GdkPixmap *wxBitmap::GetPixmap() const
|
||||
{
|
||||
wxCHECK_MSG( Ok(), (GdkPixmap *) NULL, wxT("invalid bitmap") );
|
||||
wxCHECK_MSG( Ok(), NULL, wxT("invalid bitmap") );
|
||||
|
||||
return M_BMPDATA->m_pixmap;
|
||||
}
|
||||
@@ -1354,7 +1354,7 @@ bool wxBitmap::HasPixmap() const
|
||||
|
||||
GdkBitmap *wxBitmap::GetBitmap() const
|
||||
{
|
||||
wxCHECK_MSG( Ok(), (GdkBitmap *) NULL, wxT("invalid bitmap") );
|
||||
wxCHECK_MSG( Ok(), NULL, wxT("invalid bitmap") );
|
||||
|
||||
return M_BMPDATA->m_bitmap;
|
||||
}
|
||||
|
||||
@@ -206,7 +206,7 @@ void wxBitmapButton::OnSetBitmap()
|
||||
if (!the_one.Ok()) the_one = m_bmpNormal;
|
||||
if (!the_one.Ok()) return;
|
||||
|
||||
GdkBitmap *mask = (GdkBitmap *) NULL;
|
||||
GdkBitmap *mask = NULL;
|
||||
if (the_one.GetMask()) mask = the_one.GetMask()->GetBitmap();
|
||||
|
||||
GtkWidget *child = BUTTON_CHILD(m_widget);
|
||||
|
||||
@@ -90,7 +90,7 @@ IMPLEMENT_DYNAMIC_CLASS(wxChoice, wxControlWithItems)
|
||||
|
||||
wxChoice::wxChoice()
|
||||
{
|
||||
m_strings = (wxSortedArrayString *)NULL;
|
||||
m_strings = NULL;
|
||||
}
|
||||
|
||||
bool wxChoice::Create( wxWindow *parent, wxWindowID id,
|
||||
@@ -282,7 +282,7 @@ int wxChoice::FindString( const wxString &string, bool bCase ) const
|
||||
while (child)
|
||||
{
|
||||
GtkBin *bin = GTK_BIN( child->data );
|
||||
GtkLabel *label = (GtkLabel *) NULL;
|
||||
GtkLabel *label = NULL;
|
||||
if (bin->child)
|
||||
label = GTK_LABEL(bin->child);
|
||||
if (!label)
|
||||
@@ -322,7 +322,7 @@ void wxChoice::SetString(unsigned int n, const wxString& str )
|
||||
GtkBin *bin = GTK_BIN( child->data );
|
||||
if (count == n)
|
||||
{
|
||||
GtkLabel *label = (GtkLabel *) NULL;
|
||||
GtkLabel *label = NULL;
|
||||
if (bin->child)
|
||||
label = GTK_LABEL(bin->child);
|
||||
if (!label)
|
||||
@@ -351,7 +351,7 @@ wxString wxChoice::GetString(unsigned int n) const
|
||||
GtkBin *bin = GTK_BIN( child->data );
|
||||
if (count == n)
|
||||
{
|
||||
GtkLabel *label = (GtkLabel *) NULL;
|
||||
GtkLabel *label = NULL;
|
||||
if (bin->child)
|
||||
label = GTK_LABEL(bin->child);
|
||||
if (!label)
|
||||
@@ -424,7 +424,7 @@ void wxChoice::DoApplyWidgetStyle(GtkRcStyle *style)
|
||||
gtk_widget_modify_style( GTK_WIDGET( child->data ), style );
|
||||
|
||||
GtkBin *bin = GTK_BIN( child->data );
|
||||
GtkWidget *label = (GtkWidget *) NULL;
|
||||
GtkWidget *label = NULL;
|
||||
if (bin->child)
|
||||
label = bin->child;
|
||||
if (!label)
|
||||
@@ -453,11 +453,11 @@ int wxChoice::GtkAddHelper(GtkWidget *menu, unsigned int pos, const wxString& it
|
||||
if ( index )
|
||||
{
|
||||
m_clientList.Insert( m_clientList.Item(index - 1),
|
||||
(wxObject*) NULL );
|
||||
NULL );
|
||||
}
|
||||
else
|
||||
{
|
||||
m_clientList.Insert( (wxObject*) NULL );
|
||||
m_clientList.Insert( NULL );
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -469,13 +469,13 @@ int wxChoice::GtkAddHelper(GtkWidget *menu, unsigned int pos, const wxString& it
|
||||
if (pos == m_clientList.GetCount())
|
||||
{
|
||||
gtk_menu_append( GTK_MENU(menu), menu_item );
|
||||
m_clientList.Append( (wxObject*) NULL );
|
||||
m_clientList.Append( NULL );
|
||||
index = m_clientList.GetCount() - 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
gtk_menu_insert( GTK_MENU(menu), menu_item, pos );
|
||||
m_clientList.Insert( pos, (wxObject*) NULL );
|
||||
m_clientList.Insert( pos, NULL );
|
||||
index = pos;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -219,7 +219,7 @@ selection_clear_clip( GtkWidget *WXUNUSED(widget), GdkEventSelection *event )
|
||||
wxLogTrace(TRACE_CLIPBOARD, wxT("wxClipboard will get cleared" ));
|
||||
|
||||
delete wxTheClipboard->m_data;
|
||||
wxTheClipboard->m_data = (wxDataObject*) NULL;
|
||||
wxTheClipboard->m_data = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -313,8 +313,8 @@ wxClipboard::wxClipboard()
|
||||
m_ownsClipboard = false;
|
||||
m_ownsPrimarySelection = false;
|
||||
|
||||
m_data = (wxDataObject*) NULL;
|
||||
m_receivedData = (wxDataObject*) NULL;
|
||||
m_data = NULL;
|
||||
m_receivedData = NULL;
|
||||
|
||||
/* we use m_targetsWidget to query what formats are available */
|
||||
|
||||
@@ -371,7 +371,7 @@ void wxClipboard::Clear()
|
||||
{
|
||||
m_waiting = true;
|
||||
|
||||
gtk_selection_owner_set( (GtkWidget*) NULL, g_clipboardAtom,
|
||||
gtk_selection_owner_set( NULL, g_clipboardAtom,
|
||||
(guint32) GDK_CURRENT_TIME );
|
||||
|
||||
while (m_waiting) gtk_main_iteration();
|
||||
@@ -381,7 +381,7 @@ void wxClipboard::Clear()
|
||||
{
|
||||
m_waiting = true;
|
||||
|
||||
gtk_selection_owner_set( (GtkWidget*) NULL, GDK_SELECTION_PRIMARY,
|
||||
gtk_selection_owner_set( NULL, GDK_SELECTION_PRIMARY,
|
||||
(guint32) GDK_CURRENT_TIME );
|
||||
|
||||
while (m_waiting) gtk_main_iteration();
|
||||
@@ -390,7 +390,7 @@ void wxClipboard::Clear()
|
||||
if (m_data)
|
||||
{
|
||||
delete m_data;
|
||||
m_data = (wxDataObject*) NULL;
|
||||
m_data = NULL;
|
||||
}
|
||||
|
||||
#if wxUSE_THREADS
|
||||
|
||||
@@ -35,7 +35,7 @@ public:
|
||||
m_color.green = 0;
|
||||
m_color.blue = 0;
|
||||
m_color.pixel = 0;
|
||||
m_colormap = (GdkColormap *) NULL;
|
||||
m_colormap = NULL;
|
||||
m_hasPixel = false;
|
||||
}
|
||||
|
||||
@@ -178,7 +178,7 @@ void wxColour::InitRGBA(unsigned char red, unsigned char green, unsigned char bl
|
||||
M_COLDATA->m_color.blue = ((unsigned short)blue) << SHIFT;
|
||||
M_COLDATA->m_color.pixel = 0;
|
||||
|
||||
M_COLDATA->m_colormap = (GdkColormap*) NULL;
|
||||
M_COLDATA->m_colormap = NULL;
|
||||
M_COLDATA->m_hasPixel = false;
|
||||
}
|
||||
|
||||
@@ -219,7 +219,7 @@ int wxColour::GetPixel() const
|
||||
|
||||
GdkColor *wxColour::GetColor() const
|
||||
{
|
||||
wxCHECK_MSG( Ok(), (GdkColor *) NULL, wxT("invalid colour") );
|
||||
wxCHECK_MSG( Ok(), NULL, wxT("invalid colour") );
|
||||
|
||||
return &M_COLDATA->m_color;
|
||||
}
|
||||
|
||||
@@ -247,8 +247,8 @@ bool wxComboBox::Create( wxWindow *parent, wxWindowID id, const wxString& value,
|
||||
{
|
||||
GtkWidget *list_item = gtk_list_item_new_with_label( wxGTK_CONV( choices[i] ) );
|
||||
|
||||
m_clientDataList.Append( (wxObject*)NULL );
|
||||
m_clientObjectList.Append( (wxObject*)NULL );
|
||||
m_clientDataList.Append( NULL );
|
||||
m_clientObjectList.Append( NULL );
|
||||
|
||||
gtk_container_add( GTK_CONTAINER(list), list_item );
|
||||
|
||||
@@ -365,9 +365,9 @@ int wxComboBox::DoInsertItems(const wxArrayStringsAdapter& items,
|
||||
gtk_widget_show( list_item );
|
||||
|
||||
if ( m_clientDataList.GetCount() < GetCount() )
|
||||
m_clientDataList.Insert( pos, (wxObject*) NULL );
|
||||
m_clientDataList.Insert( pos, NULL );
|
||||
if ( m_clientObjectList.GetCount() < GetCount() )
|
||||
m_clientObjectList.Insert( pos, (wxObject*) NULL );
|
||||
m_clientObjectList.Insert( pos, NULL );
|
||||
|
||||
AssignNewItemClientData(pos, clientData, i, type);
|
||||
}
|
||||
@@ -435,7 +435,7 @@ void wxComboBox::DoDeleteOneItem(unsigned int n)
|
||||
|
||||
DisableEvents();
|
||||
|
||||
GList *list = g_list_append( (GList*) NULL, child->data );
|
||||
GList *list = g_list_append( NULL, child->data );
|
||||
gtk_list_remove_items( listbox, list );
|
||||
g_list_free( list );
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@ public:
|
||||
|
||||
wxCursorRefData::wxCursorRefData()
|
||||
{
|
||||
m_cursor = (GdkCursor *) NULL;
|
||||
m_cursor = NULL;
|
||||
}
|
||||
|
||||
wxCursorRefData::~wxCursorRefData()
|
||||
|
||||
@@ -241,7 +241,7 @@ static GdkGC* wxGetPoolGC( GdkWindow *window, wxPoolGCType type )
|
||||
// The realloc failed. Fall through to error.
|
||||
wxFAIL_MSG( wxT("No GC available") );
|
||||
|
||||
return (GdkGC*) NULL;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static void wxFreePoolGC( GdkGC *gc )
|
||||
@@ -267,14 +267,14 @@ IMPLEMENT_ABSTRACT_CLASS(wxWindowDCImpl, wxDC)
|
||||
wxWindowDCImpl::wxWindowDCImpl(wxDC *owner)
|
||||
: wxGTKDCImpl(owner)
|
||||
{
|
||||
m_penGC = (GdkGC *) NULL;
|
||||
m_brushGC = (GdkGC *) NULL;
|
||||
m_textGC = (GdkGC *) NULL;
|
||||
m_bgGC = (GdkGC *) NULL;
|
||||
m_cmap = (GdkColormap *) NULL;
|
||||
m_penGC = NULL;
|
||||
m_brushGC = NULL;
|
||||
m_textGC = NULL;
|
||||
m_bgGC = NULL;
|
||||
m_cmap = NULL;
|
||||
m_isMemDC = false;
|
||||
m_isScreenDC = false;
|
||||
m_owner = (wxWindow *)NULL;
|
||||
m_owner = NULL;
|
||||
}
|
||||
|
||||
wxWindowDCImpl::wxWindowDCImpl(wxDC *owner, wxWindow *window)
|
||||
@@ -282,12 +282,12 @@ wxWindowDCImpl::wxWindowDCImpl(wxDC *owner, wxWindow *window)
|
||||
{
|
||||
wxASSERT_MSG( window, wxT("DC needs a window") );
|
||||
|
||||
m_penGC = (GdkGC *) NULL;
|
||||
m_brushGC = (GdkGC *) NULL;
|
||||
m_textGC = (GdkGC *) NULL;
|
||||
m_bgGC = (GdkGC *) NULL;
|
||||
m_cmap = (GdkColormap *) NULL;
|
||||
m_owner = (wxWindow *)NULL;
|
||||
m_penGC = NULL;
|
||||
m_brushGC = NULL;
|
||||
m_textGC = NULL;
|
||||
m_bgGC = NULL;
|
||||
m_cmap = NULL;
|
||||
m_owner = NULL;
|
||||
m_isMemDC = false;
|
||||
m_isScreenDC = false;
|
||||
m_font = window->GetFont();
|
||||
@@ -404,20 +404,20 @@ void wxWindowDCImpl::SetUpDC()
|
||||
gdk_gc_set_function( m_penGC, GDK_COPY );
|
||||
|
||||
/* clipping */
|
||||
gdk_gc_set_clip_rectangle( m_penGC, (GdkRectangle *) NULL );
|
||||
gdk_gc_set_clip_rectangle( m_brushGC, (GdkRectangle *) NULL );
|
||||
gdk_gc_set_clip_rectangle( m_textGC, (GdkRectangle *) NULL );
|
||||
gdk_gc_set_clip_rectangle( m_bgGC, (GdkRectangle *) NULL );
|
||||
gdk_gc_set_clip_rectangle( m_penGC, NULL );
|
||||
gdk_gc_set_clip_rectangle( m_brushGC, NULL );
|
||||
gdk_gc_set_clip_rectangle( m_textGC, NULL );
|
||||
gdk_gc_set_clip_rectangle( m_bgGC, NULL );
|
||||
|
||||
if (!hatch_bitmap)
|
||||
{
|
||||
hatch_bitmap = hatches;
|
||||
hatch_bitmap[0] = gdk_bitmap_create_from_data( (GdkWindow *) NULL, bdiag_bits, bdiag_width, bdiag_height );
|
||||
hatch_bitmap[1] = gdk_bitmap_create_from_data( (GdkWindow *) NULL, cdiag_bits, cdiag_width, cdiag_height );
|
||||
hatch_bitmap[2] = gdk_bitmap_create_from_data( (GdkWindow *) NULL, fdiag_bits, fdiag_width, fdiag_height );
|
||||
hatch_bitmap[3] = gdk_bitmap_create_from_data( (GdkWindow *) NULL, cross_bits, cross_width, cross_height );
|
||||
hatch_bitmap[4] = gdk_bitmap_create_from_data( (GdkWindow *) NULL, horiz_bits, horiz_width, horiz_height );
|
||||
hatch_bitmap[5] = gdk_bitmap_create_from_data( (GdkWindow *) NULL, verti_bits, verti_width, verti_height );
|
||||
hatch_bitmap[0] = gdk_bitmap_create_from_data( NULL, bdiag_bits, bdiag_width, bdiag_height );
|
||||
hatch_bitmap[1] = gdk_bitmap_create_from_data( NULL, cdiag_bits, cdiag_width, cdiag_height );
|
||||
hatch_bitmap[2] = gdk_bitmap_create_from_data( NULL, fdiag_bits, fdiag_width, fdiag_height );
|
||||
hatch_bitmap[3] = gdk_bitmap_create_from_data( NULL, cross_bits, cross_width, cross_height );
|
||||
hatch_bitmap[4] = gdk_bitmap_create_from_data( NULL, horiz_bits, horiz_width, horiz_height );
|
||||
hatch_bitmap[5] = gdk_bitmap_create_from_data( NULL, verti_bits, verti_width, verti_height );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1044,10 +1044,10 @@ void wxWindowDCImpl::DoDrawBitmap( const wxBitmap &bitmap,
|
||||
use_bitmap.GetPixmap();
|
||||
|
||||
// apply mask if any
|
||||
GdkBitmap *mask = (GdkBitmap *) NULL;
|
||||
GdkBitmap *mask = NULL;
|
||||
if (use_bitmap.GetMask()) mask = use_bitmap.GetMask()->GetBitmap();
|
||||
|
||||
GdkBitmap *new_mask = (GdkBitmap*) NULL;
|
||||
GdkBitmap *new_mask = NULL;
|
||||
|
||||
if (useMask && mask)
|
||||
{
|
||||
@@ -1107,14 +1107,14 @@ void wxWindowDCImpl::DoDrawBitmap( const wxBitmap &bitmap,
|
||||
{
|
||||
if (is_mono)
|
||||
{
|
||||
gdk_gc_set_clip_mask( m_textGC, (GdkBitmap *) NULL );
|
||||
gdk_gc_set_clip_mask( m_textGC, NULL );
|
||||
gdk_gc_set_clip_origin( m_textGC, 0, 0 );
|
||||
if (!m_currentClippingRegion.IsNull())
|
||||
gdk_gc_set_clip_region( m_textGC, m_currentClippingRegion.GetRegion() );
|
||||
}
|
||||
else
|
||||
{
|
||||
gdk_gc_set_clip_mask( m_penGC, (GdkBitmap *) NULL );
|
||||
gdk_gc_set_clip_mask( m_penGC, NULL );
|
||||
gdk_gc_set_clip_origin( m_penGC, 0, 0 );
|
||||
if (!m_currentClippingRegion.IsNull())
|
||||
gdk_gc_set_clip_region( m_penGC, m_currentClippingRegion.GetRegion() );
|
||||
@@ -1267,10 +1267,10 @@ bool wxWindowDCImpl::DoBlit( wxCoord xdest, wxCoord ydest,
|
||||
}
|
||||
|
||||
// apply mask if any
|
||||
GdkBitmap *mask = (GdkBitmap *) NULL;
|
||||
GdkBitmap *mask = NULL;
|
||||
if (use_bitmap.GetMask()) mask = use_bitmap.GetMask()->GetBitmap();
|
||||
|
||||
GdkBitmap *new_mask = (GdkBitmap*) NULL;
|
||||
GdkBitmap *new_mask = NULL;
|
||||
|
||||
if (useMask && mask)
|
||||
{
|
||||
@@ -1343,14 +1343,14 @@ bool wxWindowDCImpl::DoBlit( wxCoord xdest, wxCoord ydest,
|
||||
{
|
||||
if (is_mono)
|
||||
{
|
||||
gdk_gc_set_clip_mask( m_textGC, (GdkBitmap *) NULL );
|
||||
gdk_gc_set_clip_mask( m_textGC, NULL );
|
||||
gdk_gc_set_clip_origin( m_textGC, 0, 0 );
|
||||
if (!m_currentClippingRegion.IsNull())
|
||||
gdk_gc_set_clip_region( m_textGC, m_currentClippingRegion.GetRegion() );
|
||||
}
|
||||
else
|
||||
{
|
||||
gdk_gc_set_clip_mask( m_penGC, (GdkBitmap *) NULL );
|
||||
gdk_gc_set_clip_mask( m_penGC, NULL );
|
||||
gdk_gc_set_clip_origin( m_penGC, 0, 0 );
|
||||
if (!m_currentClippingRegion.IsNull())
|
||||
gdk_gc_set_clip_region( m_penGC, m_currentClippingRegion.GetRegion() );
|
||||
@@ -1733,7 +1733,7 @@ void wxWindowDCImpl::SetPen( const wxPen &pen )
|
||||
default:
|
||||
{
|
||||
lineStyle = GDK_LINE_SOLID;
|
||||
req_dash = (wxGTKDash*)NULL;
|
||||
req_dash = NULL;
|
||||
req_nb_dash = 0;
|
||||
break;
|
||||
}
|
||||
@@ -2070,10 +2070,10 @@ void wxWindowDCImpl::DestroyClippingRegion()
|
||||
|
||||
if (m_currentClippingRegion.IsEmpty())
|
||||
{
|
||||
gdk_gc_set_clip_rectangle( m_penGC, (GdkRectangle *) NULL );
|
||||
gdk_gc_set_clip_rectangle( m_brushGC, (GdkRectangle *) NULL );
|
||||
gdk_gc_set_clip_rectangle( m_textGC, (GdkRectangle *) NULL );
|
||||
gdk_gc_set_clip_rectangle( m_bgGC, (GdkRectangle *) NULL );
|
||||
gdk_gc_set_clip_rectangle( m_penGC, NULL );
|
||||
gdk_gc_set_clip_rectangle( m_brushGC, NULL );
|
||||
gdk_gc_set_clip_rectangle( m_textGC, NULL );
|
||||
gdk_gc_set_clip_rectangle( m_bgGC, NULL );
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -2087,13 +2087,13 @@ void wxWindowDCImpl::DestroyClippingRegion()
|
||||
void wxWindowDCImpl::Destroy()
|
||||
{
|
||||
if (m_penGC) wxFreePoolGC( m_penGC );
|
||||
m_penGC = (GdkGC*) NULL;
|
||||
m_penGC = NULL;
|
||||
if (m_brushGC) wxFreePoolGC( m_brushGC );
|
||||
m_brushGC = (GdkGC*) NULL;
|
||||
m_brushGC = NULL;
|
||||
if (m_textGC) wxFreePoolGC( m_textGC );
|
||||
m_textGC = (GdkGC*) NULL;
|
||||
m_textGC = NULL;
|
||||
if (m_bgGC) wxFreePoolGC( m_bgGC );
|
||||
m_bgGC = (GdkGC*) NULL;
|
||||
m_bgGC = NULL;
|
||||
}
|
||||
|
||||
void wxWindowDCImpl::ComputeScaleAndOrigin()
|
||||
|
||||
@@ -61,7 +61,7 @@ void wxMemoryDCImpl::DoSelect( const wxBitmap& bitmap )
|
||||
else
|
||||
{
|
||||
m_ok = false;
|
||||
m_window = (GdkWindow *) NULL;
|
||||
m_window = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
// global data initialization
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
GdkWindow *wxScreenDCImpl::sm_overlayWindow = (GdkWindow*) NULL;
|
||||
GdkWindow *wxScreenDCImpl::sm_overlayWindow = NULL;
|
||||
int wxScreenDCImpl::sm_overlayWindowX = 0;
|
||||
int wxScreenDCImpl::sm_overlayWindowY = 0;
|
||||
|
||||
|
||||
@@ -193,7 +193,7 @@ static void target_drag_leave( GtkWidget *WXUNUSED(widget),
|
||||
drop_target->m_firstMotion = true;
|
||||
|
||||
/* after this, invalidate the drop_target's GdkDragContext */
|
||||
drop_target->SetDragContext( (GdkDragContext*) NULL );
|
||||
drop_target->SetDragContext( NULL );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -286,7 +286,7 @@ static gboolean target_drag_motion( GtkWidget *WXUNUSED(widget),
|
||||
}
|
||||
|
||||
/* after this, invalidate the drop_target's GdkDragContext */
|
||||
drop_target->SetDragContext( (GdkDragContext*) NULL );
|
||||
drop_target->SetDragContext( NULL );
|
||||
|
||||
/* this has to be done because GDK has no "drag_enter" event */
|
||||
drop_target->m_firstMotion = false;
|
||||
@@ -384,10 +384,10 @@ static gboolean target_drag_drop( GtkWidget *widget,
|
||||
}
|
||||
|
||||
/* after this, invalidate the drop_target's GdkDragContext */
|
||||
drop_target->SetDragContext( (GdkDragContext*) NULL );
|
||||
drop_target->SetDragContext( NULL );
|
||||
|
||||
/* after this, invalidate the drop_target's drag widget */
|
||||
drop_target->SetDragWidget( (GtkWidget*) NULL );
|
||||
drop_target->SetDragWidget( NULL );
|
||||
|
||||
/* this has to be done because GDK has no "drag_enter" event */
|
||||
drop_target->m_firstMotion = true;
|
||||
@@ -448,7 +448,7 @@ static void target_drag_data_received( GtkWidget *WXUNUSED(widget),
|
||||
}
|
||||
|
||||
/* after this, invalidate the drop_target's drag data */
|
||||
drop_target->SetDragData( (GtkSelectionData*) NULL );
|
||||
drop_target->SetDragData( NULL );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -460,9 +460,9 @@ wxDropTarget::wxDropTarget( wxDataObject *data )
|
||||
: wxDropTargetBase( data )
|
||||
{
|
||||
m_firstMotion = true;
|
||||
m_dragContext = (GdkDragContext*) NULL;
|
||||
m_dragWidget = (GtkWidget*) NULL;
|
||||
m_dragData = (GtkSelectionData*) NULL;
|
||||
m_dragContext = NULL;
|
||||
m_dragWidget = NULL;
|
||||
m_dragData = NULL;
|
||||
m_dragTime = 0;
|
||||
}
|
||||
|
||||
@@ -582,7 +582,7 @@ void wxDropTarget::RegisterWidget( GtkWidget *widget )
|
||||
|
||||
gtk_drag_dest_set( widget,
|
||||
(GtkDestDefaults) 0, /* no default behaviour */
|
||||
(GtkTargetEntry*) NULL, /* we don't supply any formats here */
|
||||
NULL, /* we don't supply any formats here */
|
||||
0, /* number of targets = 0 */
|
||||
(GdkDragAction) 0 ); /* we don't supply any actions here */
|
||||
|
||||
@@ -748,7 +748,7 @@ wxDropSource::wxDropSource(wxWindow *win,
|
||||
{
|
||||
m_waiting = true;
|
||||
|
||||
m_iconWindow = (GtkWidget*) NULL;
|
||||
m_iconWindow = NULL;
|
||||
|
||||
m_window = win;
|
||||
m_widget = win->m_widget;
|
||||
@@ -769,7 +769,7 @@ wxDropSource::wxDropSource(wxDataObject& data,
|
||||
|
||||
SetData( data );
|
||||
|
||||
m_iconWindow = (GtkWidget*) NULL;
|
||||
m_iconWindow = NULL;
|
||||
|
||||
m_window = win;
|
||||
m_widget = win->m_widget;
|
||||
@@ -815,7 +815,7 @@ void wxDropSource::PrepareIcon( int action, GdkDragContext *context )
|
||||
if ( icon->GetMask() )
|
||||
mask = icon->GetMask()->GetBitmap();
|
||||
else
|
||||
mask = (GdkBitmap *)NULL;
|
||||
mask = NULL;
|
||||
|
||||
GdkPixmap *pixmap = icon->GetPixmap();
|
||||
|
||||
@@ -871,7 +871,7 @@ wxDragResult wxDropSource::DoDragDrop(int flags)
|
||||
|
||||
m_waiting = true;
|
||||
|
||||
GtkTargetList *target_list = gtk_target_list_new( (GtkTargetEntry*) NULL, 0 );
|
||||
GtkTargetList *target_list = gtk_target_list_new( NULL, 0 );
|
||||
|
||||
wxDataFormat *array = new wxDataFormat[ m_data->GetFormatCount() ];
|
||||
m_data->GetAllFormats( array );
|
||||
|
||||
@@ -609,7 +609,7 @@ bool wxFont::GetNoAntiAliasing() const
|
||||
|
||||
const wxNativeFontInfo *wxFont::GetNativeFontInfo() const
|
||||
{
|
||||
wxCHECK_MSG( Ok(), (wxNativeFontInfo *)NULL, wxT("invalid font") );
|
||||
wxCHECK_MSG( Ok(), NULL, wxT("invalid font") );
|
||||
|
||||
if ( !M_FONTDATA->HasNativeFont() )
|
||||
{
|
||||
@@ -710,7 +710,7 @@ void wxFont::SetNoAntiAliasing( bool no )
|
||||
// get internal representation of font
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
static GdkFont *g_systemDefaultGuiFont = (GdkFont*) NULL;
|
||||
static GdkFont *g_systemDefaultGuiFont = NULL;
|
||||
|
||||
// this is also used from tbargtk.cpp and tooltip.cpp, hence extern
|
||||
extern GdkFont *GtkGetDefaultGuiFont()
|
||||
@@ -742,7 +742,7 @@ extern GdkFont *GtkGetDefaultGuiFont()
|
||||
|
||||
GdkFont *wxFont::GetInternalFont( float scale ) const
|
||||
{
|
||||
GdkFont *font = (GdkFont *) NULL;
|
||||
GdkFont *font = NULL;
|
||||
|
||||
wxCHECK_MSG( Ok(), font, wxT("invalid font") );
|
||||
|
||||
|
||||
@@ -385,7 +385,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
|
||||
geom.max_width = maxWidth;
|
||||
geom.max_height = maxHeight;
|
||||
gtk_window_set_geometry_hints( GTK_WINDOW(m_widget),
|
||||
(GtkWidget*) NULL,
|
||||
NULL,
|
||||
&geom,
|
||||
(GdkWindowHints) flag );
|
||||
|
||||
@@ -486,7 +486,7 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
|
||||
gtk_pizza_set_size( GTK_PIZZA(m_wxwindow),
|
||||
m_frameStatusBar->m_widget,
|
||||
xx, yy, ww, hh );
|
||||
gtk_widget_draw( m_frameStatusBar->m_widget, (GdkRectangle*) NULL );
|
||||
gtk_widget_draw( m_frameStatusBar->m_widget, NULL );
|
||||
}
|
||||
#endif // wxUSE_STATUSBAR
|
||||
|
||||
|
||||
@@ -134,7 +134,7 @@ static gint gtk_listitem_focus_out_callback( GtkWidget *WXUNUSED(widget),
|
||||
if (g_isIdle)
|
||||
wxapp_install_idle_handler();
|
||||
|
||||
g_focusWindow = (wxWindowGTK *)NULL;
|
||||
g_focusWindow = NULL;
|
||||
|
||||
// don't send the window a kill focus event if it thinks that it doesn't
|
||||
// have focus already
|
||||
@@ -460,7 +460,7 @@ IMPLEMENT_DYNAMIC_CLASS(wxListBox, wxControlWithItems)
|
||||
|
||||
wxListBox::wxListBox()
|
||||
{
|
||||
m_list = (GtkList *) NULL;
|
||||
m_list = NULL;
|
||||
#if wxUSE_CHECKLISTBOX
|
||||
m_hasCheckBoxes = false;
|
||||
#endif // wxUSE_CHECKLISTBOX
|
||||
@@ -496,7 +496,7 @@ bool wxListBox::Create( wxWindow *parent, wxWindowID id,
|
||||
return false;
|
||||
}
|
||||
|
||||
m_widget = gtk_scrolled_window_new( (GtkAdjustment*) NULL, (GtkAdjustment*) NULL );
|
||||
m_widget = gtk_scrolled_window_new( NULL, NULL );
|
||||
if (style & wxLB_ALWAYS_SB)
|
||||
{
|
||||
gtk_scrolled_window_set_policy( GTK_SCROLLED_WINDOW(m_widget),
|
||||
@@ -548,7 +548,7 @@ bool wxListBox::Create( wxWindow *parent, wxWindowID id,
|
||||
}
|
||||
else
|
||||
{
|
||||
m_strings = (wxSortedArrayString *)NULL;
|
||||
m_strings = NULL;
|
||||
}
|
||||
|
||||
Append(n, choices);
|
||||
@@ -722,7 +722,7 @@ void wxListBox::DoDeleteOneItem(unsigned int n)
|
||||
|
||||
wxCHECK_RET( child, wxT("wrong listbox index") );
|
||||
|
||||
GList *list = g_list_append( (GList*) NULL, child->data );
|
||||
GList *list = g_list_append( NULL, child->data );
|
||||
gtk_list_remove_items( m_list, list );
|
||||
g_list_free( list );
|
||||
|
||||
@@ -994,7 +994,7 @@ void wxListBox::ApplyToolTip( GtkTooltips *tips, const wxChar *tip )
|
||||
GList *child = m_list->children;
|
||||
while (child)
|
||||
{
|
||||
gtk_tooltips_set_tip( tips, GTK_WIDGET( child->data ), wxConvCurrent->cWX2MB(tip), (gchar*) NULL );
|
||||
gtk_tooltips_set_tip( tips, GTK_WIDGET( child->data ), wxConvCurrent->cWX2MB(tip), NULL );
|
||||
child = child->next;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -181,10 +181,10 @@ void wxMenuBar::Init(size_t n, wxMenu *menus[], const wxString titles[], long st
|
||||
// the parent window is known after wxFrame::SetMenu()
|
||||
m_needParent = false;
|
||||
m_style = style;
|
||||
m_invokingWindow = (wxWindow*) NULL;
|
||||
m_invokingWindow = NULL;
|
||||
|
||||
if (!PreCreation( (wxWindow*) NULL, wxDefaultPosition, wxDefaultSize ) ||
|
||||
!CreateBase( (wxWindow*) NULL, -1, wxDefaultPosition, wxDefaultSize, style, wxDefaultValidator, wxT("menubar") ))
|
||||
if (!PreCreation( NULL, wxDefaultPosition, wxDefaultSize ) ||
|
||||
!CreateBase( NULL, -1, wxDefaultPosition, wxDefaultSize, style, wxDefaultValidator, wxT("menubar") ))
|
||||
{
|
||||
wxFAIL_MSG( wxT("wxMenuBar creation failed") );
|
||||
return;
|
||||
@@ -243,7 +243,7 @@ wxMenuBar::~wxMenuBar()
|
||||
|
||||
static void wxMenubarUnsetInvokingWindow( wxMenu *menu, wxWindow *win )
|
||||
{
|
||||
menu->SetInvokingWindow( (wxWindow*) NULL );
|
||||
menu->SetInvokingWindow( NULL );
|
||||
|
||||
wxWindow *top_frame = win;
|
||||
while (top_frame->GetParent() && !(top_frame->IsTopLevel()))
|
||||
@@ -308,7 +308,7 @@ void wxMenuBar::SetInvokingWindow( wxWindow *win )
|
||||
|
||||
void wxMenuBar::UnsetInvokingWindow( wxWindow *win )
|
||||
{
|
||||
m_invokingWindow = (wxWindow*) NULL;
|
||||
m_invokingWindow = NULL;
|
||||
wxWindow *top_frame = win;
|
||||
while (top_frame->GetParent() && !(top_frame->IsTopLevel()))
|
||||
top_frame = top_frame->GetParent();
|
||||
@@ -410,7 +410,7 @@ wxMenu *wxMenuBar::Replace(size_t pos, wxMenu *menu, const wxString& title)
|
||||
wxMenu *menuOld = Remove(pos);
|
||||
if ( menuOld && !Insert(pos, menu, title) )
|
||||
{
|
||||
return (wxMenu*) NULL;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// either Insert() succeeded or Remove() failed and menuOld is NULL
|
||||
@@ -421,7 +421,7 @@ wxMenu *wxMenuBar::Remove(size_t pos)
|
||||
{
|
||||
wxMenu *menu = wxMenuBarBase::Remove(pos);
|
||||
if ( !menu )
|
||||
return (wxMenu*) NULL;
|
||||
return NULL;
|
||||
|
||||
gtk_menu_item_remove_submenu( GTK_MENU_ITEM(menu->m_owner) );
|
||||
gtk_container_remove(GTK_CONTAINER(m_menubar), menu->m_owner);
|
||||
@@ -510,7 +510,7 @@ wxMenuItem* wxMenuBar::FindItem( int id, wxMenu **menuForItem ) const
|
||||
|
||||
if ( menuForItem )
|
||||
{
|
||||
*menuForItem = result ? result->GetMenu() : (wxMenu *)NULL;
|
||||
*menuForItem = result ? result->GetMenu() : NULL;
|
||||
}
|
||||
|
||||
return result;
|
||||
@@ -740,8 +740,8 @@ wxMenuItem::wxMenuItem(wxMenu *parentMenu,
|
||||
|
||||
void wxMenuItem::Init()
|
||||
{
|
||||
m_labelWidget = (GtkWidget *) NULL;
|
||||
m_menuItem = (GtkWidget *) NULL;
|
||||
m_labelWidget = NULL;
|
||||
m_menuItem = NULL;
|
||||
|
||||
DoSetText(m_text);
|
||||
}
|
||||
@@ -872,7 +872,7 @@ wxAcceleratorEntry *wxMenuItem::GetAccel() const
|
||||
if ( !GetHotKey() )
|
||||
{
|
||||
// nothing
|
||||
return (wxAcceleratorEntry *)NULL;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// accelerator parsing code looks for them after a TAB, so insert a dummy
|
||||
@@ -938,7 +938,7 @@ void wxMenu::Init()
|
||||
// our back by GTK+ e.g. when it is removed from menubar:
|
||||
gtk_widget_ref(m_menu);
|
||||
|
||||
m_owner = (GtkWidget*) NULL;
|
||||
m_owner = NULL;
|
||||
|
||||
// Tearoffs are entries, just like separators. So if we want this
|
||||
// menu to be a tear-off one, we just append a tearoff entry
|
||||
@@ -1151,7 +1151,7 @@ wxMenuItem* wxMenu::DoInsert(size_t pos, wxMenuItem *item)
|
||||
wxMenuItem *wxMenu::DoRemove(wxMenuItem *item)
|
||||
{
|
||||
if ( !wxMenuBase::DoRemove(item) )
|
||||
return (wxMenuItem *)NULL;
|
||||
return NULL;
|
||||
|
||||
// TODO: this code doesn't delete the item factory item and this seems
|
||||
// impossible as of GTK 1.2.6.
|
||||
@@ -1535,8 +1535,8 @@ bool wxWindowGTK::DoPopupMenu( wxMenu *menu, int x, int y )
|
||||
|
||||
gtk_menu_popup(
|
||||
GTK_MENU(menu->m_menu),
|
||||
(GtkWidget *) NULL, // parent menu shell
|
||||
(GtkWidget *) NULL, // parent menu item
|
||||
NULL, // parent menu shell
|
||||
NULL, // parent menu item
|
||||
posfunc, // function to position it
|
||||
userdata, // client data
|
||||
0, // button used to activate it
|
||||
|
||||
@@ -192,8 +192,8 @@ static gint gtk_window_button_press_callback( GtkWidget *widget, GdkEventButton
|
||||
GDK_POINTER_MOTION_HINT_MASK |
|
||||
GDK_BUTTON_MOTION_MASK |
|
||||
GDK_BUTTON1_MOTION_MASK),
|
||||
(GdkWindow *) NULL,
|
||||
(GdkCursor *) NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
(unsigned int) GDK_CURRENT_TIME );
|
||||
|
||||
win->m_diffX = (int)gdk_event->x;
|
||||
@@ -350,7 +350,7 @@ bool wxMiniFrame::Create( wxWindow *parent, wxWindowID id, const wxString &title
|
||||
if ((style & wxSYSTEM_MENU) &&
|
||||
((style & wxCAPTION) || (style & wxTINY_CAPTION_HORIZ) || (style & wxTINY_CAPTION_VERT)))
|
||||
{
|
||||
GdkBitmap *mask = (GdkBitmap*) NULL;
|
||||
GdkBitmap *mask = NULL;
|
||||
GdkPixmap *pixmap = gdk_pixmap_create_from_xpm_d
|
||||
(
|
||||
wxGetRootWindow()->window,
|
||||
@@ -401,7 +401,7 @@ void wxMiniFrame::SetTitle( const wxString &title )
|
||||
{
|
||||
wxFrame::SetTitle( title );
|
||||
|
||||
gtk_widget_draw( m_mainWidget, (GdkRectangle*) NULL );
|
||||
gtk_widget_draw( m_mainWidget, NULL );
|
||||
}
|
||||
|
||||
#endif // wxUSE_MINIFRAME
|
||||
|
||||
@@ -61,8 +61,8 @@ public:
|
||||
wxGtkNotebookPage()
|
||||
{
|
||||
m_image = -1;
|
||||
m_page = (GtkNotebookPage *) NULL;
|
||||
m_box = (GtkWidget *) NULL;
|
||||
m_page = NULL;
|
||||
m_box = NULL;
|
||||
}
|
||||
|
||||
wxString m_text;
|
||||
@@ -291,7 +291,7 @@ void wxNotebook::Init()
|
||||
m_padding = 0;
|
||||
m_inSwitchPage = false;
|
||||
|
||||
m_imageList = (wxImageList *) NULL;
|
||||
m_imageList = NULL;
|
||||
m_selection = -1;
|
||||
m_themeEnabled = true;
|
||||
}
|
||||
@@ -408,9 +408,9 @@ int wxNotebook::GetPageImage( size_t page ) const
|
||||
|
||||
wxGtkNotebookPage* wxNotebook::GetNotebookPage( int page ) const
|
||||
{
|
||||
wxCHECK_MSG( m_widget != NULL, (wxGtkNotebookPage*) NULL, wxT("invalid notebook") );
|
||||
wxCHECK_MSG( m_widget != NULL, NULL, wxT("invalid notebook") );
|
||||
|
||||
wxCHECK_MSG( page < (int)m_pagesData.GetCount(), (wxGtkNotebookPage*) NULL, wxT("invalid notebook index") );
|
||||
wxCHECK_MSG( page < (int)m_pagesData.GetCount(), NULL, wxT("invalid notebook index") );
|
||||
|
||||
return m_pagesData.Item(page)->GetData();
|
||||
}
|
||||
@@ -485,7 +485,7 @@ bool wxNotebook::SetPageImage( size_t page, int image )
|
||||
if (image == -1 && nb_page->m_image == -1)
|
||||
return true; /* Case 1): Nothing to do. */
|
||||
|
||||
GtkWidget *pixmapwid = (GtkWidget*) NULL;
|
||||
GtkWidget *pixmapwid = NULL;
|
||||
|
||||
if (nb_page->m_image != -1)
|
||||
{
|
||||
@@ -521,7 +521,7 @@ bool wxNotebook::SetPageImage( size_t page, int image )
|
||||
/* Construct the new pixmap */
|
||||
const wxBitmap *bmp = m_imageList->GetBitmapPtr(image);
|
||||
GdkPixmap *pixmap = bmp->GetPixmap();
|
||||
GdkBitmap *mask = (GdkBitmap*) NULL;
|
||||
GdkBitmap *mask = NULL;
|
||||
if ( bmp->GetMask() )
|
||||
{
|
||||
mask = bmp->GetMask()->GetBitmap();
|
||||
@@ -689,7 +689,7 @@ bool wxNotebook::InsertPage( size_t position,
|
||||
|
||||
const wxBitmap *bmp = m_imageList->GetBitmapPtr(imageId);
|
||||
GdkPixmap *pixmap = bmp->GetPixmap();
|
||||
GdkBitmap *mask = (GdkBitmap*) NULL;
|
||||
GdkBitmap *mask = NULL;
|
||||
if ( bmp->GetMask() )
|
||||
{
|
||||
mask = bmp->GetMask()->GetBitmap();
|
||||
|
||||
@@ -31,7 +31,7 @@ public:
|
||||
m_style = wxPENSTYLE_SOLID;
|
||||
m_joinStyle = wxJOIN_ROUND;
|
||||
m_capStyle = wxCAP_ROUND;
|
||||
m_dash = (wxGTKDash*) NULL;
|
||||
m_dash = NULL;
|
||||
m_countDashes = 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -328,7 +328,7 @@ void wxPopupWindow::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y), int width, int
|
||||
geom.max_width = m_width;
|
||||
geom.max_height = m_height;
|
||||
gtk_window_set_geometry_hints( GTK_WINDOW(m_widget),
|
||||
(GtkWidget*) NULL,
|
||||
NULL,
|
||||
&geom,
|
||||
(GdkWindowHints) flag );
|
||||
|
||||
|
||||
@@ -216,7 +216,7 @@ bool wxRadioBox::Create( wxWindow *parent, wxWindowID id, const wxString& title,
|
||||
unsigned int num_of_cols = GetColumnCount();
|
||||
unsigned int num_of_rows = GetRowCount();
|
||||
|
||||
GtkRadioButton *m_radio = (GtkRadioButton*) NULL;
|
||||
GtkRadioButton *m_radio = NULL;
|
||||
|
||||
GtkWidget *table = gtk_table_new( num_of_rows, num_of_cols, FALSE );
|
||||
gtk_table_set_col_spacings( GTK_TABLE(table), 1 );
|
||||
@@ -225,7 +225,7 @@ bool wxRadioBox::Create( wxWindow *parent, wxWindowID id, const wxString& title,
|
||||
gtk_container_add( GTK_CONTAINER(m_widget), table );
|
||||
|
||||
wxString label;
|
||||
GSList *radio_button_group = (GSList *) NULL;
|
||||
GSList *radio_button_group = NULL;
|
||||
for (int i = 0; i < n; i++)
|
||||
{
|
||||
if ( i != 0 )
|
||||
@@ -551,7 +551,7 @@ void wxRadioBox::ApplyToolTip( GtkTooltips *tips, const wxChar *tip )
|
||||
while (node)
|
||||
{
|
||||
GtkWidget *widget = GTK_WIDGET( node->GetData() );
|
||||
gtk_tooltips_set_tip( tips, widget, wxConvCurrent->cWX2MB(tip), (gchar*) NULL );
|
||||
gtk_tooltips_set_tip( tips, widget, wxConvCurrent->cWX2MB(tip), NULL );
|
||||
node = node->GetNext();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -87,7 +87,7 @@ bool wxRadioButton::Create( wxWindow *parent,
|
||||
if (!HasFlag(wxRB_GROUP))
|
||||
{
|
||||
// search backward for last group start
|
||||
wxRadioButton *chief = (wxRadioButton*) NULL;
|
||||
wxRadioButton *chief = NULL;
|
||||
wxWindowList::compatibility_iterator node = parent->GetChildren().GetLast();
|
||||
while (node)
|
||||
{
|
||||
|
||||
@@ -355,7 +355,7 @@ wxRegionContain wxRegion::DoContainsRect(const wxRect& r) const
|
||||
GdkRegion *wxRegion::GetRegion() const
|
||||
{
|
||||
if (!m_refData)
|
||||
return (GdkRegion*) NULL;
|
||||
return NULL;
|
||||
|
||||
return M_REGIONDATA->m_region;
|
||||
}
|
||||
|
||||
@@ -287,7 +287,7 @@ wxRendererGTK::DrawSplitterSash(wxWindow *win,
|
||||
GTK_PIZZA(win->m_wxwindow)->bin_window,
|
||||
GTK_STATE_NORMAL,
|
||||
GTK_SHADOW_OUT,
|
||||
(GdkRectangle*) NULL,
|
||||
NULL,
|
||||
win->m_wxwindow,
|
||||
(char *)"paned", // const_cast
|
||||
isVert ? position : size.x - 2*SASH_SIZE,
|
||||
|
||||
@@ -188,9 +188,9 @@ bool wxScrollBar::Create(wxWindow *parent, wxWindowID id,
|
||||
m_oldPos = 0.0;
|
||||
|
||||
if ((style & wxSB_VERTICAL) == wxSB_VERTICAL)
|
||||
m_widget = gtk_vscrollbar_new( (GtkAdjustment *) NULL );
|
||||
m_widget = gtk_vscrollbar_new( NULL );
|
||||
else
|
||||
m_widget = gtk_hscrollbar_new( (GtkAdjustment *) NULL );
|
||||
m_widget = gtk_hscrollbar_new( NULL );
|
||||
|
||||
m_adjust = gtk_range_get_adjustment( GTK_RANGE(m_widget) );
|
||||
|
||||
|
||||
@@ -145,9 +145,9 @@ bool wxSlider::Create(wxWindow *parent, wxWindowID id,
|
||||
m_oldPos = 0.0;
|
||||
|
||||
if (style & wxSL_VERTICAL)
|
||||
m_widget = gtk_vscale_new( (GtkAdjustment *) NULL );
|
||||
m_widget = gtk_vscale_new( NULL );
|
||||
else
|
||||
m_widget = gtk_hscale_new( (GtkAdjustment *) NULL );
|
||||
m_widget = gtk_hscale_new( NULL );
|
||||
|
||||
if (style & wxSL_LABELS)
|
||||
{
|
||||
|
||||
@@ -74,7 +74,7 @@ void wxStaticBitmap::SetBitmap( const wxBitmap &bitmap )
|
||||
|
||||
if (m_bitmap.Ok())
|
||||
{
|
||||
GdkBitmap *mask = (GdkBitmap *) NULL;
|
||||
GdkBitmap *mask = NULL;
|
||||
if (m_bitmap.GetMask())
|
||||
mask = m_bitmap.GetMask()->GetBitmap();
|
||||
|
||||
|
||||
@@ -125,7 +125,7 @@ public:
|
||||
if (bitmap.Ok())
|
||||
{
|
||||
GdkBitmap *mask = bitmap.GetMask() ? bitmap.GetMask()->GetBitmap()
|
||||
: (GdkBitmap *)NULL;
|
||||
: NULL;
|
||||
gtk_pixmap_set( GTK_PIXMAP(m_pixmap), bitmap.GetPixmap(), mask );
|
||||
}
|
||||
}
|
||||
@@ -230,7 +230,7 @@ static void wxInsertChildInToolBar( wxToolBar* WXUNUSED(parent),
|
||||
void wxToolBarTool::Init()
|
||||
{
|
||||
m_item =
|
||||
m_pixmap = (GtkWidget *)NULL;
|
||||
m_pixmap = NULL;
|
||||
}
|
||||
|
||||
wxToolBarToolBase *wxToolBar::CreateTool(int id,
|
||||
@@ -258,7 +258,7 @@ wxToolBar::CreateTool(wxControl *control, const wxString& label)
|
||||
|
||||
void wxToolBar::Init()
|
||||
{
|
||||
m_toolbar = (GtkToolbar *)NULL;
|
||||
m_toolbar = NULL;
|
||||
m_blockEvent = false;
|
||||
m_defaultWidth = 32;
|
||||
m_defaultHeight = 32;
|
||||
@@ -366,11 +366,11 @@ bool wxToolBar::DoInsertTool(size_t pos, wxToolBarToolBase *toolBase)
|
||||
wxCHECK_MSG( bitmap.GetPixmap() != NULL, false,
|
||||
wxT("wxToolBar::Add needs a wxBitmap") );
|
||||
|
||||
GtkWidget *tool_pixmap = (GtkWidget *)NULL;
|
||||
GtkWidget *tool_pixmap = NULL;
|
||||
|
||||
GdkPixmap *pixmap = bitmap.GetPixmap();
|
||||
|
||||
GdkBitmap *mask = (GdkBitmap *)NULL;
|
||||
GdkBitmap *mask = NULL;
|
||||
if ( bitmap.GetMask() )
|
||||
mask = bitmap.GetMask()->GetBitmap();
|
||||
|
||||
@@ -556,7 +556,7 @@ wxToolBarToolBase *wxToolBar::FindToolForPosition(wxCoord WXUNUSED(x),
|
||||
// VZ: GTK+ doesn't seem to have such thing
|
||||
wxFAIL_MSG( _T("wxToolBar::FindToolForPosition() not implemented") );
|
||||
|
||||
return (wxToolBarToolBase *)NULL;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void wxToolBar::SetMargins( int x, int y )
|
||||
|
||||
@@ -223,7 +223,7 @@ void wxTextCtrl::Init()
|
||||
m_modified = false;
|
||||
SetUpdateFont(false);
|
||||
m_text =
|
||||
m_vScrollbar = (GtkWidget *)NULL;
|
||||
m_vScrollbar = NULL;
|
||||
}
|
||||
|
||||
wxTextCtrl::~wxTextCtrl()
|
||||
@@ -271,7 +271,7 @@ bool wxTextCtrl::Create( wxWindow *parent,
|
||||
if (multi_line)
|
||||
{
|
||||
// create our control ...
|
||||
m_text = gtk_text_new( (GtkAdjustment *) NULL, (GtkAdjustment *) NULL );
|
||||
m_text = gtk_text_new( NULL, NULL );
|
||||
|
||||
// ... and put into the upper left hand corner of the table
|
||||
bool bHasHScrollbar = false;
|
||||
@@ -1246,7 +1246,7 @@ void wxTextCtrl::OnInternalIdle()
|
||||
|
||||
if (cursor.Ok())
|
||||
{
|
||||
GdkWindow *window = (GdkWindow*) NULL;
|
||||
GdkWindow *window = NULL;
|
||||
if (HasFlag(wxTE_MULTILINE))
|
||||
window = GTK_TEXT(m_text)->text_area;
|
||||
else
|
||||
|
||||
@@ -136,7 +136,7 @@ void wxToggleBitmapButton::OnSetBitmap()
|
||||
{
|
||||
if (!m_bitmap.Ok()) return;
|
||||
|
||||
GdkBitmap *mask = (GdkBitmap *) NULL;
|
||||
GdkBitmap *mask = NULL;
|
||||
if (m_bitmap.GetMask()) mask = m_bitmap.GetMask()->GetBitmap();
|
||||
|
||||
GtkWidget *child = BUTTON_CHILD(m_widget);
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
// global data
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
static GtkTooltips *ss_tooltips = (GtkTooltips*) NULL;
|
||||
static GtkTooltips *ss_tooltips = NULL;
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// wxToolTip
|
||||
@@ -35,7 +35,7 @@ IMPLEMENT_ABSTRACT_CLASS(wxToolTip, wxObject)
|
||||
wxToolTip::wxToolTip( const wxString &tip )
|
||||
{
|
||||
m_text = tip;
|
||||
m_window = (wxWindow*) NULL;
|
||||
m_window = NULL;
|
||||
}
|
||||
|
||||
void wxToolTip::SetTip( const wxString &tip )
|
||||
@@ -56,7 +56,7 @@ void wxToolTip::Apply( wxWindow *win )
|
||||
m_window = win;
|
||||
|
||||
if (m_text.empty())
|
||||
m_window->ApplyToolTip( ss_tooltips, (wxChar*) NULL );
|
||||
m_window->ApplyToolTip( ss_tooltips, NULL );
|
||||
else
|
||||
m_window->ApplyToolTip( ss_tooltips, m_text );
|
||||
}
|
||||
|
||||
@@ -66,8 +66,8 @@ extern wxWindowGTK *g_delayedFocus;
|
||||
|
||||
// the frame that is currently active (i.e. its child has focus). It is
|
||||
// used to generate wxActivateEvents
|
||||
static wxTopLevelWindowGTK *g_activeFrame = (wxTopLevelWindowGTK*) NULL;
|
||||
static wxTopLevelWindowGTK *g_lastActiveFrame = (wxTopLevelWindowGTK*) NULL;
|
||||
static wxTopLevelWindowGTK *g_activeFrame = NULL;
|
||||
static wxTopLevelWindowGTK *g_lastActiveFrame = NULL;
|
||||
|
||||
// if we detect that the app has got/lost the focus, we set this variable to
|
||||
// either TRUE or FALSE and an activate event will be sent during the next
|
||||
@@ -455,7 +455,7 @@ void wxTopLevelWindowGTK::Init()
|
||||
m_sizeSet = false;
|
||||
m_miniEdge = 0;
|
||||
m_miniTitle = 0;
|
||||
m_mainWidget = (GtkWidget*) NULL;
|
||||
m_mainWidget = NULL;
|
||||
m_insertInClientArea = true;
|
||||
m_isIconized = false;
|
||||
m_fsIsShowing = false;
|
||||
@@ -990,7 +990,7 @@ void wxTopLevelWindowGTK::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
|
||||
: maxHeight ;
|
||||
|
||||
gtk_window_set_geometry_hints( GTK_WINDOW(m_widget),
|
||||
(GtkWidget*) NULL,
|
||||
NULL,
|
||||
&geom,
|
||||
(GdkWindowHints) flag );
|
||||
|
||||
@@ -1103,10 +1103,10 @@ void wxTopLevelWindowGTK::SetIcons( const wxIconBundle &icons )
|
||||
if (icon.Ok())
|
||||
{
|
||||
wxMask *mask = icon.GetMask();
|
||||
GdkBitmap *bm = (GdkBitmap *) NULL;
|
||||
GdkBitmap *bm = NULL;
|
||||
if (mask) bm = mask->GetBitmap();
|
||||
|
||||
gdk_window_set_icon( m_widget->window, (GdkWindow *) NULL, icon.GetPixmap(), bm );
|
||||
gdk_window_set_icon( m_widget->window, NULL, icon.GetPixmap(), bm );
|
||||
}
|
||||
|
||||
wxSetIconsX11( (WXDisplay*)GDK_WINDOW_XDISPLAY( window ),
|
||||
|
||||
@@ -106,7 +106,7 @@ void wxDisplaySizeMM( int *width, int *height )
|
||||
|
||||
void wxGetMousePosition( int* x, int* y )
|
||||
{
|
||||
gdk_window_get_pointer( (GdkWindow*) NULL, x, y, (GdkModifierType*) NULL );
|
||||
gdk_window_get_pointer( NULL, x, y, NULL );
|
||||
}
|
||||
|
||||
bool wxColourDisplay()
|
||||
|
||||
@@ -207,19 +207,19 @@ static GdkGC *g_eraseGC = NULL;
|
||||
|
||||
// mouse capture state: the window which has it and if the mouse is currently
|
||||
// inside it
|
||||
static wxWindowGTK *g_captureWindow = (wxWindowGTK*) NULL;
|
||||
static wxWindowGTK *g_captureWindow = NULL;
|
||||
static bool g_captureWindowHasMouse = false;
|
||||
|
||||
wxWindowGTK *g_focusWindow = (wxWindowGTK*) NULL;
|
||||
wxWindowGTK *g_focusWindow = NULL;
|
||||
|
||||
// the last window which had the focus - this is normally never NULL (except
|
||||
// if we never had focus at all) as even when g_focusWindow is NULL it still
|
||||
// keeps its previous value
|
||||
wxWindowGTK *g_focusWindowLast = (wxWindowGTK*) NULL;
|
||||
wxWindowGTK *g_focusWindowLast = NULL;
|
||||
|
||||
// If a window get the focus set but has not been realized
|
||||
// yet, defer setting the focus to idle time.
|
||||
wxWindowGTK *g_delayedFocus = (wxWindowGTK*) NULL;
|
||||
wxWindowGTK *g_delayedFocus = NULL;
|
||||
|
||||
// hack: we need something to pass to gtk_menu_popup, so we store the time of
|
||||
// the last click here (extern: used from gtk/menu.cpp)
|
||||
@@ -227,7 +227,7 @@ guint32 wxGtkTimeLastClick = 0;
|
||||
|
||||
// global variables because GTK+ DnD want to have the
|
||||
// mouse event that caused it
|
||||
GdkEvent *g_lastMouseEvent = (GdkEvent*) NULL;
|
||||
GdkEvent *g_lastMouseEvent = NULL;
|
||||
int g_lastButtonNumber = 0;
|
||||
|
||||
extern bool g_mainThreadLocked;
|
||||
@@ -294,7 +294,7 @@ wxWindow *wxFindFocusedChild(wxWindowGTK *win)
|
||||
{
|
||||
wxWindow *winFocus = wxWindowGTK::FindFocus();
|
||||
if ( !winFocus )
|
||||
return (wxWindow *)NULL;
|
||||
return NULL;
|
||||
|
||||
if ( winFocus == win )
|
||||
return (wxWindow *)win;
|
||||
@@ -308,7 +308,7 @@ wxWindow *wxFindFocusedChild(wxWindowGTK *win)
|
||||
return child;
|
||||
}
|
||||
|
||||
return (wxWindow *)NULL;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static void draw_frame( GtkWidget *widget, wxWindowGTK *win )
|
||||
@@ -611,7 +611,7 @@ static void gtk_window_draw_callback( GtkWidget *widget,
|
||||
GdkRectangle child_area;
|
||||
if (gtk_widget_intersect (child->widget, rect, &child_area))
|
||||
{
|
||||
gtk_widget_draw (child->widget, &child_area /* (GdkRectangle*) NULL*/ );
|
||||
gtk_widget_draw (child->widget, &child_area /* NULL*/ );
|
||||
}
|
||||
}
|
||||
#endif
|
||||
@@ -1433,7 +1433,7 @@ wxWindowGTK *FindWindowForMouseEvent(wxWindowGTK *win, wxCoord& x, wxCoord& y)
|
||||
}
|
||||
else
|
||||
{
|
||||
if ((child->m_wxwindow == (GtkWidget*) NULL) &&
|
||||
if ((child->m_wxwindow == NULL) &&
|
||||
(child->m_x <= xx) &&
|
||||
(child->m_y <= yy) &&
|
||||
(child->m_x+child->m_width >= xx) &&
|
||||
@@ -1879,7 +1879,7 @@ static gint gtk_window_focus_out_callback( GtkWidget *WXUNUSED(widget),
|
||||
if ( winFocus )
|
||||
win = winFocus;
|
||||
|
||||
g_focusWindow = (wxWindowGTK *)NULL;
|
||||
g_focusWindow = NULL;
|
||||
|
||||
#ifdef HAVE_XIM
|
||||
if (win->m_ic)
|
||||
@@ -2424,9 +2424,9 @@ wxMouseState wxGetMouseState()
|
||||
void wxWindowGTK::Init()
|
||||
{
|
||||
// GTK specific
|
||||
m_widget = (GtkWidget *) NULL;
|
||||
m_wxwindow = (GtkWidget *) NULL;
|
||||
m_focusWidget = (GtkWidget *) NULL;
|
||||
m_widget = NULL;
|
||||
m_wxwindow = NULL;
|
||||
m_focusWidget = NULL;
|
||||
|
||||
// position/size
|
||||
m_x = 0;
|
||||
@@ -2445,8 +2445,8 @@ void wxWindowGTK::Init()
|
||||
m_hasScrolling = false;
|
||||
m_isScrolling = false;
|
||||
|
||||
m_hAdjust = (GtkAdjustment*) NULL;
|
||||
m_vAdjust = (GtkAdjustment*) NULL;
|
||||
m_hAdjust = NULL;
|
||||
m_vAdjust = NULL;
|
||||
m_oldHorizontalPos =
|
||||
m_oldVerticalPos = 0.0;
|
||||
m_oldClientWidth =
|
||||
@@ -2466,8 +2466,8 @@ void wxWindowGTK::Init()
|
||||
m_cursor = *wxSTANDARD_CURSOR;
|
||||
|
||||
#ifdef HAVE_XIM
|
||||
m_ic = (GdkIC*) NULL;
|
||||
m_icattr = (GdkICAttr*) NULL;
|
||||
m_ic = NULL;
|
||||
m_icattr = NULL;
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -2509,7 +2509,7 @@ bool wxWindowGTK::Create( wxWindow *parent,
|
||||
|
||||
m_insertCallback = wxInsertChildInWindow;
|
||||
|
||||
m_widget = gtk_scrolled_window_new( (GtkAdjustment *) NULL, (GtkAdjustment *) NULL );
|
||||
m_widget = gtk_scrolled_window_new( NULL, NULL );
|
||||
GTK_WIDGET_UNSET_FLAGS( m_widget, GTK_CAN_FOCUS );
|
||||
|
||||
GtkScrolledWindow *scrolledWindow = GTK_SCROLLED_WINDOW(m_widget);
|
||||
@@ -2642,13 +2642,13 @@ wxWindowGTK::~wxWindowGTK()
|
||||
if (m_wxwindow)
|
||||
{
|
||||
gtk_widget_destroy( m_wxwindow );
|
||||
m_wxwindow = (GtkWidget*) NULL;
|
||||
m_wxwindow = NULL;
|
||||
}
|
||||
|
||||
if (m_widget)
|
||||
{
|
||||
gtk_widget_destroy( m_widget );
|
||||
m_widget = (GtkWidget*) NULL;
|
||||
m_widget = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3138,7 +3138,7 @@ void wxWindowGTK::DoClientToScreen( int *x, int *y ) const
|
||||
|
||||
if (!m_widget->window) return;
|
||||
|
||||
GdkWindow *source = (GdkWindow *) NULL;
|
||||
GdkWindow *source = NULL;
|
||||
if (m_wxwindow)
|
||||
source = GTK_PIZZA(m_wxwindow)->bin_window;
|
||||
else
|
||||
@@ -3167,7 +3167,7 @@ void wxWindowGTK::DoScreenToClient( int *x, int *y ) const
|
||||
|
||||
if (!m_widget->window) return;
|
||||
|
||||
GdkWindow *source = (GdkWindow *) NULL;
|
||||
GdkWindow *source = NULL;
|
||||
if (m_wxwindow)
|
||||
source = GTK_PIZZA(m_wxwindow)->bin_window;
|
||||
else
|
||||
@@ -3431,7 +3431,7 @@ void wxWindowGTK::WarpPointer( int x, int y )
|
||||
// We provide this function ourselves as it is
|
||||
// missing in GDK (top of this file).
|
||||
|
||||
GdkWindow *window = (GdkWindow*) NULL;
|
||||
GdkWindow *window = NULL;
|
||||
if (m_wxwindow)
|
||||
window = GTK_PIZZA(m_wxwindow)->bin_window;
|
||||
else
|
||||
@@ -3505,7 +3505,7 @@ void wxWindowGTK::Refresh( bool eraseBackground, const wxRect *rect )
|
||||
}
|
||||
else
|
||||
{
|
||||
gtk_widget_draw( m_widget, (GdkRectangle*) NULL );
|
||||
gtk_widget_draw( m_widget, NULL );
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3695,7 +3695,7 @@ void wxWindowGTK::DoSetToolTip( wxToolTip *tip )
|
||||
void wxWindowGTK::ApplyToolTip( GtkTooltips *tips, const wxChar *tip )
|
||||
{
|
||||
wxString tmp( tip );
|
||||
gtk_tooltips_set_tip( tips, GetConnectWidget(), wxGTK_CONV(tmp), (gchar*) NULL );
|
||||
gtk_tooltips_set_tip( tips, GetConnectWidget(), wxGTK_CONV(tmp), NULL );
|
||||
}
|
||||
#endif // wxUSE_TOOLTIPS
|
||||
|
||||
@@ -3829,7 +3829,7 @@ bool wxWindowGTK::SetBackgroundStyle(wxBackgroundStyle style)
|
||||
|
||||
if (style == wxBG_STYLE_CUSTOM)
|
||||
{
|
||||
GdkWindow *window = (GdkWindow*) NULL;
|
||||
GdkWindow *window = NULL;
|
||||
if (m_wxwindow)
|
||||
window = GTK_PIZZA(m_wxwindow)->bin_window;
|
||||
else
|
||||
@@ -3913,7 +3913,7 @@ void wxWindowGTK::DoCaptureMouse()
|
||||
{
|
||||
wxCHECK_RET( m_widget != NULL, wxT("invalid window") );
|
||||
|
||||
GdkWindow *window = (GdkWindow*) NULL;
|
||||
GdkWindow *window = NULL;
|
||||
if (m_wxwindow)
|
||||
window = GTK_PIZZA(m_wxwindow)->bin_window;
|
||||
else
|
||||
@@ -3931,7 +3931,7 @@ void wxWindowGTK::DoCaptureMouse()
|
||||
GDK_BUTTON_RELEASE_MASK |
|
||||
GDK_POINTER_MOTION_HINT_MASK |
|
||||
GDK_POINTER_MOTION_MASK),
|
||||
(GdkWindow *) NULL,
|
||||
NULL,
|
||||
cursor->GetCursor(),
|
||||
(guint32)GDK_CURRENT_TIME );
|
||||
g_captureWindow = this;
|
||||
@@ -3944,9 +3944,9 @@ void wxWindowGTK::DoReleaseMouse()
|
||||
|
||||
wxCHECK_RET( g_captureWindow, wxT("can't release mouse - not captured") );
|
||||
|
||||
g_captureWindow = (wxWindowGTK*) NULL;
|
||||
g_captureWindow = NULL;
|
||||
|
||||
GdkWindow *window = (GdkWindow*) NULL;
|
||||
GdkWindow *window = NULL;
|
||||
if (m_wxwindow)
|
||||
window = GTK_PIZZA(m_wxwindow)->bin_window;
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user