Index: mythplugins/mythgame/theme/theme.pro
===================================================================
--- mythplugins/mythgame/theme/theme.pro	(revision 20694)
+++ mythplugins/mythgame/theme/theme.pro	(working copy)
@@ -10,7 +10,7 @@
 !macx:QMAKE_COPY_DIR = sh ../../cpsvndir
 
 defaultfiles.path = $${PREFIX}/share/mythtv/themes/default
-defaultfiles.files = default/*.xml default/images/*.png
+defaultfiles.files = default/*.xml default/images/*.png default/htmls/*.html
 
 widefiles.path = $${PREFIX}/share/mythtv/themes/default-wide
 widefiles.files = default-wide/*.xml default-wide/images/*.png
Index: mythplugins/mythgame/theme/default/game-ui.xml
===================================================================
--- mythplugins/mythgame/theme/default/game-ui.xml	(revision 20694)
+++ mythplugins/mythgame/theme/default/game-ui.xml	(working copy)
@@ -1,25 +1,7 @@
 <mythuitheme>
 
-  <window name="gametree">
+  <window name="gameui">
 
-    <font name="active" face="Arial">
-        <color>#ffffff</color>
-        <size>18</size>
-        <bold>yes</bold>
-    </font>
-
-    <font name="inactive" face="Arial">
-        <color>#9999cc</color>
-        <size>18</size>
-        <bold>yes</bold>
-    </font>
-
-    <font name="selectable" face="Arial">
-        <color>#8cdeff</color>
-        <size>18</size>
-        <bold>yes</bold>
-    </font>
-
     <font name="largetitle" face="Arial">
         <color>#ffffff</color>
         <dropcolor>#000000</dropcolor>
@@ -33,110 +15,66 @@
         <size>20</size>
         <bold>yes</bold>
     </font>
-
-    <container name="background">
-        <image name="filler" draworder="0" fleximage="yes">
-            <filename>background.png</filename>
-            <position>0,10</position>
-        </image>
-        <image name="titlelines" draworder="0" fleximage="no">
-            <filename>trans-titles.png</filename>
-            <position>0,10</position>
-        </image>
-        <image name="infofiller" draworder="0" fleximage="no">
-            <filename>pf-top.png</filename>
-            <position>26,350</position>
-        </image>
-    </container>
-
-    <container name="gameselector">
+    
+    <buttontree name="gametreelist">
         <area>0,10,800,310</area>
-        <managedtreelist name="gametreelist" draworder="1" bins="2">
-            <area>40,10,720,270</area>
-            <image function="selectionbar" filename="mv_selectionbar.png"></image>
-            <image function="uparrow" filename="mv_up_arrow.png"></image>
-            <image function="downarrow" filename="mv_down_arrow.png"></image>
-            <image function="leftarrow" filename="mv_left_arrow.png"></image>
-            <image function="rightarrow" filename="mv_right_arrow.png"></image>
-            <bin number="1">
-                <area>30,16,190,250</area>
-                <fcnfont name="active" function="active"></fcnfont>
-                <fcnfont name="inactive" function="inactive"></fcnfont>
-                <fcnfont name="active" function="selected"></fcnfont>
-                <fcnfont name="selectable" function="selectable"></fcnfont>
-            </bin>
-            <bin number="2">
-                <area>235,10,535,270</area>
-                <fcnfont name="active" function="active"></fcnfont>
-                <fcnfont name="active" function="selected"></fcnfont>
-                <fcnfont name="inactive" function="inactive"></fcnfont>
-                <fcnfont name="selectable" function="selectable"></fcnfont>
-            </bin>
-        </managedtreelist>
+        <numlists>2</numlists>
+        <spacing>10</spacing>
+        <buttonlist name="listtemplate" from="basebuttonlist" />
+    </buttontree>
 
-        <image name="showinglines" draworder="2" fleximage="yes">
-            <filename>showings.png</filename>
-            <position>0,0</position>
-        </image>
-    </container>
-
-    <container name="game_info">
-      <area>25,355,750,220</area>
-
-      <textarea name="gametitle" draworder="6">
-        <area>13,5,500,50</area>
+    <textarea name="gametitle">
+        <area>38,360,500,50</area>
         <font>largetitle</font>
-      </textarea>
+    </textarea>
 
-      <textarea name="system" draworder="6">
-        <area>13,75,150,35</area>
+    <textarea name="system">
+        <area>38,430,150,35</area>
         <font>infofont</font>
         <value>System:</value>
-      </textarea>
+    </textarea>
 
-      <textarea name="systemname" draworder="6">
-        <area>153,75,500,35</area>
+    <textarea name="systemname">
+        <area>178,430,500,35</area>
         <font>infofont</font>
-      </textarea>
+    </textarea>
 
-      <textarea name="year" draworder="6">
-        <area>13,110,150,35</area>
+    <textarea name="year">
+        <area>38,465,150,35</area>
         <font>infofont</font>
         <value>Year:</value>
-      </textarea>
+    </textarea>
 
-      <textarea name="yearname" draworder="6">
-        <area>153,110,500,35</area>
+    <textarea name="yearname">
+        <area>178,465,500,35</area>
         <font>infofont</font>
-      </textarea>
+    </textarea>
 
-      <textarea name="genre" draworder="6">
-        <area>13,140,150,35</area>
+    <textarea name="genre">
+        <area>38,495,150,35</area>
         <font>infofont</font>
         <value>Genre:</value>
-      </textarea>
+    </textarea>
 
-      <textarea name="genrename" draworder="6">
-        <area>153,140,500,35</area>
+    <textarea name="genrename">
+        <area>178,495,500,35</area>
         <font>infofont</font>
-      </textarea>
+    </textarea>
 
-      <textarea name="favorite" draworder="6">
-        <area>13,170,150,35</area>
+    <textarea name="favorite">
+        <area>38,525,150,35</area>
         <font>infofont</font>
         <value>Favorite:</value>
-      </textarea>
+    </textarea>
 
-      <textarea name="showfavorite" draworder="6">
-        <area>153,170,500,35</area>
+    <textarea name="showfavorite">
+        <area>178,525,500,35</area>
         <font>infofont</font>
-      </textarea>
+    </textarea>
 
-      <image name="gameimage" draworder="6" fleximage="no">
-          <position>535,25</position>
-          <staticsize>180,150</staticsize>
-      </image>
-    </container>
+    <imagetype name="gameimage">
+        <area>560,380,180,150</area>
+    </imagetype>
   
   </window>
 
Index: mythplugins/mythgame/theme/default/htmls/gamedetails.html
===================================================================
--- mythplugins/mythgame/theme/default/htmls/gamedetails.html	(revision 0)
+++ mythplugins/mythgame/theme/default/htmls/gamedetails.html	(revision 0)
@@ -0,0 +1,22 @@
+<html>
+<head>
+    <style type="text/css">
+        h1 {font-size:24pt;font-style: normal;color:yellow}
+        p  {font-size:20pt;font-style: normal;color:#ffffff;margin-top: -10pt}
+    </style>
+</head>
+
+<body>
+    <h1>%NAME_LABLE%</h1> <p>%NAME%</p>
+    <h1>%TYPE_LABLE%</h1> <p>%TYPE%</p>
+    <h1>%ROM_LABLE%</h1> <p>%ROM%</p>
+    <h1>%CRC_LABLE%</h1> <p>%CRC%</p>
+    <h1>%PATH_LABLE%</h1> <p>%PATH%</p>
+    <h1>%GENRE_LABLE%</h1> <p>%GENRE%</p>
+    <h1>%YEAR_LABLE%</h1> <p>%YEAR%</p>
+    <h1>%COUNTRY_LABLE%</h1> <p>%COUNTRY%</p>
+    <h1>%PUBLISHER_LABLE%</h1> <p>%PUBLISHER%</p>
+    <h1>%PLAYERS_LABLE%</h1> <p>%PLAYERS%</p>
+</body>
+
+</html>
Index: mythplugins/mythgame/theme/default-wide/game-ui.xml
===================================================================
--- mythplugins/mythgame/theme/default-wide/game-ui.xml	(revision 20694)
+++ mythplugins/mythgame/theme/default-wide/game-ui.xml	(working copy)
@@ -1,25 +1,7 @@
 <mythuitheme>
 
-  <window name="gametree">
+  <window name="gameui">
 
-    <font name="active" face="Trebuchet MS">
-        <color>#ffffff</color>
-        <size>18</size>
-        <bold>yes</bold>
-    </font>
-
-    <font name="inactive" face="Trebuchet MS">
-        <color>#9999cc</color>
-        <size>18</size>
-        <bold>yes</bold>
-    </font>
-
-    <font name="selectable" face="Trebuchet MS">
-        <color>#8cdeff</color>
-        <size>18</size>
-        <bold>yes</bold>
-    </font>
-
     <font name="largetitle" face="Trebuchet MS">
         <color>#ffffff</color>
         <dropcolor>#000000</dropcolor>
@@ -34,112 +16,87 @@
         <bold>yes</bold>
     </font>
 
-    <container name="background">
-        <image name="filler" draworder="0" fleximage="yes">
-            <filename>background.png</filename> <!-- 1280x326 -->
-            <position>0,48</position>
-        </image>
-        <image name="titlelines" draworder="0" fleximage="no">
-            <filename>trans-titles.png</filename> <!-- 1280x326 -->
-            <position>0,50</position>
-            <staticsize>280,315</staticsize>
-        </image>
-        <image name="infofiller" draworder="0" fleximage="no">
-            <filename>pf-top.png</filename> <!-- 1152x260 -->
-            <position>64,412</position>
-        </image>
-    </container>
-
-    <container name="gameselector">
+    <buttontree name="gametreelist">
         <area>8,52,1264,310</area>
-        <managedtreelist name="gametreelist" draworder="1" bins="2">
-            <area>32,0,1200,296</area>
-            <image function="selectionbar" filename="mv_selectionbar.png"></image>
-            <image function="uparrow" filename="mv_up_arrow.png"></image>
-            <image function="downarrow" filename="mv_down_arrow.png"></image>
-            <image function="leftarrow" filename="mv_left_arrow.png"></image>
-            <image function="rightarrow" filename="mv_right_arrow.png"></image>
-            <bin number="1">
-		<area>56,28,288,271</area>
-                <fcnfont name="active" function="active"></fcnfont>
-                <fcnfont name="inactive" function="inactive"></fcnfont>
-                <fcnfont name="active" function="selected"></fcnfont>
-                <fcnfont name="selectable" function="selectable"></fcnfont>
-            </bin>
-            <bin number="2">
-                <area>384,0,816,296</area>
-                <fcnfont name="active" function="active"></fcnfont>
-                <fcnfont name="active" function="selected"></fcnfont>
-                <fcnfont name="inactive" function="inactive"></fcnfont>
-                <fcnfont name="selectable" function="selectable"></fcnfont>
-            </bin>
-        </managedtreelist>
+        <numlists>3</numlists>
+        <spacing>10</spacing>
+        <buttonlist name="listtemplate" from="basebuttonlist" />
+    </buttontree>
 
-	<image name="showinglines" draworder="2" fleximage="yes">
-            <filename>showings.png</filename>
-            <position>20,10</position>
-            <staticsize>1200,310</staticsize>
-	</image>
-    </container>
-
-    <container name="game_info">
-      <area>64,412,1152,260</area>
-
-      <textarea name="gametitle" draworder="6">
-        <area>32,28,752,60</area>
+    <textarea name="gametitle" draworder="6">
+        <area>96,440,752,60</area>
         <font>largetitle</font>
-      </textarea>
+    </textarea>
 
-      <textarea name="system" draworder="6">
-        <area>32,98,140,35</area>
+    <textarea name="system" draworder="6">
+        <area>96,510,140,35</area>
         <font>infofont</font>
         <value>System:</value>
-      </textarea>
+    </textarea>
 
-      <textarea name="systemname" draworder="6">
-        <area>172,98,580,35</area>
+    <textarea name="systemname" draworder="6">
+        <area>236,510,580,35</area>
         <font>infofont</font>
-      </textarea>
+    </textarea>
 
-      <textarea name="year" draworder="6">
-        <area>32,133,140,35</area>
+    <textarea name="year" draworder="6">
+        <area>96,545,140,35</area>
         <font>infofont</font>
         <value>Year:</value>
-      </textarea>
+    </textarea>
 
-      <textarea name="yearname" draworder="6">
-        <area>172,133,580,35</area>
+    <textarea name="yearname" draworder="6">
+        <area>236,545,580,35</area>
         <font>infofont</font>
-      </textarea>
+    </textarea>
 
-      <textarea name="genre" draworder="6">
-        <area>32,168,140,35</area>
+    <textarea name="genre" draworder="6">
+        <area>96,580,140,35</area>
         <font>infofont</font>
         <value>Genre:</value>
-      </textarea>
+    </textarea>
 
-      <textarea name="genrename" draworder="6">
-        <area>172,168,580,35</area>
+    <textarea name="genrename" draworder="6">
+        <area>236,580,580,35</area>
         <font>infofont</font>
-      </textarea>
+    </textarea>
 
-      <textarea name="favorite" draworder="6">
-        <area>32,203,140,35</area>
+    <textarea name="favorite" draworder="6">
+        <area>96,615,140,35</area>
         <font>infofont</font>
         <value>Favorite:</value>
-      </textarea>
+    </textarea>
 
-      <textarea name="showfavorite" draworder="6">
-        <area>172,203,580,35</area>
+    <textarea name="showfavorite" draworder="6">
+        <area>236,615,580,35</area>
         <font>infofont</font>
-      </textarea>
+    </textarea>
 
-      <image name="gameimage" draworder="6" fleximage="no">
-          <position>816,36</position>
-          <staticsize>300,196</staticsize>
-      </image>
-    </container>
-  
+    <imagetype name="gameimage">
+          <area>880,448,300,196</area>
+    </imagetype>
+
   </window>
 
+  <window name="gamedetails">
+
+    <textarea name="title" from="basetextarea">
+        <area>80,20,720,40</area>
+        <font>baselarge</font>
+        <value>Game Details:</value>
+    </textarea>
+
+    <imagetype name="background">
+        <filename>pd-background.png</filename>
+        <position>60,60</position>
+    </imagetype>
+
+    <webbrowser name="browser">
+        <area>80,70,1094,555</area>
+        <zoom>1.0</zoom>
+        <background color="#000000" alpha="1"/>
+    </webbrowser>
+
+  </window>
+
 </mythuitheme>
Index: mythplugins/mythgame/mythgame/gameui.cpp
===================================================================
--- mythplugins/mythgame/mythgame/gameui.cpp	(revision 0)
+++ mythplugins/mythgame/mythgame/gameui.cpp	(revision 0)
@@ -0,0 +1,651 @@
+#include <mythcontext.h>
+#include <mythuibuttontree.h>
+#include <mythdialogbox.h>
+#include <mythgenerictree.h>
+
+// MythGame headers
+#include "gameui.h"
+#include "gamehandler.h"
+#include "rominfo.h"
+#include "gamedetails.h"
+
+class GameTreeInfo 
+{
+  public:
+    GameTreeInfo(const QString& levels, const QString& filter)
+      : m_levels(QStringList::split(" ", levels))
+      , m_filter(filter)
+    {
+    }
+
+    int getDepth() const                        { return m_levels.size(); }
+    const QString& getLevel(unsigned i) const   { return m_levels[i]; }
+    const QString& getFilter() const            { return m_filter; }
+
+  private:
+    QStringList m_levels;
+    QString m_filter;
+};
+
+Q_DECLARE_METATYPE(GameTreeInfo *)
+
+GameUI::GameUI(MythScreenStack *parent)
+        : MythScreenType(parent, "GameUI")
+{
+    gContext->addCurrentLocation("mythgame");
+}
+
+GameUI::~GameUI()
+{
+    gContext->removeCurrentLocation();
+}
+
+bool GameUI::Create()
+{
+    if (!LoadWindowFromXML("game-ui.xml", "gameui", this))
+        return false;
+
+    bool err = false;
+    UIUtilE::Assign(this, m_gameTreeUI, "gametreelist", &err);
+    UIUtilE::Assign(this, m_gameTitle, "gametitle", &err);
+    UIUtilE::Assign(this, m_gameSystem, "systemname", &err);
+    UIUtilE::Assign(this, m_gameYear, "yearname", &err);
+    UIUtilE::Assign(this, m_gameGenre, "genrename", &err);
+    UIUtilE::Assign(this, m_gameFavourite, "showfavorite", &err);
+    UIUtilE::Assign(this, m_gameImage, "gameimage", &err);
+
+    if (err)
+    {
+        VERBOSE(VB_IMPORTANT, "Cannot load screen 'gameui'");
+        return false;
+    }
+    
+    connect(m_gameTreeUI, SIGNAL(itemClicked(MythUIButtonListItem*)),
+            this, SLOT(itemClicked(MythUIButtonListItem*)));
+
+    connect(m_gameTreeUI, SIGNAL(nodeChanged(MythGenericTree*)),
+            this, SLOT(nodeChanged(MythGenericTree*)));
+
+    m_gameShowFileName = gContext->GetSetting("GameShowFileNames").toInt();
+
+    m_gameTree = new MythGenericTree("game root", 0, false);
+
+    timer = new QTimer(this);
+    connect(timer, SIGNAL(timeout()), SLOT(showImageTimeout()));
+
+    //  create system filter to only select games where handlers are present
+    QString systemFilter;
+
+    // The call to GameHandler::count() fills the handler list for us
+    // to move through.
+    unsigned handlercount = GameHandler::count();
+
+    for (unsigned i = 0; i < handlercount; ++i)
+    {
+        QString system = GameHandler::getHandler(i)->SystemName();
+        if (i == 0)
+            systemFilter = "system in ('" + system + "'";
+        else
+            systemFilter += ",'" + system + "'";
+    }
+    if (systemFilter.isEmpty())
+    {
+        systemFilter = "1=0";
+        VERBOSE(VB_GENERAL, QString("Couldn't find any game handlers!"));
+    }
+    else
+        systemFilter += ")";
+
+    m_showHashed = gContext->GetSetting("GameTreeView").toInt();
+
+    //  create a few top level nodes - this could be moved to a config based
+    //  approach with multiple roots if/when someone has the time to create
+    //  the relevant dialog screens
+
+    QString levels = gContext->GetSetting("GameFavTreeLevels");
+
+    MythGenericTree *new_node = new MythGenericTree("Favourites", 1, true);
+    new_node->SetData(qVariantFromValue(
+                new GameTreeInfo(levels, systemFilter + " and favorite=1")));
+    m_favouriteNode = m_gameTree->addNode(new_node);
+
+    levels = gContext->GetSetting("GameAllTreeLevels");
+
+    if (m_showHashed)
+    {
+        int pos = levels.find("gamename",0);
+        if (pos >= 0)
+            levels.insert(pos, " hash ");
+    }
+
+    new_node = new MythGenericTree(tr("All Games"), 1, true);
+    new_node->SetData(qVariantFromValue(
+                new GameTreeInfo(levels, systemFilter)));
+    m_gameTree->addNode(new_node);
+
+    new_node = new MythGenericTree(tr("-   By Genre"), 1, true);
+    new_node->SetData(qVariantFromValue(
+                new GameTreeInfo("genre gamename", systemFilter)));
+    m_gameTree->addNode(new_node);
+
+    new_node = new MythGenericTree(tr("-   By Year"), 1, true);
+    new_node->SetData(qVariantFromValue(
+                new GameTreeInfo("year gamename", systemFilter)));
+    m_gameTree->addNode(new_node);
+
+    new_node = new MythGenericTree(tr("-   By Name"), 1, true);
+    new_node->SetData(qVariantFromValue(
+                new GameTreeInfo("gamename", systemFilter)));
+    m_gameTree->addNode(new_node);
+
+    new_node = new MythGenericTree(tr("-   By Publisher"), 1, true);
+    new_node->SetData(qVariantFromValue(
+                new GameTreeInfo("publisher gamename", systemFilter)));
+    m_gameTree->addNode(new_node);
+
+    m_gameTreeUI->AssignTree(m_gameTree);
+
+    BuildFocusList();
+
+    return true;
+}
+
+bool GameUI::keyPressEvent(QKeyEvent *event)
+{
+    if (GetFocusWidget()->keyPressEvent(event))
+        return true;
+
+    bool handled = false;
+    QStringList actions;
+    gContext->GetMainWindow()->TranslateKeyPress("Game", event, actions);
+
+    for (int i = 0; i < actions.size() && !handled; i++)
+    {
+        QString action = actions[i];
+        handled = true;
+
+        if (action == "MENU")
+            showMenu();
+        else if (action == "INFO")
+            showInfo();
+        else if (action == "TOGGLEFAV")
+            toggleFavorite();
+        else if (action == "INCSEARCH")
+            searchStart();
+        else if (action == "INCSEARCHNEXT")
+            searchStart();
+        else
+            handled = false;
+    }
+    if (!handled && MythScreenType::keyPressEvent(event))
+        handled = true;
+
+    return handled;
+}
+
+void GameUI::nodeChanged(MythGenericTree* node)
+{
+    if (!isLeaf(node))
+    {
+        if (node->childCount() == 0 || node == m_favouriteNode)
+        {
+            node->deleteAllChildren();
+            fillNode(node);
+        }
+        if (timer->isActive())
+            timer->stop();
+        clearRomInfo();
+    }
+    else
+    {
+        RomInfo *romInfo = qVariantValue<RomInfo *>(node->GetData());
+        if (romInfo->Romname().isEmpty())
+            romInfo->fillData();
+        updateRomInfo(romInfo);
+        if (!romInfo->ImagePath().isEmpty())
+        {
+            if (timer->isActive())
+                timer->changeInterval(330);
+            else
+                timer->start(330, true);
+        }
+        else
+        {
+            if (m_gameImage->IsVisible())
+                m_gameImage->Hide();
+        }
+    }
+}
+
+void GameUI::itemClicked(MythUIButtonListItem*)
+{
+    MythGenericTree *node = m_gameTreeUI->GetCurrentNode();
+    if (isLeaf(node))
+    {
+        RomInfo *romInfo = qVariantValue<RomInfo *>(node->GetData());
+        if (romInfo->RomCount() == 1)
+        {
+            GameHandler::Launchgame(romInfo, NULL);
+        }
+        else
+        {
+            QString msg = QObject::tr("Choose System for") + 
+                              ":\n" + node->getString();
+            MythScreenStack *popupStack = GetMythMainWindow()->
+                                              GetStack("popup stack");
+            MythDialogBox *chooseSystemPopup = new MythDialogBox(
+                msg, popupStack, "chooseSystemPopup");
+
+            if (chooseSystemPopup->Create())
+            {
+                chooseSystemPopup->SetReturnEvent(this, "chooseSystemPopup");
+                QString all_systems = romInfo->AllSystems();
+                QStringList players = QStringList::split(",", all_systems);
+                for (QStringList::Iterator it = players.begin();
+                     it != players.end(); ++it)
+                {
+                    chooseSystemPopup->AddButton(*it);
+                }
+                chooseSystemPopup->AddButton(tr("Cancel"));
+                popupStack->AddScreen(chooseSystemPopup);
+            }
+            else
+                delete chooseSystemPopup;
+        }
+    }
+}
+
+void GameUI::showImageTimeout(void)
+{
+    m_gameImage->Load();
+    if (!m_gameImage->IsVisible())
+        m_gameImage->Show();
+}
+
+void GameUI::searchComplete(QString string)
+{
+    MythGenericTree *parent = m_gameTreeUI->GetCurrentNode()->getParent();
+    MythGenericTree *new_node = parent->getChildByName(string);
+    if (new_node)
+    {
+        m_gameTreeUI->SetCurrentNode(new_node);
+        // SetActive updates the buttonlist but SetCurrentNode doesn't.
+        m_gameTreeUI->SetActive(true);
+    }
+}
+
+void GameUI::updateRomInfo(RomInfo *rom)
+{
+    m_gameTitle->SetText(rom->Gamename());
+    m_gameSystem->SetText(rom->System());
+    m_gameYear->SetText(rom->Year());
+    m_gameGenre->SetText(rom->Genre());
+
+    if (rom->Favorite())
+        m_gameFavourite->SetText("Yes");
+    else
+        m_gameFavourite->SetText("No");
+
+    m_gameImage->SetFilename(rom->ImagePath());
+}
+
+void GameUI::clearRomInfo(void) {
+    m_gameTitle->SetText("");
+    m_gameSystem->SetText("");
+    m_gameYear->SetText("");
+    m_gameGenre->SetText("");
+    m_gameFavourite->SetText("");
+
+    if (m_gameImage->IsVisible())
+        m_gameImage->Hide();
+}
+
+void GameUI::edit(void)
+{
+    MythGenericTree *node = m_gameTreeUI->GetCurrentNode();
+    if (isLeaf(node))
+    {
+        RomInfo *romInfo = qVariantValue<RomInfo *>(node->GetData());
+        romInfo->edit_rominfo();
+        romInfo->fillData();
+        updateRomInfo(romInfo);
+    }
+}
+
+void GameUI::showInfo()
+{
+    MythGenericTree *node = m_gameTreeUI->GetCurrentNode();
+    if (isLeaf(node))
+    {
+        RomInfo *romInfo = qVariantValue<RomInfo *>(node->GetData());
+        MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
+        GameDetails *details_dialog  = new GameDetails(mainStack, romInfo);
+
+        if (details_dialog->Create())
+            mainStack->AddScreen(details_dialog);
+        else
+            delete details_dialog;
+    }
+}
+
+void GameUI::showMenu()
+{
+    MythGenericTree *node = m_gameTreeUI->GetCurrentNode();
+    if (isLeaf(node))
+    {
+        RomInfo *romInfo = qVariantValue<RomInfo *>(node->GetData());
+        MythScreenStack *popupStack = GetMythMainWindow()->
+                                              GetStack("popup stack");
+        MythDialogBox *showMenuPopup =
+            new MythDialogBox(node->getString(), popupStack, "showMenuPopup");
+
+        if (showMenuPopup->Create())
+        {
+            showMenuPopup->SetReturnEvent(this, "showMenuPopup");
+            showMenuPopup->AddButton(tr("Show Information"));
+            if (romInfo->Favorite())
+                showMenuPopup->AddButton(tr("Remove Favorite"));
+            else
+                showMenuPopup->AddButton(tr("Make Favorite"));
+            showMenuPopup->AddButton(tr("Edit"));
+            popupStack->AddScreen(showMenuPopup);
+        }
+        else
+            delete showMenuPopup;
+    }
+}
+
+void GameUI::searchStart(void)
+{
+    MythGenericTree *parent = m_gameTreeUI->GetCurrentNode()->getParent();
+
+    if (parent != NULL)
+    {
+        QStringList childList;
+        QList<MythGenericTree*>::iterator it;
+        QList<MythGenericTree*> *children = parent->getAllChildren();
+
+        for (it = children->begin(); it != children->end(); ++it)
+        {
+            MythGenericTree *child = *it;
+            childList << child->getString(); 
+        }
+
+        MythScreenStack *popupStack =
+            GetMythMainWindow()->GetStack("popup stack");
+        MythUISearchDialog *searchDialog = new MythUISearchDialog(popupStack,
+            tr("Game Search"), childList, true, "");
+
+        if (searchDialog->Create())
+        {
+            connect(searchDialog, SIGNAL(haveResult(QString)),
+                    SLOT(searchComplete(QString)));
+
+            popupStack->AddScreen(searchDialog);
+        }
+        else
+            delete searchDialog;
+    }
+}
+
+void GameUI::toggleFavorite(void)
+{
+    MythGenericTree *node = m_gameTreeUI->GetCurrentNode();
+    if (isLeaf(node))
+    {
+        RomInfo *romInfo = qVariantValue<RomInfo *>(node->GetData());
+        romInfo->setFavorite();
+        if (romInfo->Favorite())
+            m_gameFavourite->SetText("Yes");
+        else
+            m_gameFavourite->SetText("No");
+
+        if (node->getParent() == m_favouriteNode) {
+            m_gameTreeUI->SetCurrentNode(m_favouriteNode);
+            m_gameTreeUI->SetActive(true);
+        }
+    }
+}
+
+void GameUI::customEvent(QEvent *event)
+{
+    if (event->type() == kMythDialogBoxCompletionEventType)
+    {
+        DialogCompletionEvent *dce =
+            dynamic_cast<DialogCompletionEvent*>(event);
+
+        QString resultid = dce->GetId();
+        QString resulttext = dce->GetResultText();
+
+        if (resultid == "showMenuPopup")
+        {
+            if (resulttext == tr("Edit")) {
+                edit();
+            }
+            else if (resulttext == tr("Show Information"))
+            {
+                showInfo();
+            }
+            else if (resulttext == tr("Make Favorite") ||
+                     resulttext == tr("Remove Favorite"))
+            {
+                toggleFavorite();
+            }
+        }
+        else if (resultid == "chooseSystemPopup")
+        {
+            if (resulttext != "" && resulttext != tr("Cancel")) {
+                MythGenericTree *node = m_gameTreeUI->GetCurrentNode();
+                RomInfo *romInfo = qVariantValue<RomInfo *>(node->GetData());
+                GameHandler::Launchgame(romInfo, resulttext);
+            }
+        }
+    }
+}
+
+QString GameUI::getFillSql(MythGenericTree *node) const
+{
+    QString layer = node->getString();
+    int childDepth = node->getInt() + 1;
+    QString childLevel = getChildLevelString(node);
+    QString filter = getFilter(node);
+    bool childIsLeaf = childDepth == getLevelsOnThisBranch(node) + 1;
+    RomInfo *romInfo = qVariantValue<RomInfo *>(node->GetData());
+
+    QString columns;
+    QString conj = "where ";
+
+    if (!filter.isEmpty())
+    {
+        filter = conj + filter;
+        conj = " and ";
+    }
+    if ((childLevel == "gamename") && (m_gameShowFileName))
+    {
+        columns = childIsLeaf
+                    ? "romname,system,year,genre,gamename"
+                    : "romname";
+
+        if (m_showHashed)
+            filter += " and romname like '" + layer + "%'";
+
+    }
+    else if ((childLevel == "gamename") && (layer.length() == 1)) {
+        columns = childIsLeaf
+                    ? childLevel + ",system,year,genre,gamename"
+                    : childLevel;
+
+        if (m_showHashed) 
+            filter += " and gamename like '" + layer + "%'";
+
+    }
+    else if (childLevel == "hash") {
+        columns = "left(gamename,1)";
+    }
+    else {
+
+        columns = childIsLeaf
+                    ? childLevel + ",system,year,genre,gamename"
+                    : childLevel;
+    }
+
+    //  this whole section ought to be in rominfo.cpp really, but I've put it
+    //  in here for now to minimise the number of files changed by this mod
+    if (romInfo) {
+        if (!romInfo->System().isEmpty())
+        {
+            filter += conj + "trim(system)=:SYSTEM";
+            conj = " and ";
+        }
+        if (!romInfo->Year().isEmpty())
+        {
+            filter += conj + "year=:YEAR";
+            conj = " and ";
+        }
+        if (!romInfo->Genre().isEmpty())
+        {
+            filter += conj + "trim(genre)=:GENRE";
+            conj = " and ";
+        }
+        if (!romInfo->Publisher().isEmpty())
+        {
+            filter += conj + "publisher=:PUBLISHER";
+            conj = " and ";
+        }
+
+        if (!romInfo->Gamename().isEmpty())
+        {
+            filter += conj + "trim(gamename)=:GAMENAME";
+        }
+
+    }
+
+    filter += conj + " display = 1 ";
+
+    QString sql;
+
+    if ((childLevel == "gamename") && (m_gameShowFileName))
+    {   
+        sql = "select distinct "
+                + columns
+                + " from gamemetadata "
+                + filter
+                + " order by romname"
+                + ";";
+    }
+    else if (childLevel == "hash") {
+        sql = "select distinct "
+                + columns
+                + " from gamemetadata "
+                + filter
+                + " order by gamename,romname"
+                + ";";
+    }
+    else
+    {
+        sql = "select distinct "
+                + columns
+                + " from gamemetadata "
+                + filter
+                + " order by "
+                + childLevel
+                + ";";
+    }
+
+    return sql;
+}
+
+QString GameUI::getChildLevelString(MythGenericTree *node) const
+{
+    unsigned this_level = node->getInt();
+    while (node->getInt() != 1)
+        node = node->getParent();
+
+    GameTreeInfo *gi = qVariantValue<GameTreeInfo *>(node->GetData());
+    return gi->getLevel(this_level - 1);
+}
+
+QString GameUI::getFilter(MythGenericTree *node) const
+{
+    while (node->getInt() != 1)
+        node = node->getParent();
+    GameTreeInfo *gi = qVariantValue<GameTreeInfo *>(node->GetData());
+    return gi->getFilter();
+}
+
+int GameUI::getLevelsOnThisBranch(MythGenericTree *node) const
+{
+    while (node->getInt() != 1)
+        node = node->getParent();
+
+    GameTreeInfo *gi = qVariantValue<GameTreeInfo *>(node->GetData());
+    return gi->getDepth();
+}
+
+bool GameUI::isLeaf(MythGenericTree *node) const
+{
+  return (node->getInt() - 1) == getLevelsOnThisBranch(node);
+}
+
+void GameUI::fillNode(MythGenericTree *node)
+{
+    QString layername = node->getString();
+    RomInfo *romInfo = qVariantValue<RomInfo *>(node->GetData());
+
+    MSqlQuery query(MSqlQuery::InitCon());
+
+    query.prepare(getFillSql(node));
+
+    if (romInfo)
+    {
+        if (!romInfo->System().isEmpty())
+            query.bindValue(":SYSTEM",  romInfo->System());
+        if (!romInfo->Year().isEmpty())
+            query.bindValue(":YEAR", romInfo->Year());
+        if (!romInfo->Genre().isEmpty())
+            query.bindValue(":GENRE", romInfo->Genre());
+        if (!romInfo->Publisher().isEmpty())
+            query.bindValue(":PUBLISHER", romInfo->Publisher());
+        if (!romInfo->Gamename().isEmpty())
+            query.bindValue(":GAMENAME", romInfo->Gamename());
+    }
+
+    bool IsLeaf = node->getInt() == getLevelsOnThisBranch(node);
+    if (query.exec() && query.size() > 0)
+    {
+        while (query.next())
+        {
+            QString current = query.value(0).toString().stripWhiteSpace();
+            MythGenericTree *new_node =
+                new MythGenericTree(current, node->getInt() + 1, false);
+            if (IsLeaf)
+            {
+                RomInfo *temp = new RomInfo();
+                temp->setSystem(query.value(1).toString().stripWhiteSpace());
+                temp->setYear(query.value(2).toString());
+                temp->setGenre(query.value(3).toString().stripWhiteSpace());
+                temp->setGamename(query.value(4).toString().stripWhiteSpace());
+                new_node->SetData(qVariantFromValue(temp));
+                node->addNode(new_node);
+            }
+            else
+            {
+                RomInfo *newRomInfo;
+                if (node->getInt() > 1)
+                {
+                    RomInfo *currentRomInfo;
+                    currentRomInfo = qVariantValue<RomInfo *>(node->GetData());
+                    newRomInfo = new RomInfo(*currentRomInfo);
+                }
+                else
+                {
+                    newRomInfo = new RomInfo();
+                }
+                new_node->SetData(qVariantFromValue(newRomInfo));
+                node->addNode(new_node);
+                if (getChildLevelString(node) != "hash")
+                    newRomInfo->setField(getChildLevelString(node), current);
+            }
+        }
+    }
+}
Index: mythplugins/mythgame/mythgame/gameui.h
===================================================================
--- mythplugins/mythgame/mythgame/gameui.h	(revision 0)
+++ mythplugins/mythgame/mythgame/gameui.h	(revision 0)
@@ -0,0 +1,64 @@
+#ifndef GAMEUI_H_
+#define GAMEUI_H_
+
+#include <qtimer.h>
+
+// myth
+#include <mythscreentype.h>
+
+class MythUIButtonTree;
+class MythGenericTree;
+class RomInfo;
+
+class GameUI : public MythScreenType
+{
+    Q_OBJECT
+
+  public:
+    GameUI(MythScreenStack *parentStack);
+    ~GameUI();
+
+    bool Create();
+    bool keyPressEvent(QKeyEvent *event);
+
+  public slots:
+    void nodeChanged(MythGenericTree* node);
+    void itemClicked(MythUIButtonListItem* item);
+    void showImageTimeout(void);
+    void searchComplete(QString);
+
+  private:
+    void updateRomInfo(RomInfo *rom);
+    void clearRomInfo(void);
+    void edit(void);
+    void showInfo(void);
+    void showMenu(void);
+    void searchStart(void);
+    void toggleFavorite(void);
+    void customEvent(QEvent *event);
+
+    QString getFillSql(MythGenericTree* node) const;
+    QString getChildLevelString(MythGenericTree *node) const;
+    QString getFilter(MythGenericTree *node) const;
+    int     getLevelsOnThisBranch(MythGenericTree *node) const;
+    bool    isLeaf(MythGenericTree *node) const;
+    void    fillNode(MythGenericTree *node);
+
+  private:
+    bool m_showHashed;
+    int m_gameShowFileName;
+    QTimer *timer;
+
+    MythGenericTree  *m_gameTree;
+    MythGenericTree  *m_favouriteNode;
+
+    MythUIButtonTree *m_gameTreeUI;
+    MythUIText       *m_gameTitle;
+    MythUIText       *m_gameSystem;
+    MythUIText       *m_gameYear;
+    MythUIText       *m_gameGenre;
+    MythUIText       *m_gameFavourite;
+    MythUIImage      *m_gameImage; 
+};
+
+#endif
Index: mythplugins/mythgame/mythgame/rominfo.h
===================================================================
--- mythplugins/mythgame/mythgame/rominfo.h	(revision 20694)
+++ mythplugins/mythgame/mythgame/rominfo.h	(working copy)
@@ -130,4 +130,6 @@
 
 bool operator==(const RomInfo& a, const RomInfo& b);
 
+Q_DECLARE_METATYPE(RomInfo *)
+
 #endif
Index: mythplugins/mythgame/mythgame/gamedetails.cpp
===================================================================
--- mythplugins/mythgame/mythgame/gamedetails.cpp	(revision 0)
+++ mythplugins/mythgame/mythgame/gamedetails.cpp	(revision 0)
@@ -0,0 +1,148 @@
+#include <QFile>
+
+#include "mythcontext.h"
+#include "mythdb.h"
+#include "mythuihelper.h"
+
+
+#include "gamedetails.h"
+
+GameDetails::GameDetails(MythScreenStack *parent, const RomInfo *romInfo)
+           : MythScreenType (parent, "gamedetails")
+{
+    m_romInfo = *romInfo;
+    m_browser = NULL;
+    m_page = QString();
+}
+
+GameDetails::~GameDetails(void)
+{
+}
+
+bool GameDetails::Create(void)
+{
+    bool foundtheme = false;
+
+    // Load the theme for this screen
+    foundtheme = LoadWindowFromXML("game-ui.xml", "gamedetails", this);
+
+    if (!foundtheme)
+        return false;
+
+    bool err = false;
+    UIUtilE::Assign(this, m_browser, "browser", &err);
+
+    if (err)
+    {
+        VERBOSE(VB_IMPORTANT, "Cannot load screen 'gamedetails'");
+        return false;
+    }
+
+    BuildFocusList();
+
+    return true;
+}
+
+void GameDetails::Init()
+{
+    updatePage();
+}
+
+void GameDetails::updatePage(void)
+{
+    if (m_page == QString())
+        loadPage();
+
+    m_browser->SetHtml(m_page);
+}
+
+void GameDetails::loadPage(void)
+{
+    if (!loadHTML())
+    {
+       VERBOSE(VB_IMPORTANT, "  HTML not loaded");
+    }
+
+    addItem("NAME", QObject::tr("Name"), m_romInfo.Gamename());
+    addItem("TYPE", QObject::tr("Type"), m_romInfo.GameType());
+    addItem("ROM", QObject::tr("Filename"), m_romInfo.Romname());
+    addItem("CRC", QObject::tr("CRC"), m_romInfo.CRC_VALUE());
+    addItem("PATH", QObject::tr("Path"), m_romInfo.Rompath());
+    addItem("GENRE", QObject::tr("Genre"), m_romInfo.Genre());
+    addItem("YEAR", QObject::tr("Year"), m_romInfo.Year());
+    addItem("COUNTRY", QObject::tr("Country"), m_romInfo.Country());
+    addItem("PUBLISHER", QObject::tr("Publisher"), m_romInfo.Publisher());
+    addItem("PLAYERS", QObject::tr("Player(s)"), m_romInfo.AllSystems());
+
+    m_page = m_html.join("\n");
+}
+
+bool GameDetails::loadHTML(void)
+{
+    m_html.clear();
+
+    QString filename = "gamedetails.html";
+    if (!GetMythUI()->FindThemeFile(filename))
+        return false;
+
+    QFile file(QLatin1String(qPrintable(filename)));
+
+    if (!file.exists())
+        return false;
+
+    if (file.open(QIODevice::ReadOnly))
+    {
+        QTextStream stream(&file);
+
+        while (!stream.atEnd())
+        {
+            m_html.append(stream.readLine());
+        }
+        file.close();
+    }
+    else
+        return false;
+
+    return true;
+}
+
+void GameDetails::addItem(const QString &key, const QString &title,
+                          const QString &data)
+{
+    QString escapedKey = "%" + key + "%";
+
+    if (data == "")
+    {
+        removeItem(key);
+        return;
+    }
+
+    // find the key in the html and replace with the correct data
+    for (int x = 0; x < m_html.size(); x++)
+    {
+        QString s = m_html[x];
+        if (s.contains(escapedKey))
+        {
+            // replace the label first
+            s.replace("%" + key + "_LABLE%", title);
+            // now replace the data
+            s.replace(escapedKey, data);
+            m_html[x] = s;
+        }
+    }
+}
+
+void GameDetails::removeItem(const QString &key)
+{
+    // remove all line in the html that have key in them
+    // (should only be one line)
+    for (int x = 0; x < m_html.size(); x++)
+    {
+        QString s = m_html[x];
+        if (s.contains("%" + key + "%"))
+        {
+            m_html.removeAll(s);
+            return;
+        }
+    }
+}
Index: mythplugins/mythgame/mythgame/main.cpp
===================================================================
--- mythplugins/mythgame/mythgame/main.cpp	(revision 20694)
+++ mythplugins/mythgame/mythgame/main.cpp	(working copy)
@@ -6,10 +6,10 @@
 #include <QDir>
 #include <QApplication>
 
+#include "gameui.h"
 #include "gamehandler.h"
 #include "rominfo.h"
 #include "gamesettings.h"
-#include "gametree.h"
 #include "dbcheck.h"
 
 #include <mythtv/mythcontext.h>
@@ -60,33 +60,33 @@
 {
     QString themedir = GetMythUI()->GetThemeDir();
 
-    MythThemedMenu *diag = new MythThemedMenu(
+    MythThemedMenu *menu = new MythThemedMenu(
         themedir, which_menu, GetMythMainWindow()->GetMainStack(), "game menu");
 
     GameData data;
 
-    diag->setCallback(GameCallback, &data);
-    diag->setKillable();
+    menu->setCallback(GameCallback, &data);
+    menu->setKillable();
 
-    if (diag->foundTheme())
+    if (menu->foundTheme())
     {
-        if (class LCD * lcd = LCD::Get())
-        {
+        if (LCD * lcd = LCD::Get())
             lcd->switchToTime();
-        }
-        GetMythMainWindow()->GetMainStack()->AddScreen(diag);
+
+        GetMythMainWindow()->GetMainStack()->AddScreen(menu);
         return 0;
     }
     else
     {
         VERBOSE(VB_IMPORTANT, QString("Couldn't find menu %1 or theme %2")
                               .arg(which_menu).arg(themedir));
-        delete diag;
+        delete menu;
         return -1;
     }
 }
 
 void runGames(void);
+int  RunGames(void);
 
 void setupKeys(void)
 {
@@ -105,9 +105,12 @@
 {
     if (!gContext->TestPopupVersion("mythgame", libversion,
                                     MYTH_BINARY_VERSION))
+    {
+        VERBOSE(VB_IMPORTANT,
+                QString("libmythgame.so/main.o: binary version mismatch"));
         return -1;
+    }
 
-
     gContext->ActivateSettingsCache(false);
     if (!UpgradeGameDatabaseSchema())
     {
@@ -126,18 +129,31 @@
     return 0;
 }
 
-void runGames(void)
+void runGames()
 {
-    gContext->addCurrentLocation("mythgame");
-    GameTree gametree(gContext->GetMainWindow(), "gametree", "game-");
-    gametree.exec();
-    gContext->removeCurrentLocation();
+    RunGames();
 }
 
+int RunGames(void)
+{
+    MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
+    GameUI *game = new GameUI(mainStack);
+
+    if (game->Create())
+    {
+        mainStack->AddScreen(game);
+        return 0;
+    }
+    else
+    {
+        delete game;
+        return -1;
+    } 
+}
+
 int mythplugin_run(void)
 {
-    runGames();
-    return 0;
+    return RunGames();
 }
 
 int mythplugin_config(void)
Index: mythplugins/mythgame/mythgame/gamedetails.h
===================================================================
--- mythplugins/mythgame/mythgame/gamedetails.h	(revision 0)
+++ mythplugins/mythgame/mythgame/gamedetails.h	(revision 0)
@@ -0,0 +1,34 @@
+#ifndef GAMEDETAILS_H_
+#define GAMEDETAILS_H_
+
+#include <QString>
+#include <QKeyEvent>
+
+#include "mythscreentype.h"
+#include "mythuiwebbrowser.h"
+#include "rominfo.h"
+
+class GameDetails : public MythScreenType
+{
+    Q_OBJECT
+  public:
+    GameDetails(MythScreenStack *parent, const RomInfo *romInfo);
+    ~GameDetails();
+
+    bool Create(void);
+    void Init(void);
+
+  private:
+    void updatePage(void);
+    void loadPage(void);
+    bool loadHTML(void);
+    void addItem(const QString &key, const QString &title, const QString &data);
+    void removeItem(const QString &key);
+
+    RomInfo            m_romInfo;
+    MythUIWebBrowser  *m_browser;
+    QString            m_page;
+    QStringList        m_html;
+};
+
+#endif
Index: mythplugins/mythgame/mythgame/mythgame.pro
===================================================================
--- mythplugins/mythgame/mythgame/mythgame.pro	(revision 20694)
+++ mythplugins/mythgame/mythgame/mythgame.pro	(working copy)
@@ -9,11 +9,12 @@
 INSTALLS += target
 
 # Input
-HEADERS += gamehandler.h rominfo.h unzip.h gamesettings.h gametree.h
-HEADERS += rom_metadata.h romedit.h
+HEADERS += gamehandler.h rominfo.h unzip.h gamesettings.h gameui.h
+HEADERS += rom_metadata.h romedit.h gamedetails.h
 
-SOURCES += main.cpp gamehandler.cpp rominfo.cpp gametree.cpp unzip.c
+SOURCES += main.cpp gamehandler.cpp rominfo.cpp gameui.cpp unzip.c
 SOURCES += gamesettings.cpp dbcheck.cpp rom_metadata.cpp romedit.cpp
+SOURCES += gamedetails.cpp
 
 use_hidesyms {
     QMAKE_CXXFLAGS += -fvisibility=hidden
Index: mythtv/themes/Terra/game-ui.xml
===================================================================
--- mythtv/themes/Terra/game-ui.xml	(revision 0)
+++ mythtv/themes/Terra/game-ui.xml	(revision 0)
@@ -0,0 +1,125 @@
+<mythuitheme>
+
+  <window name="gameui">
+
+    <imagetype name="backdrop" from="basebackdrop" />
+    <imagetype name="topbar" from="basetopbar" />
+
+    <textarea name="heading" from="baseheading">
+        <value>Play Games</value>
+    </textarea>
+
+    <buttontree name="gametreelist">
+        <area>8,52,1264,375</area>
+        <numlists>3</numlists>
+        <spacing>10</spacing>
+        <buttonlist name="listtemplate">
+            <area>0,0,1264,375</area>
+            <layout>vertical</layout>
+            <buttonarea>0,0,100%,97%</buttonarea>
+            <statetype name="buttonitem">
+                <state name="active">
+                    <area>0,0,100%,30</area>
+                    <imagetype name="buttonbackground">
+                        <gradient start="#4b4b3e" end="#4b4b3e" alpha="255"/>
+                    </imagetype>
+                    <textarea name="buttontext">
+                        <area>5,0,85%,30</area>
+                        <font>basesmall</font>
+                        <cutdown>yes</cutdown>
+                        <align>left,vcenter</align>
+                    </textarea>
+                </state>
+                <state name="selected" from="active">
+                    <imagetype name="buttonbackground">
+                        <gradient start="#8a916f" end="#8a916f" alpha="255"/>
+                    </imagetype>
+                    <textarea name="buttontext">
+                        <area>5,0,85%,30</area>
+                        <font>basesmallbrown</font>
+                        <cutdown>yes</cutdown>
+                        <align>left,vcenter</align>
+                    </textarea>
+                </state>
+                <state name="inactive" from="active" />
+            </statetype>
+        </buttonlist>
+    </buttontree>
+
+      <textarea name="gametitle">
+        <area>96,440,752,60</area>
+        <font>baseextralarge</font>
+      </textarea>
+
+      <textarea name="system">
+        <area>96,510,140,35</area>
+        <font>basemedium</font>
+        <value>System:</value>
+      </textarea>
+
+      <textarea name="systemname">
+        <area>236,510,580,35</area>
+        <font>basemedium</font>
+      </textarea>
+
+      <textarea name="year">
+        <area>96,545,140,35</area>
+        <font>basemedium</font>
+        <value>Year:</value>
+      </textarea>
+
+      <textarea name="yearname">
+        <area>236,545,580,35</area>
+        <font>basemedium</font>
+      </textarea>
+
+      <textarea name="genre">
+        <area>96,580,140,35</area>
+        <font>basemedium</font>
+        <value>Genre:</value>
+      </textarea>
+
+      <textarea name="genrename">
+        <area>236,580,580,35</area>
+        <font>basemedium</font>
+      </textarea>
+
+      <textarea name="favorite">
+        <area>96,615,140,35</area>
+        <font>basemedium</font>
+        <value>Favorite:</value>
+      </textarea>
+
+      <textarea name="showfavorite">
+        <area>236,615,580,35</area>
+        <font>basemedium</font>
+      </textarea>
+
+      <imagetype name="gameimage">
+          <area>880,448,300,196</area>
+      </imagetype>
+
+  </window>
+
+  <window name="gamedetails">
+
+      <textarea name="title" from="basetextarea">
+          <area>80,20,720,40</area>
+          <font>baselarge</font>
+          <value>Game Details:</value>
+      </textarea>
+
+      <imagetype name="background">
+          <filename>pd-background.png</filename>
+          <position>60,60</position>
+      </imagetype>
+
+      <webbrowser name="browser">
+          <area>80,70,1094,555</area>
+          <zoom>1.0</zoom>
+          <background color="#000000" alpha="1"/>
+      </webbrowser>
+
+  </window>
+
+</mythuitheme>
Index: mythtv/themes/Terra/base.xml
===================================================================
--- mythtv/themes/Terra/base.xml	(revision 20694)
+++ mythtv/themes/Terra/base.xml	(working copy)
@@ -717,6 +717,70 @@
         </button>
     </window>
 
+    <window name="MythSearchDialog">
+        <area>-1,-1,500,500</area>
+        <imagetype name="backimg">
+            <area>0,0,500,500</area>
+            <filename>mythdialogbox-background.png</filename>
+        </imagetype>
+
+        <textarea name="title" from="basetextarea">
+            <area>12,20,470,60</area>
+            <multiline>yes</multiline>
+            <align>allcenter</align>
+        </textarea>
+
+        <textedit name="input" from="basetextedit">
+            <position>32,85</position>
+        </textedit>
+
+        <buttonlist name="itemlist">
+            <area>12,150,470,270</area>
+            <layout>vertical</layout>
+            <buttonarea>0,0,470,270</buttonarea>
+            <align>left,vcenter</align>
+            <showarrow>no</showarrow>
+            <spacing>3</spacing>
+            <wrapstyle>selection</wrapstyle>
+            <statetype name="buttonitem">
+                <state name="active">
+                    <area>0,0,100%,30</area>
+                    <imagetype name="buttonbackground">
+                        <gradient start="#4b4b3e" end="#4b4b3e" alpha="255"/>
+                    </imagetype>
+                    <textarea name="buttontext">
+                        <area>5,0,85%,30</area>
+                        <font>basesmall</font>
+                        <cutdown>yes</cutdown>
+                        <align>left,vcenter</align>
+                    </textarea>
+                </state>
+                <state name="selected" from="active">
+                    <imagetype name="buttonbackground">
+                        <gradient start="#8a916f" end="#8a916f" alpha="255"/>
+                    </imagetype>
+                    <textarea name="buttontext">
+                        <area>5,0,85%,30</area>
+                        <font>basesmallbrown</font>
+                        <cutdown>yes</cutdown>
+                        <align>left,vcenter</align>
+                    </textarea>
+                </state>
+                <state name="inactive" from="active" />
+            </statetype>
+        </buttonlist>
+
+        <button name="cancel" from="basebutton">
+            <position>18,435</position>
+            <value>Cancel</value>
+        </button>
+
+        <button name="ok" from="basebutton">
+            <position>259,435</position>
+            <value>Ok</value>
+        </button>
+    </window>
+
     <!-- Busy Dialog -->
     <window name="MythBusyDialog">
         <area>-1,-1,580,165</area>
