bool verbose)
{
- bool bResult = FALSE;
//sanity check; icon must be less than 127 pixels high and 255 wide
if ( image->GetHeight () > 127 )
{
//calculate size and offset of image and mask
wxCountingOutputStream cStream;
- bResult = SaveDib(image, cStream, verbose, IsBmp, IsMask);
+ bool bResult = SaveDib(image, cStream, verbose, IsBmp, IsMask);
if ( !bResult )
{
if ( verbose )
bool wxICOHandler::DoLoadFile(wxImage *image, wxInputStream& stream,
bool WXUNUSED(verbose), int index)
{
- bool bResult = FALSE;
- bool IsBmp = FALSE;
+ bool bResult wxDUMMY_INITIALIZE(false);
+ bool IsBmp = false;
ICONDIR IconDir;
if ( iSel == wxNOT_FOUND || iSel < 0 || iSel >= nIcons )
{
wxLogError(_("ICO: Invalid icon index."));
- bResult = FALSE;
+ bResult = false;
}
else
{
bool success = ::ChooseColor(&(chooseColorStruct)) != 0;
// Try to highlight the correct window (the parent)
- HWND hWndParent = 0;
if (GetParent())
{
- hWndParent = (HWND) GetParent()->GetHWND();
+ HWND hWndParent = (HWND) GetParent()->GetHWND();
if (hWndParent)
::BringWindowToTop(hWndParent);
}
WXLPARAM lParam,
WXLPARAM* result)
{
- wxEventType eventType = wxEVT_NULL;
+ wxEventType eventType wxDUMMY_INITIALIZE(wxEVT_NULL);
NMHDR *hdr = (NMHDR*) lParam;
switch ( hdr->code )
ImageList_Destroy(GetHimageList());
m_hImageList = 0;
- UINT flags = 0 ;
#ifdef __WXWINCE__
- flags = ILC_COLOR;
+ UNIT flags = ILC_COLOR;
#else
+ UINT flags wxDUMMY_INITIALIZE(0) ;
if (image.GetDepth() <= 4)
flags = ILC_COLOR4;
else if (image.GetDepth() <= 8)
ImageList_Destroy(GetHimageList());
m_hImageList = 0;
- UINT flags = 0 ;
#ifdef __WXWINCE__
- flags = ILC_COLOR;
+ UINT flags = ILC_COLOR;
#else
+ UINT flags wxDUMMY_INITIALIZE(0) ;
if (image.GetDepth() <= 4)
flags = ILC_COLOR4;
else if (image.GetDepth() <= 8)
wxWindowID id,
const wxString& name)
{
- wxStatusBar *statusBar = NULL;
+ wxStatusBar *statusBar wxDUMMY_INITIALIZE(NULL);
#if wxUSE_NATIVE_STATUSBAR
if ( !UsesNativeStatusBar() )
// Optimise such that we don't have to always resize the toolbar
// when the frame changes, otherwise we'll get a lot of flicker.
- bool heightChanging = TRUE;
- bool widthChanging = TRUE;
+ bool heightChanging wxDUMMY_INITIALIZE(true);
+ bool widthChanging wxDUMMY_INITIALIZE(true);
if ( toolbar->GetWindowStyleFlag() & wxTB_VERTICAL )
{
if (m_AnyInternalData)
{
int n = GetItemCount();
- int i = 0;
m_ignoreChangeMessages = TRUE;
- for (i = 0; i < n; i++)
+ for (int i = 0; i < n; i++)
wxDeleteInternalData(this, i);
m_ignoreChangeMessages = FALSE;
wxSize clientSize = GetClientSize();
wxRect itemRect;
- int cy=0;
int itemCount = GetItemCount();
int i;
{
if (GetItemRect(i, itemRect))
{
- cy = itemRect.GetTop();
+ int cy = itemRect.GetTop();
if (i != 0) // Don't draw the first one
{
dc.DrawLine(0, cy, clientSize.x, cy);
m_printDialogData.SetMaxPage(9999);
// Create a suitable device context
- wxDC *dc = NULL;
+ wxDC *dc wxDUMMY_INITIALIZE(NULL);
if (prompt)
{
dc = PrintDialog(parent);
return false;
}
- int logPPIScreenX = 0;
- int logPPIScreenY = 0;
- int logPPIPrinterX = 0;
- int logPPIPrinterY = 0;
-
HDC hdc = ::GetDC(NULL);
- logPPIScreenX = ::GetDeviceCaps(hdc, LOGPIXELSX);
- logPPIScreenY = ::GetDeviceCaps(hdc, LOGPIXELSY);
+ int logPPIScreenX = ::GetDeviceCaps(hdc, LOGPIXELSX);
+ int logPPIScreenY = ::GetDeviceCaps(hdc, LOGPIXELSY);
::ReleaseDC(NULL, hdc);
- logPPIPrinterX = ::GetDeviceCaps((HDC) dc->GetHDC(), LOGPIXELSX);
- logPPIPrinterY = ::GetDeviceCaps((HDC) dc->GetHDC(), LOGPIXELSY);
+ int logPPIPrinterX = ::GetDeviceCaps((HDC) dc->GetHDC(), LOGPIXELSX);
+ int logPPIPrinterY = ::GetDeviceCaps((HDC) dc->GetHDC(), LOGPIXELSY);
if (logPPIPrinterX == 0 || logPPIPrinterY == 0)
{
delete dc;
wxPrinterDC printerDC(m_printDialogData.GetPrintData());
int printerWidth = 150;
- int printerHeight = 250;
+ int printerHeight wxDUMMY_INITIALIZE(250);
int printerXRes = 1500;
int printerYRes = 2500;
wxCHECK_MSG( radiobox, 0, wxT("radio button without radio box?") );
- bool processed = TRUE;
+ bool processed wxDUMMY_INITIALIZE(true);
// HELPINFO doesn't seem to be supported on WinCE.
#ifndef __WXWINCE__
processed = radiobox->GetEventHandler()->ProcessEvent(helpEvent);
}
else
- processed = FALSE;
+ processed = false;
#endif
if (processed)
return 0;
int position,
maxPos, trackPos = pos;
+ wxUnusedVar(trackPos);
+
// when we're dragging the scrollbar we can't use pos parameter because it
// is limited to 16 bits
// JACS: now always using GetScrollInfo, since there's no reason
minLabel.Printf(wxT("%d"), minValue);
wstyle = STATIC_FLAGS;
if ( m_windowStyle & wxCLIP_SIBLINGS )
- msStyle |= WS_CLIPSIBLINGS;
+ wstyle |= WS_CLIPSIBLINGS;
m_staticMin = (WXHWND) CreateWindowEx
(
0, wxT("STATIC"), minLabel,
wstyle = STATIC_FLAGS;
if ( m_windowStyle & wxCLIP_SIBLINGS )
- msStyle |= WS_CLIPSIBLINGS;
+ wstyle |= WS_CLIPSIBLINGS;
m_staticMax = (WXHWND) CreateWindowEx
(
// we may have either bitmap or icon: if a bitmap with mask is passed, we
// will transform it to an icon ourselves because otherwise the mask will
// be ignored by Windows
- wxGDIImage *image = (wxGDIImage *)NULL;
m_isIcon = bitmap.IsKindOf(CLASSINFO(wxIcon));
- image = ConvertImage( bitmap );
+ wxGDIImage *image = ConvertImage( bitmap );
m_isIcon = image->IsKindOf( CLASSINFO(wxIcon) );
// create the native control
bool wxTabCtrl::MSWOnNotify(int idCtrl, WXLPARAM lParam, WXLPARAM *result)
{
wxTabEvent event(wxEVT_NULL, m_windowId);
- wxEventType eventType = wxEVT_NULL;
+ wxEventType eventType wxDUMMY_INITIALIZE(wxEVT_NULL);
NMHDR* hdr1 = (NMHDR*) lParam;
switch ( hdr1->code )
{
point.y = y;
::ClientToScreen(hWnd, &point);
wxCurrentPopupMenu = menu;
+#if defined(__WXWINCE__)
UINT flags = 0;
-#if !defined(__WXWINCE__)
- flags = TPM_RIGHTBUTTON;
+#else
+ UINT flags = TPM_RIGHTBUTTON;
#endif
::TrackPopupMenu(hMenu, flags, point.x, point.y, 0, hWnd, NULL);