Bug related to icon/bitmap conversion, fix by Mumit Khan
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@5427 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -171,7 +171,11 @@ MyFrame::AddSampleText(wxLayoutList *llist)
|
|||||||
llist->Insert("The quick brown fox jumps over the lazy dog.");
|
llist->Insert("The quick brown fox jumps over the lazy dog.");
|
||||||
llist->LineBreak();
|
llist->LineBreak();
|
||||||
llist->Insert("Hello ");
|
llist->Insert("Hello ");
|
||||||
|
#if wxICON_IS_BITMAP
|
||||||
llist->Insert(new wxLayoutObjectIcon(new wxICON(Micon)));
|
llist->Insert(new wxLayoutObjectIcon(new wxICON(Micon)));
|
||||||
|
#else
|
||||||
|
llist->Insert(new wxLayoutObjectIcon(new wxBitmap (wxICON(Micon))));
|
||||||
|
#endif
|
||||||
llist->SetFontWeight(wxBOLD);
|
llist->SetFontWeight(wxBOLD);
|
||||||
llist->Insert("World! ");
|
llist->Insert("World! ");
|
||||||
llist->SetFontWeight(wxNORMAL);
|
llist->SetFontWeight(wxNORMAL);
|
||||||
|
@@ -449,7 +449,11 @@ wxLayoutObjectIcon::wxLayoutObjectIcon(wxBitmap *icon)
|
|||||||
{
|
{
|
||||||
m_Icon = icon;
|
m_Icon = icon;
|
||||||
if(! m_Icon)
|
if(! m_Icon)
|
||||||
|
#if wxICON_IS_BITMAP
|
||||||
m_Icon = new wxIcon;
|
m_Icon = new wxIcon;
|
||||||
|
#else
|
||||||
|
m_Icon = new wxBitmap;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
Reference in New Issue
Block a user