Generate JSON box list for ThemeCache
The commented out wxLogDebug statements in Theme.cpp give the location of all the boxes in the theme. This is useful for identifying what is in the theme cache for javascript code.
This commit is contained in:
parent
8782a7264a
commit
291be502a0
|
@ -1042,7 +1042,8 @@ bool ThemeBase::ReadImageCache( teThemeType type, bool bOkIfNotFound)
|
|||
if( (mBitmapFlags[i] & resFlagInternal)==0)
|
||||
{
|
||||
mFlow.GetNextPosition( Image.GetWidth(),Image.GetHeight() );
|
||||
// wxLogDebug(wxT("Copy at %i %i (%i,%i)"), mxPos, myPos, xWidth1, yHeight1 );
|
||||
wxRect R = mFlow.RectInner();
|
||||
//wxLogDebug( "[%i, %i, %i, %i, \"%s\"], ", R.x, R.y, R.width, R.height, mBitmapNames[i].c_str() );
|
||||
Image = GetSubImageWithAlpha( ImageCache, mFlow.RectInner() );
|
||||
mBitmaps[i] = wxBitmap(Image);
|
||||
}
|
||||
|
@ -1060,6 +1061,8 @@ bool ThemeBase::ReadImageCache( teThemeType type, bool bOkIfNotFound)
|
|||
{
|
||||
mFlow.GetNextPosition( iColSize, iColSize );
|
||||
mFlow.RectMid( x, y );
|
||||
wxRect R = mFlow.RectInner();
|
||||
//wxLogDebug( "[%i, %i, %i, %i, \"%s\"], ", R.x, R.y, R.width, R.height, mColourNames[i].c_str() );
|
||||
// Only change the colour if the alpha is opaque.
|
||||
// This allows us to add NEW colours more easily.
|
||||
if( ImageCache.GetAlpha(x,y ) > 128 )
|
||||
|
|
Loading…
Reference in New Issue