看你code的架构怎么写了,
我是这样避免的,不知道对你有用没有,
void QT_MMScreen::paintEvent( QPaintEvent *pEvent )
{
Q_UNUSED(pEvent);
if(pEvent->rect().contains(rect(),false))
{
//qDebug()<<"QT_MMScreen rect is:"<<rect()<<"window w/h is:"<<width()<<height();
//qDebug()<<"QT_MMScreen paintEvent is:"<<pEvent->type()<<"region:"<<pEvent->region()<<"rect:"<<pEvent->rect();
QPainter p(this);
p.drawImage((SCREEN_WIDTH-m_bg.width())/2, (SCREEN_HEIGHT-m_bg.height())/2,m_bg);
}
}