mirror of
https://github.com/SFML/SFML.git
synced 2024-11-28 22:31:09 +08:00
FS#108 - Updated the Qt sample and tutorial to work with Qt 4.5
git-svn-id: https://sfml.svn.sourceforge.net/svnroot/sfml/trunk@1082 4e206d99-4929-0410-ac5d-dfc041789085
This commit is contained in:
parent
4d44a91ced
commit
0883940b2a
@ -20,6 +20,7 @@ myInitialized (false)
|
|||||||
{
|
{
|
||||||
// Setup some states to allow direct rendering into the widget
|
// Setup some states to allow direct rendering into the widget
|
||||||
setAttribute(Qt::WA_PaintOnScreen);
|
setAttribute(Qt::WA_PaintOnScreen);
|
||||||
|
setAttribute(Qt::WA_OpaquePaintEvent);
|
||||||
setAttribute(Qt::WA_NoSystemBackground);
|
setAttribute(Qt::WA_NoSystemBackground);
|
||||||
|
|
||||||
// Set strong focus to enable keyboard events to be received
|
// Set strong focus to enable keyboard events to be received
|
||||||
@ -63,6 +64,15 @@ void QSFMLCanvas::OnUpdate()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
/// Return the paint engine used by the widget to draw itself
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
QPaintEngine* QSFMLCanvas::paintEngine() const
|
||||||
|
{
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
/// Called when the widget is shown ;
|
/// Called when the widget is shown ;
|
||||||
/// we use it to initialize our SFML window
|
/// we use it to initialize our SFML window
|
||||||
|
@ -50,6 +50,12 @@ private :
|
|||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
virtual void OnUpdate();
|
virtual void OnUpdate();
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
/// Return the paint engine used by the widget to draw itself
|
||||||
|
///
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
virtual QPaintEngine* paintEngine() const;
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
/// Called when the widget is shown ;
|
/// Called when the widget is shown ;
|
||||||
/// we use it to initialize our SFML window
|
/// we use it to initialize our SFML window
|
||||||
|
Loading…
Reference in New Issue
Block a user