git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39354
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
+#include "wx/bmpbuttn.h"
+
- #include "wx/bmpbuttn.h"
#include "wx/log.h"
#endif
#include "wx/log.h"
#endif
#include "wx/intl.h"
#include "wx/log.h"
#include "wx/msgdlg.h"
#include "wx/intl.h"
#include "wx/log.h"
#include "wx/msgdlg.h"
+ #include "wx/bmpbuttn.h"
#endif
#include "wx/statline.h"
#include "wx/dirctrl.h"
#include "wx/generic/dirdlgg.h"
#include "wx/artprov.h"
#endif
#include "wx/statline.h"
#include "wx/dirctrl.h"
#include "wx/generic/dirdlgg.h"
#include "wx/artprov.h"
-#include "wx/bmpbuttn.h"
// ----------------------------------------------------------------------------
// constants
// ----------------------------------------------------------------------------
// constants
#include "wx/settings.h"
#include "wx/log.h"
#include "wx/msgdlg.h"
#include "wx/settings.h"
#include "wx/log.h"
#include "wx/msgdlg.h"
+ #include "wx/bmpbuttn.h"
#endif
#include "wx/checkbox.h"
#endif
#include "wx/checkbox.h"
#include "wx/stattext.h"
#include "wx/longlong.h"
#include "wx/sizer.h"
#include "wx/stattext.h"
#include "wx/longlong.h"
#include "wx/sizer.h"
-#include "wx/bmpbuttn.h"
#include "wx/tokenzr.h"
#include "wx/config.h"
#include "wx/imaglist.h"
#include "wx/tokenzr.h"
#include "wx/config.h"
#include "wx/imaglist.h"
+#include "wx/bmpbuttn.h"
+
- #include "wx/bmpbuttn.h"
#include "wx/log.h"
#include "wx/dcmemory.h"
#endif
#include "wx/log.h"
#include "wx/dcmemory.h"
#endif
/////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////
+// Name: src/os2/bmpbuttn.cpp
// Purpose: wxBitmapButton
// Author: David Webster
// Modified by:
// Purpose: wxBitmapButton
// Author: David Webster
// Modified by:
#endif
#include "wx/os2/private.h"
#endif
#include "wx/os2/private.h"
m_marginY = wxDEFAULT_BUTTON_MARGIN;
}
m_marginY = wxDEFAULT_BUTTON_MARGIN;
}
- int nX = rPos.x;
- int nY = rPos.y;
- int nWidth = rSize.x;
- int nHeight = rSize.y;
+ int nX = rPos.x;
+ int nY = rPos.y;
+ int nWidth = rSize.x;
+ int nHeight = rSize.y;
m_windowId = NewControlId();
else
m_windowId = vId;
m_windowId = NewControlId();
else
m_windowId = vId;
- if (nWidth == -1 && rBitmap.Ok())
+ if (nWidth == wxDefaultCoord && rBitmap.Ok())
nWidth = rBitmap.GetWidth() + 4 * m_marginX;
nWidth = rBitmap.GetWidth() + 4 * m_marginX;
- if (nHeight == -1 && rBitmap.Ok())
+ if (nHeight == wxDefaultCoord && rBitmap.Ok())
nHeight = rBitmap.GetHeight() + 4 * m_marginY;
ULONG ulOS2Style = WS_VISIBLE | WS_TABSTOP | BS_USERBUTTON;
nHeight = rBitmap.GetHeight() + 4 * m_marginY;
ULONG ulOS2Style = WS_VISIBLE | WS_TABSTOP | BS_USERBUTTON;
bool wxBitmapButton::OS2OnDraw( WXDRAWITEMSTRUCT* pItem)
{
bool wxBitmapButton::OS2OnDraw( WXDRAWITEMSTRUCT* pItem)
{
- PUSERBUTTON pUser = (PUSERBUTTON)pItem;
- bool bAutoDraw = (GetWindowStyleFlag() & wxBU_AUTODRAW) != 0;
+ PUSERBUTTON pUser = (PUSERBUTTON)pItem;
+ bool bAutoDraw = (GetWindowStyleFlag() & wxBU_AUTODRAW) != 0;
- wxBitmap* pBitmap;
- bool bIsSelected = pUser->fsState & BDS_HILITED;
- wxClientDC vDc(this);
+ wxBitmap* pBitmap;
+ bool bIsSelected = pUser->fsState & BDS_HILITED;
+ wxClientDC vDc(this);
if (bIsSelected && m_bmpSelected.Ok())
pBitmap = &m_bmpSelected;
if (bIsSelected && m_bmpSelected.Ok())
pBitmap = &m_bmpSelected;
pBitmap = &m_bmpNormal;
if (!pBitmap->Ok() )
pBitmap = &m_bmpNormal;
if (!pBitmap->Ok() )
+#include "wx/bmpbuttn.h"
+
- #include "wx/bmpbuttn.h"
#include "wx/log.h"
#include "wx/dcmemory.h"
#endif
#include "wx/log.h"
#include "wx/dcmemory.h"
#endif
}
#endif // wxUSE_BMPBUTTON
}
#endif // wxUSE_BMPBUTTON
/////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////
-// Name: univ/bmpbuttn.cpp
+// Name: src/univ/bmpbuttn.cpp
// Purpose: wxBitmapButton implementation
// Author: Vadim Zeitlin
// Modified by:
// Purpose: wxBitmapButton implementation
// Author: Vadim Zeitlin
// Modified by:
+#include "wx/bmpbuttn.h"
+
#ifndef WX_PRECOMP
#include "wx/dc.h"
#ifndef WX_PRECOMP
#include "wx/dc.h"
- #include "wx/bmpbuttn.h"
#include "wx/validate.h"
#endif
#include "wx/validate.h"
#endif
}
#endif // wxUSE_BMPBUTTON
}
#endif // wxUSE_BMPBUTTON
/////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////
+// Name: src/xrc/xh_bmpbt.cpp
// Purpose: XRC resource for bitmap buttons
// Author: Brian Gavin
// Created: 2000/09/09
// Purpose: XRC resource for bitmap buttons
// Author: Brian Gavin
// Created: 2000/09/09
+#if wxUSE_XRC && wxUSE_BMPBUTTON
#include "wx/xrc/xh_bmpbt.h"
#include "wx/xrc/xh_bmpbt.h"
-#include "wx/bmpbuttn.h"
+
+#ifndef WX_PRECOMP
+ #include "wx/bmpbuttn.h"
+#endif
IMPLEMENT_DYNAMIC_CLASS(wxBitmapButtonXmlHandler, wxXmlResourceHandler)
IMPLEMENT_DYNAMIC_CLASS(wxBitmapButtonXmlHandler, wxXmlResourceHandler)
return IsOfClass(node, wxT("wxBitmapButton"));
}
return IsOfClass(node, wxT("wxBitmapButton"));
}
+#endif // wxUSE_XRC && wxUSE_BMPBUTTON