2011-01-27 6 views

答えて

3

使用QMovieアニメーションGIFを再生し、それぞれの新しいフレームイベントのトレイアイコンを更新する:

m_icon = new QSystemTrayIcon(); 
m_icon->show(); 
m_gif = new QMovie(":/animated.gif"); 
connect(m_gif, SIGNAL(frameChanged(int)), this, SLOT(updateIcon())); 
m_gif->start(); 

... C++例えば申し訳

void MyWidget::updateIcon() 
{ 
    m_icon->setIcon(m_gif->currentPixmap()); 
} 

を、私はPyQtをインストールしないでください。

関連する問題