From: <ma...@us...> - 2003-12-23 00:41:43
|
Update of /cvsroot/sharedaemon/ui-wx/src In directory sc8-pr-cvs1:/tmp/cvs-serv18411 Modified Files: MBitmapButton.cpp MBitmapButton.h Log Message: Fixes stuff Index: MBitmapButton.cpp =================================================================== RCS file: /cvsroot/sharedaemon/ui-wx/src/MBitmapButton.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- MBitmapButton.cpp 22 Dec 2003 12:06:23 -0000 1.5 +++ MBitmapButton.cpp 23 Dec 2003 00:41:40 -0000 1.6 @@ -146,6 +146,7 @@ tmp->SetMask(new wxMask(*tmp, wxColour(0, 0, 0))); #endif SetBitmapLabel(*tmp); + orig_img = *tmp; SetSize(wxSize(tmp->GetWidth()+10, tmp->GetHeight()+5)); delete tmp; } @@ -172,7 +173,7 @@ mdc.SetBrush(wxBrush(wxColour(0, 0, 0), wxSOLID)); #endif mdc.DrawRectangle(0, 0, tmp.GetWidth(), tmp.GetHeight()); - mdc.DrawBitmap(GetBitmapLabel(), 0, 0, true); + mdc.DrawBitmap(orig_img, 0, 0, true); #ifndef __WXMSW__ tmp.SetMask(new wxMask(tmp, wxColour(0, 0, 0))); #endif Index: MBitmapButton.h =================================================================== RCS file: /cvsroot/sharedaemon/ui-wx/src/MBitmapButton.h,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- MBitmapButton.h 22 Dec 2003 11:56:02 -0000 1.2 +++ MBitmapButton.h 23 Dec 2003 00:41:40 -0000 1.3 @@ -81,6 +81,7 @@ DECLARE_EVENT_TABLE() void OnClick(wxCommandEvent &event){ event.Skip(); } /* Skips events */ void OnSize(wxSizeEvent &event); /* Updates image */ + wxBitmap orig_img; /* Original generated image */ }; #endif // ___WXMSW__ |