Take const wxWindow in wxBitmapBundle::GetPreferredSizeFor()
This function should be usable in const methods of wxWindow-derived classes too.
This commit is contained in:
@@ -100,7 +100,7 @@ public:
|
|||||||
// Get preferred size, i.e. usually the closest size in which a bitmap is
|
// Get preferred size, i.e. usually the closest size in which a bitmap is
|
||||||
// available to the ideal size determined from the default size and the DPI
|
// available to the ideal size determined from the default size and the DPI
|
||||||
// scaling, for the given window.
|
// scaling, for the given window.
|
||||||
wxSize GetPreferredSizeFor(wxWindow* window) const;
|
wxSize GetPreferredSizeFor(const wxWindow* window) const;
|
||||||
wxSize GetPreferredSizeAtScale(double scale) const;
|
wxSize GetPreferredSizeAtScale(double scale) const;
|
||||||
|
|
||||||
// Get bitmap of the specified size, creating a new bitmap from the closest
|
// Get bitmap of the specified size, creating a new bitmap from the closest
|
||||||
|
@@ -275,7 +275,7 @@ public:
|
|||||||
|
|
||||||
@param window Non-null and fully created window.
|
@param window Non-null and fully created window.
|
||||||
*/
|
*/
|
||||||
wxSize GetPreferredSizeFor(wxWindow* window) const;
|
wxSize GetPreferredSizeFor(const wxWindow* window) const;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Get bitmap of the specified size, creating a new bitmap from the closest
|
Get bitmap of the specified size, creating a new bitmap from the closest
|
||||||
|
@@ -375,7 +375,7 @@ wxSize wxBitmapBundle::GetDefaultSize() const
|
|||||||
return m_impl->GetDefaultSize();
|
return m_impl->GetDefaultSize();
|
||||||
}
|
}
|
||||||
|
|
||||||
wxSize wxBitmapBundle::GetPreferredSizeFor(wxWindow* window) const
|
wxSize wxBitmapBundle::GetPreferredSizeFor(const wxWindow* window) const
|
||||||
{
|
{
|
||||||
wxCHECK_MSG( window, wxDefaultSize, "window must be valid" );
|
wxCHECK_MSG( window, wxDefaultSize, "window must be valid" );
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user