[mythtv] Mythgallery without deprecated mythdialog
trebor_s at web.de
Mon May 16 14:54:14 UTC 2011
i'm currently working on improving the gallery plugin. Currently
MythDialog is used in the gallery plugin to create the opengl widget
which then shows the images. According to the source code documentation
MythDialog is deprecated and MythScreenType shall be used.
I have changes the code so that when the user selects an image a new
window will be created and added to the stack.
In the Create() method I create the layout which uses
GetMythMainWindow(). I then assign the QGLWidget object to the layout
which will display the images in OpenGl with the scaling, fading and so
This works fine so far, except one issue. This approach will overlap
all other screens like popup dialogs, the music widget and so on. What
can be done to improve this? Is this the right direction to get rid of
the MythDialog or should I use MythUIImage? Where should then the
effects be handled?
Here are some small code snippets.
if (!LoadWindowFromXML("image-ui.xml", "slideshow", this))
<some more code here>
m_layout = new QVBoxLayout(GetMythMainWindow());
m_gliw = new GLImageWidget(this, NULL);
The QGLWidget gets the ImageWidget object so it can forward the
keypresses or get some information from this object.
GLImageWidget::GLImageWidget(ImageWidget *iw, QWidget *parent) :
More information about the mythtv-dev