Exemplo n.º 1
0
	//-------------------------------------------------------------------------
	void AppFrame::draw( bool forceDraw )
	//-------------------------------------------------------------------------
	{
		Layout::draw( forceDraw );

		if ( mMessage.length( ) > 0 )
		{
			// draw message, if any
			maSetColor( MessageBackColor.val( ) );

			if ( mProgress < 0 )
			{
				mMsgSkin->draw( mFillBounds.x, mFillBounds.y, mFillBounds.width, mFillBounds.height, WidgetSkin::/*eType::*/SELECTED );
				mFont->drawBoundedString( mMessage.c_str( ), mTextBounds.x, mTextBounds.y, mTextBounds );
			}
			else
			{
				Gfx_fillRect( mProgressBounds.x, mProgressBounds.y, mProgressBounds.width, mProgressBounds.height );
				maSetColor( MessageForeColor.val( ) );
				Gfx_fillRect( mProgressBounds.x, mProgressBounds.y, (int)( mProgressBounds.width * mProgress ), mProgressBounds.height );
			}
		}
	}
Exemplo n.º 2
0
void MAUI::ColorDrawable::draw(int left, int top, int width, int height) {
	maSetColor(mColor);
	Gfx_fillRect(left, top, width, height);
}