From 9b5ae377f655f80525fb73e26fb3bbcd601c9f32 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Thu, 14 Dec 2017 19:32:08 +0000
Subject: LinHES-config: add LH_HELP file for mythinstall and Alt+H shortcut.

---
 abs/core/LinHES-config/LH_HELP  | 14 ++++++++++++++
 abs/core/LinHES-config/PKGBUILD |  6 +++++-
 2 files changed, 19 insertions(+), 1 deletion(-)
 create mode 100644 abs/core/LinHES-config/LH_HELP

diff --git a/abs/core/LinHES-config/LH_HELP b/abs/core/LinHES-config/LH_HELP
new file mode 100644
index 0000000..809a4ad
--- /dev/null
+++ b/abs/core/LinHES-config/LH_HELP
@@ -0,0 +1,14 @@
+Visit http://linhes.org for additional help.
+
+KEYBOARD SHORTCUTS
+Alt + h: This Screen
+Alt + x: Open New Terminal (xterm)
+Alt + m: Open mythfrontend
+m in mythfrontend: Display Power/About Menu
+Alt + 1: Start Master mythbackend
+Alt + 2: Stop Master mythbackend
+Alt + 3: Restart Master mythbackend
+Alt + s: Open mythtv-setup
+Alt + u: Unhide/Hide Mouse Pointer
+Alt + w: Open Web Browser (Chrome if installed)
+Alt + f: Restart Window Manager
diff --git a/abs/core/LinHES-config/PKGBUILD b/abs/core/LinHES-config/PKGBUILD
index 86a9c5c..9d8cbc9 100755
--- a/abs/core/LinHES-config/PKGBUILD
+++ b/abs/core/LinHES-config/PKGBUILD
@@ -1,6 +1,6 @@
 pkgname=LinHES-config
 pkgver=8.5.1
-pkgrel=1
+pkgrel=2
 conflicts=(MythVantage-config MythVantage-config-dev LinHES-config-dev LinHes-config )
 pkgdesc="Install and configure your system"
 depends=('bc' 'libstatgrab' 'mysql-python' 'expect' 'curl' 'dnsutils' 'parted'
@@ -32,6 +32,7 @@ source=(mv_install.py 09_mythvantge_runit_grub
 	udev_link.sh
 	restore_km_db_chroot.sh
 	README
+    LH_HELP
 	mv_advanced.py
 	mv_common.py
 	mv_ddns.py
@@ -118,6 +119,8 @@ package() {
 
     #README file displayed on install
     install -m 0755 README $MVDIR/README
+    #LH_HELP file displayed with Alt+H shortcut
+    install -m 0755 LH_HELP $MVDIR/LH_HELP
 
     mkdir -p $pkgdir/usr/bin
     install -m 0755 file_time_offset.py $pkgdir/usr/bin/file_time_offset.py
@@ -165,6 +168,7 @@ md5sums=('518c868141fe443e9258144c029ed3f9'
          'd3490e93f313bbbcbc6c3693c56b9c17'
          'e959df98947eb0d2ea64ff616b61aab5'
          '2506860a416e1988934225d80d501c2c'
+         '3ff600acf742700bb55b719dab863d15'
          'f57200b66b6cf384f2c784b3e4303503'
          'b3505d27b65a4d35e252e2d256909e80'
          'b845de3e05c1734cce4b9ac5e8f1baaf'
-- 
cgit v0.12


From 617a3af08e1baa921cda93e0077121f22a9447d9 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Thu, 14 Dec 2017 22:29:56 +0000
Subject: mythinstall: port question, readme and help screens to MythUI

eliminate some compiler warnings by checking for system call outputs.
---
 .../MythVantage-app/mythinstall/installdialog.cpp  |  53 +++--
 .../MythVantage-app/mythinstall/main.cpp           | 222 +++++++++------------
 .../MythVantage-app/mythinstall/mythinstall.pro    |   4 +-
 .../MythVantage-app/mythinstall/questionnotice.cpp | 136 +++++++++++++
 .../MythVantage-app/mythinstall/questionnotice.h   |  43 ++++
 .../MythVantage-app/mythinstall/xorgsettings.h     |   1 -
 abs/core/mythinstall/PKGBUILD                      |   8 +-
 abs/core/mythinstall/install-ui.xml                |  40 ++++
 8 files changed, 349 insertions(+), 158 deletions(-)
 create mode 100755 abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.cpp
 create mode 100755 abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.h

diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.cpp b/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.cpp
index 6f4252f..a067f98 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.cpp
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.cpp
@@ -23,10 +23,9 @@
 
 
 WelcomeDialog::WelcomeDialog(MythScreenStack *parent, const char *name)
-    :MythScreenType(parent, name),
-     m_status_text(NULL),          m_recording_text(NULL), m_scheduled_text(NULL),
-     m_time_text(NULL),      m_date_text(NULL),
-     m_menuPopup(NULL), m_mv_text(NULL)
+    :MythScreenType(parent, name), m_menuPopup(NULL),
+     m_status_text(NULL),m_recording_text(NULL), m_scheduled_text(NULL),
+     m_mv_text(NULL), m_time_text(NULL), m_date_text(NULL)
 
 {
 //     system("rm -f /tmp/.install_state");
@@ -104,9 +103,11 @@ void WelcomeDialog::shutdownNow(int rc)
 //     system("rm -f /tmp/.install_percent");
 //     system("rm -f /tmp/.install_error");
     if (rc == 1)
-        system("/sbin/halt");
+        if(!system("/sbin/halt"))
+            LOG(VB_GENERAL, LOG_ERR, "Error running halt");
     else
-        system("/sbin/reboot");
+        if(!system("/sbin/reboot"))
+            LOG(VB_GENERAL, LOG_ERR, "Error running reboot");
 }
 
 void WelcomeDialog::runLIVECD(void)
@@ -159,7 +160,8 @@ bool WelcomeDialog::keyPressEvent(QKeyEvent *event)
 //                QByteArray tmp = cmd.toAscii();
 //                QByteArray tmp = cmd;
 //                system(tmp);
-                system(qPrintable(cmd));
+                if(!system(qPrintable(cmd)))
+                    LOG(VB_GENERAL, LOG_ERR, "Error running MythShutdownXTermCMD");
             }
         }
         else
@@ -174,7 +176,6 @@ bool WelcomeDialog::keyPressEvent(QKeyEvent *event)
 void WelcomeDialog::closeDialog()
 {
     Close();
-    exit(0);
 }
 
 
@@ -229,7 +230,8 @@ void WelcomeDialog::updateScreen(void)
     QString cmdtxt;
     cmdtxt=MV_ROOT  ;
     cmdtxt.append("bin/install_proxy.sh " );
-    system(qPrintable(cmdtxt));
+    if(!system(qPrintable(cmdtxt)))
+        LOG(VB_GENERAL, LOG_ERR, "Error running install_proxy.sh");
     recording_text="Press MENU for Options";
     mythvantage_text=" ";
     error_text=" ";
@@ -522,7 +524,7 @@ QString WelcomeDialog::findinstallsouce(void)
     {
         getline (mountfile,line);
         if ( line.empty() )
-            line = "oops didn't find andthing";
+            line = "oops didn't find anything";
 
         currentitem= ( QString::fromStdString( line ) );
 
@@ -867,7 +869,8 @@ void WelcomeDialog::install_generic(void)
             QString cmdtxt;
             cmdtxt=MV_ROOT  ;
             cmdtxt.append("bin/install_proxy.sh find_update " +  install_drive +" &");
-            system(qPrintable(cmdtxt));
+            if(!system(qPrintable(cmdtxt)))
+                LOG(VB_GENERAL, LOG_ERR, "Could not run install_proxy.sh find update");
             busy_find_oldsettings();
             bool flag = false;
             QString line;
@@ -1000,14 +1003,14 @@ int  WelcomeDialog::ask_validate_network(void)
             QString cmdtxt;
             cmdtxt=MV_ROOT  ;
             cmdtxt.append("bin/install_proxy.sh network_check_it setup_network &");
-            retval =  system(qPrintable(cmdtxt));
+            retval = system(qPrintable(cmdtxt));
             busy_network();
             if (network_check)
             {
                 network_check->setProgress(2);
                 cmdtxt=MV_ROOT  ;
                 cmdtxt.append("bin/install_proxy.sh network_check_it check_self");
-                retval =  system(qPrintable(cmdtxt));
+                retval = system(qPrintable(cmdtxt));
                 if ( retval != 0 )
                 {
                     network_check->Close();
@@ -1020,7 +1023,7 @@ int  WelcomeDialog::ask_validate_network(void)
                 network_check->setProgress(3);
                 cmdtxt=MV_ROOT  ;
                 cmdtxt.append("bin/install_proxy.sh network_check_it check_gw");
-                retval =  system(qPrintable(cmdtxt));
+                retval = system(qPrintable(cmdtxt));
                 if ( retval != 0 )
                 {
                     network_check->Close();
@@ -1033,7 +1036,7 @@ int  WelcomeDialog::ask_validate_network(void)
                 network_check->setProgress(4);
                 cmdtxt=MV_ROOT  ;
                 cmdtxt.append("bin/install_proxy.sh network_check_it check_ns");
-                retval =  system(qPrintable(cmdtxt));
+                retval = system(qPrintable(cmdtxt));
                 if ( retval != 0 )
                 {
                     network_check->Close();
@@ -1046,7 +1049,7 @@ int  WelcomeDialog::ask_validate_network(void)
                 network_check->setProgress(5);
                 cmdtxt=MV_ROOT  ;
                 cmdtxt.append("bin/install_proxy.sh network_check_it check_names");
-                retval =  system(qPrintable(cmdtxt));
+                retval = system(qPrintable(cmdtxt));
                 if ( retval != 0 )
                 {
                     network_check->Close();
@@ -1059,7 +1062,7 @@ int  WelcomeDialog::ask_validate_network(void)
                 network_check->setProgress(6);
                 cmdtxt=MV_ROOT  ;
                 cmdtxt.append("bin/install_proxy.sh network_check_it host_names");
-                retval =  system(qPrintable(cmdtxt));
+                retval = system(qPrintable(cmdtxt));
                 if ( retval != 0 )
                 {
                     network_check->Close();
@@ -1154,14 +1157,18 @@ void WelcomeDialog::install_it(void)
         QString cmdtxt=MV_ROOT  ;
         //cmdtxt.append("bin/install_proxy.sh full_install_it " + install_drive + " " + rootfs + " " + rootsize + " " +  datafs + " " + datasize + " " + swapsize + "&");
         cmdtxt.append("bin/install_proxy.sh full_install_it &");
-        system(qPrintable(cmdtxt));
+        if(!system(qPrintable(cmdtxt)))
+            LOG(VB_GENERAL, LOG_ERR, "Error running install_proxy.sh full_install_it");
+
     }
     else if  ( installtype == "Upgrade" )
     {
         QString cmdtxt=MV_ROOT  ;
         //cmdtxt.append("bin/install_proxy.sh upgrade_it " + install_drive + " " + uprootfs +  "&");
         cmdtxt.append("bin/install_proxy.sh upgrade_it &");
-        system(qPrintable(cmdtxt));
+        if(!system(qPrintable(cmdtxt)))
+            LOG(VB_GENERAL, LOG_ERR, "Error running install_proxy.sh upgrade_it");
+
     }
     else if (installtype=="NET")
     {
@@ -1178,11 +1185,15 @@ void WelcomeDialog::install_it(void)
         QString h;
         h=localhostname;
         cmdtxt.append("bin/restore_default_settings.sh -c save -t syssettings  -d  127.0.0.1  -h " + h);
-        system(qPrintable(cmdtxt));
+        if(!system(qPrintable(cmdtxt)))
+            LOG(VB_GENERAL, LOG_ERR, "Error running restore_default_settings.sh");
+
         cmdtxt=MV_ROOT  ;
         //cmdtxt.append("bin/install_proxy.sh NETBOOT  " + install_drive +  "  &");
         cmdtxt.append("bin/install_proxy.sh NETBOOT &");
-        system(qPrintable(cmdtxt));
+        if(!system(qPrintable(cmdtxt)))
+            LOG(VB_GENERAL, LOG_ERR, "Error running install_proxy.sh NETBOOT");
+
     }
 
     WORKING_ON_INSTALL = true;
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/main.cpp b/abs/core/mythinstall/MythVantage-app/mythinstall/main.cpp
index b6e66cd..51cce48 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/main.cpp
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/main.cpp
@@ -5,9 +5,7 @@
 #include "password_manage.h"
 #include "autocard.h"
 #include "settemplate.h"
-
-
-
+#include "questionnotice.h"
 
 // Qt
 #include <QApplication>
@@ -15,15 +13,12 @@
 #include <QDir>
 #include <QTextStream>
 
-
 #include <cstdlib>
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <fcntl.h>
-#include <unistd.h>
-
-
-
+#include <chrono> // for milliseconds
+#include <thread> // for sleep_for
 
 #include <stdio.h>
 
@@ -39,13 +34,12 @@
 #include "commandlineparser.h"
 #include "mythlogging.h"
 #include "dialogbox.h"
-
+#include "signalhandling.h"
 
 // libmythui
 #include "mythmainwindow.h"
 #include "mythuihelper.h"
 
-
 //??
 #include "myththemebase.h"
 
@@ -254,9 +248,8 @@ int main(int argc, char **argv)
       bShowHelp = true;
 
     if (cmdline.toBool("readme"))
-    {
       bShowReadme = true;
-    }
+
     if (cmdline.toBool("question"))
     {
       bShowquestion = true;
@@ -267,11 +260,11 @@ int main(int argc, char **argv)
       bRunSetup = true;
 
     if (cmdline.toBool("show_lang"))
-        showLang = true;
+      showLang = true;
 
     LCD::SetupLCD();
     if (class LCD *lcd = LCD::Get())
-        lcd->switchToTime();
+      lcd->switchToTime();
 
 
     MythTranslation::load("mythfrontend");
@@ -300,14 +293,16 @@ int main(int argc, char **argv)
         gCoreContext->ActivateSettingsCache(false);
         gCoreContext->ClearSettingsCache();
         bool runconfig = false;
-        system("cp -f /etc/systemconfig /tmp/systemconfig.bak");
+        if (!system("cp -f /etc/systemconfig /tmp/systemconfig.bak"))
+            LOG(VB_GENERAL, LOG_ERR, "Could not backup /etc/systemconfig.");
         QString olddb = gCoreContext->GetSetting("HostMysqlserver");
         QString oldhostype = gCoreContext->GetSetting("HostSystemType");
 
         //sync db with pacman
         if (bShowplugins || bShowsoftware)
         {
-            system("pacman -Q > /tmp/pacman_installed");
+            if (!system("pacman -Q > /tmp/pacman_installed"))
+                LOG(VB_GENERAL, LOG_ERR, "Could not create /tmp/pacman_installed.");
             QString progPacmanNamesArray[] = {  "mythappletrailers",
                                                 "mytharchive",
                                                 "mythbrowser",
@@ -370,7 +365,7 @@ int main(int argc, char **argv)
                 QByteArray PacName = progPacmanNamesArray[i].toLocal8Bit();
                 const char *PacNameChar = PacName.data();
                 sprintf(cmd, "grep -q '%s ' /tmp/pacman_installed", PacNameChar);
-    
+
                 //LOG(VB_GENERAL, LOG_INFO, QString(progPacmanNamesArray[i]));
                 //LOG(VB_GENERAL, LOG_INFO, QString(progDBNamesArray[i]));
                 QString currDBValue = gCoreContext->GetSetting(progDBNamesArray[i]);
@@ -389,7 +384,8 @@ int main(int argc, char **argv)
                     runconfig = true;
                 }
             }
-            system("rm -f /tmp/pacman_installed");
+            if (!system("rm -f /tmp/pacman_installed"))
+                LOG(VB_GENERAL, LOG_ERR, "Could not remove /tmp/pacman_installed.");
         }
         //DONE sync db with pacman
 
@@ -401,7 +397,8 @@ int main(int argc, char **argv)
         //save my settings in case db switches
         QString cmdtxt=MV_ROOT;
         cmdtxt.append("bin/myth_settings_wrapper.sh -c save -t syssettings  -d " + olddb);
-        system(qPrintable(cmdtxt));
+        if (!system(qPrintable(cmdtxt)))
+            LOG(VB_GENERAL, LOG_ERR, "Could not save settings");
 
         if ( status != 0 )
         {
@@ -416,7 +413,8 @@ int main(int argc, char **argv)
             QString cmdtxt;
             cmdtxt=MV_ROOT;
             cmdtxt.append("bin/myth_settings_wrapper.sh -c save  -t  syssettings  -d " + olddb ) ;
-            system(qPrintable(cmdtxt));
+            if (!system(qPrintable(cmdtxt)))
+                LOG(VB_GENERAL, LOG_ERR, "Could not save settings");
         }
 
         if ( runconfig )
@@ -437,7 +435,9 @@ int main(int argc, char **argv)
 
 
         }
-        system("rm -f /tmp/systemconfig.bak");
+        if (!system("rm -f /tmp/systemconfig.bak"))
+            LOG(VB_GENERAL, LOG_ERR, "Could not remove /tmp/systemconfig.bak.");
+
         gCoreContext->ActivateSettingsCache(false);
         gCoreContext->ClearSettingsCache();
         if ( restart )
@@ -450,14 +450,16 @@ int main(int argc, char **argv)
             problems->append("\n");
             dia = new DialogBox(mainWindow, problems->append("\n" ));
             dia->AddButton(QObject::tr("OK"));
-            int returncode = 0;
-            returncode = dia->exec();
+            //int returncode = 0;
+            //returncode = dia->exec();
+            dia->exec();
             dia->deleteLater();
             //cout << "restarting" << endl;
             QString cmdtxt;
             cmdtxt=MV_ROOT  ;
             cmdtxt.append("bin/systemconfig.sh  reloadfe" );
-            system(qPrintable(cmdtxt));
+            if (!system(qPrintable(cmdtxt)))
+                LOG(VB_GENERAL, LOG_ERR, "Could not reload frontend.");
         }
         gCoreContext->ActivateSettingsCache(false);
         gCoreContext->ClearSettingsCache();
@@ -530,66 +532,42 @@ int main(int argc, char **argv)
 
     else if (bShowHelp)
     {
-        DialogBox *dia = NULL;
-        QString prompt;
-        QString *problems = new QString("LinHES Help");
-        problems->append("\n");
-        problems->append("Visit http://linhes.org for additional help.");
-        problems->append("\n");
-        problems->append("\n");
-        problems->append("------Keyboard Shortcuts---------------------------------");
-        problems->append("\n");
-        problems->append("Alt + h: This Screen");
-        problems->append("\n");
-#ifdef __MVAPP__
-        problems->append("F2: Open/Close Terminal");
-        problems->append("\n");
-        problems->append("Shift + Return: Open New Terminal (xterm)");
-        problems->append("\n");
-        problems->append("Alt + F2: Show 2nd desktop  Alt + F1 To Go Back");
-        problems->append("\n");
-        problems->append("Alt + c: Capture Myth Screenshot");
-        problems->append("\n");
-#else
-        problems->append("Alt + x: Open New Terminal (xterm)");
-        problems->append("\n");
-        problems->append("Alt + m: Open mythfrontend");
-        problems->append("\n");
-        problems->append("m in mythfrontend: Display Power/About Menu");
-        problems->append("\n");
-#endif
-        problems->append("Alt + 1: Start Master mythbackend");
-        problems->append("\n");
-        problems->append("Alt + 2: Stop Master mythbackend");
-        problems->append("\n");
-        problems->append("Alt + 3: Restart Master mythbackend");
-        problems->append("\n");
-        problems->append("Alt + s: Open mythtv-setup");
-        problems->append("\n");
-        problems->append("Alt + u: Unhide/Hide Mouse Pointer");
-        problems->append("\n");
-        problems->append("Alt + w: Open Web Browser (Chrome if installed)");
-        problems->append("\n");
-        problems->append("Alt + f: Restart Window Manager");
-        problems->append("\n");
+        QString line;
+        QString LH_HelpText;
+        QFile file("/usr/MythVantage/LH_HELP");
+        if ( file.open(QIODevice::ReadOnly | QIODevice::Text) )
+        {
+            QTextStream t( &file );        // use a text stream
+            while ( !t.atEnd() )
+            {
+                line = t.readLine();
+                LH_HelpText.append(line);
+                LH_HelpText.append("\n");
+            }
+            file.close();
+        }
+        else
+            LH_HelpText.append("Couldn't open /usr/MythVantage/LH_HELP");
 
+        MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
+        QuestionNoticeDialog *questionNotice = new QuestionNoticeDialog(mainStack,
+                                            "Notice");
+        if (questionNotice->Create("notice", "LinHES Help", LH_HelpText))
+            mainStack->AddScreen(questionNotice, true);
+        else
+            return -1;
+
+        do
+        {
+            qApp->processEvents();
+            std::this_thread::sleep_for(std::chrono::milliseconds(5));
+        } while (mainStack->TotalScreens() > 0);
 
-        dia = new DialogBox(mainWindow, problems->append("\n" ));
-        dia->AddButton(QObject::tr("OK"));
-        int returncode = 0;
-        returncode = dia->exec();
-        dia->deleteLater();
-        DestroyMythMainWindow();
-        delete gContext;
-        return returncode;
     }
     else if (bShowReadme)
     {
-        DialogBox *dia = NULL;
-        QString prompt;
         QString line;
-        QString *problems = new QString("");
-        problems->append("\n");
+        QString readmeText;
         QFile file("/usr/MythVantage/README");
         if ( file.open(QIODevice::ReadOnly | QIODevice::Text) )
         {
@@ -597,88 +575,72 @@ int main(int argc, char **argv)
             while ( !t.atEnd() )
             {
                 line = t.readLine();
-                problems->append(line);
-                problems->append("\n");
+                readmeText.append(line);
+                readmeText.append("\n");
             }
             file.close();
         }
         else
-            problems->append("Couldn't open file");
-        dia = new DialogBox(mainWindow, problems->append("\n" ));
-        dia->AddButton(QObject::tr("OK"));
-        int returncode = 0;
-        returncode = dia->exec();
-        dia->deleteLater();
-        DestroyMythMainWindow();
-        delete gContext;
-        return returncode;
-    }
+            readmeText.append("Couldn't open /usr/MythVantage/README");
 
+        MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
+        QuestionNoticeDialog *questionNotice = new QuestionNoticeDialog(mainStack,
+                                            "Notice");
+        if (questionNotice->Create("notice", "Welcome to LinHES!", readmeText))
+            mainStack->AddScreen(questionNotice, true);
+        else
+            return -1;
+
+        do
+        {
+            qApp->processEvents();
+            std::this_thread::sleep_for(std::chrono::milliseconds(5));
+        } while (mainStack->TotalScreens() > 0);
+    }
     else if (bShowquestion)
     {
         //LOG(VB_GENERAL, LOG_INFO, QString(question));
-        DialogBox *dia = NULL;
-        QString prompt;
-        QString *problems = new QString("");
-        problems->append("\n");
-        problems->append("\n");
-        problems->append(question);
-        dia = new DialogBox(mainWindow, problems->append("\n" ));
-        dia->AddButton(QObject::tr("Yes"));
-        dia->AddButton(QObject::tr("No"));
-        int returncode = 0;
+        extern int questionReturnCode; //as extern to be set in questionnotice.cpp
 
-        returncode = dia->exec();
-        dia->deleteLater();
-        DestroyMythMainWindow();
-        delete gContext;
+        MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
+        QuestionNoticeDialog *questionNotice = new QuestionNoticeDialog(mainStack,
+                                            "Question");
+        if (questionNotice->Create("question", "Question", question))
+            mainStack->AddScreen(questionNotice, true);
+        else
+            return -1;
 
-        return returncode;
+        do
+        {
+            qApp->processEvents();
+            std::this_thread::sleep_for(std::chrono::milliseconds(5));
+        } while (mainStack->TotalScreens() > 0);
+        retval = questionReturnCode;
     }
     else
     {
-        if (LanguageSelection::prompt(showLang)){
+        if (LanguageSelection::prompt(showLang))
+        {
             //taken from reloadTheme mythtv-setup
             MythTranslation::reload();
             GetMythMainWindow()->ReinitDone();
-
         }
 
         MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
         WelcomeDialog *welcome = new WelcomeDialog(mainStack, "Welcome");
         if (welcome->Create())
-        {
             mainStack->AddScreen(welcome, true);
-        }
         else
             return -1;
 
         do
         {
-
             qApp->processEvents();
-            usleep(5000);
+            std::this_thread::sleep_for(std::chrono::milliseconds(5));
         } while (mainStack->TotalScreens() > 0);
-
-
-       // DestroyMythMainWindow();
-   //     delete gContext;
-   //     gContext = NULL;
-   //     delete qApp;
-
     }
     DestroyMythMainWindow();
-
-    //gCoreContext->GetSetting("MasterServerIP");
-    //gCoreContext->GetSetting("BackendServerIP");
-
-
-
     delete gContext;
-    gContext = NULL ;
-    //delete qApp;
-
-    return 0;
+    SignalHandler::Done();
+    return retval;
 }
-
-
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/mythinstall.pro b/abs/core/mythinstall/MythVantage-app/mythinstall/mythinstall.pro
index f517c43..8dd6855 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/mythinstall.pro
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/mythinstall.pro
@@ -41,7 +41,7 @@ QMAKE_CLEAN += $(TARGET)
 //HEADERS += commandlineparser.h
 //SOURCES += main.cpp commandlineparser.cpp
 
-HEADERS += installdialog.h commandlineparser.h installsettings.h settemplate.h installationtype.h autocard.h xorgsettings.h password_manage.h misc_settings.h mv_common.h infrared.h compat-mv.h supplemental.h vnc.h fileshare.h
-SOURCES += main.cpp commandlineparser.cpp installdialog.cpp installsettings.cpp settemplate.cpp installationtype.cpp autocard.cpp xorgsettings.cpp password_manage.cpp misc_settings.cpp infrared.cpp compat-mv.cpp supplemental.cpp vnc.cpp fileshare.cpp
+HEADERS += installdialog.h commandlineparser.h installsettings.h settemplate.h installationtype.h autocard.h xorgsettings.h password_manage.h misc_settings.h mv_common.h infrared.h compat-mv.h supplemental.h vnc.h fileshare.h questionnotice.h
+SOURCES += main.cpp commandlineparser.cpp installdialog.cpp installsettings.cpp settemplate.cpp installationtype.cpp autocard.cpp xorgsettings.cpp password_manage.cpp misc_settings.cpp infrared.cpp compat-mv.cpp supplemental.cpp vnc.cpp fileshare.cpp questionnotice.cpp
 
 QT += sql xml network widgets
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.cpp b/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.cpp
new file mode 100755
index 0000000..529be89
--- /dev/null
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.cpp
@@ -0,0 +1,136 @@
+// ANSI C
+#include <cstdlib>
+
+// POSIX
+#include <unistd.h>
+
+// qt
+#include <QCoreApplication>
+#include <QKeyEvent>
+#include <QEvent>
+#include <QTimer>
+
+// myth
+#include "exitcodes.h"
+#include "mythcontext.h"
+#include "signalhandling.h"
+#include "questionnotice.h"
+
+int questionReturnCode;
+
+QuestionNoticeDialog::QuestionNoticeDialog(MythScreenStack *parent,
+    const char *name)
+    :MythScreenType(parent, name),
+    m_title_text(NULL), m_notice_text(NULL), m_question_text(NULL)
+{
+    gCoreContext->addListener(this);
+}
+
+bool QuestionNoticeDialog::Create(QString questionORnotice, QString title,
+                                  QString displayText)
+{
+    bool foundtheme = false;
+
+    // Load the theme for this screen
+    foundtheme = LoadWindowFromXML("install-ui.xml",
+                                   "questionnotice_screen", this);
+
+    if (!foundtheme)
+        return false;
+
+    bool err = false;
+
+    UIUtilE::Assign(this, m_title_text, "title", &err);
+    UIUtilE::Assign(this, m_notice_text, "notice_text", &err);
+    UIUtilE::Assign(this, m_ok_button, "ok_button", &err);
+    UIUtilE::Assign(this, m_question_text, "question_text", &err);
+    UIUtilE::Assign(this, m_yes_button, "yes_button", &err);
+    UIUtilE::Assign(this, m_no_button, "no_button", &err);
+
+    if (err)
+    {
+        LOG(VB_GENERAL, LOG_ERR,  "Cannot load screen 'questionnotice_screen'");
+        return false;
+    }
+
+    m_title_text->SetVisible(true);
+    m_title_text->SetText(title);
+
+    //LOG(VB_GENERAL, LOG_INFO, QString(questionORnotice));
+    //LOG(VB_GENERAL, LOG_INFO, QString(displayText));
+
+    //show the correct text and buttons depending on questionORnotice
+    if (questionORnotice.contains("notice"))
+    {
+        m_notice_text->SetVisible(true);
+        m_notice_text->SetText(displayText);
+        m_ok_button->SetVisible(true);
+        m_question_text->SetVisible(false);
+        m_yes_button->SetVisible(false);
+        m_no_button->SetVisible(false);
+    }
+    else
+    {
+        m_notice_text->SetVisible(false);
+        m_ok_button->SetVisible(false);
+        m_question_text->SetVisible(true);
+        m_question_text->SetText(displayText);
+        m_yes_button->SetVisible(true);
+        m_no_button->SetVisible(true);
+    }
+
+    m_ok_button->SetText(tr("OK"));
+    connect(m_ok_button, SIGNAL(Clicked()),
+            this, SLOT(okButtonClick()));
+    m_yes_button->SetText(tr("Yes"));
+    connect(m_yes_button, SIGNAL(Clicked()),
+            this, SLOT(yesButtonClick()));
+    m_no_button->SetText(tr("No"));
+    connect(m_no_button, SIGNAL(Clicked()),
+            this, SLOT(noButtonClick()));
+
+    BuildFocusList();
+
+    return true;
+}
+
+void QuestionNoticeDialog::okButtonClick(void)
+{
+    // this makes sure the button appears to click properly
+    QTimer::singleShot(500, this, SLOT(okButton()));
+}
+
+void QuestionNoticeDialog::okButton(void)
+{
+    questionReturnCode = 0;
+    Close();
+}
+
+void QuestionNoticeDialog::yesButtonClick(void)
+{
+    // this makes sure the button appears to click properly
+    QTimer::singleShot(500, this, SLOT(yesButton()));
+}
+
+void QuestionNoticeDialog::yesButton(void)
+{
+    questionReturnCode = 16;
+    Close();
+}
+
+void QuestionNoticeDialog::noButtonClick(void)
+{
+    // this makes sure the button appears to click properly
+    QTimer::singleShot(500, this, SLOT(noButton()));
+}
+
+void QuestionNoticeDialog::noButton(void)
+{
+    questionReturnCode = 17;
+    Close();
+}
+
+QuestionNoticeDialog::~QuestionNoticeDialog()
+{
+    gCoreContext->removeListener(this);
+}
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.h b/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.h
new file mode 100755
index 0000000..a2c2c79
--- /dev/null
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.h
@@ -0,0 +1,43 @@
+#ifndef QUESIONNOTICEDIALOG_H_
+#define QUESIONNOTICEDIALOG_H_
+
+// qt
+#include <QDateTime>
+
+// libmythui
+#include "mythscreentype.h"
+#include "mythuibutton.h"
+#include "mythuitext.h"
+#include "mythdialogbox.h"
+
+class QuestionNoticeDialog : public MythScreenType
+{
+
+    Q_OBJECT
+
+public:
+    QuestionNoticeDialog(MythScreenStack *parent, const char *name);
+    ~QuestionNoticeDialog();
+
+    bool Create(QString questionORnotice, QString title, QString displayText);
+
+protected slots:
+    void yesButton(void);
+    void yesButtonClick(void);
+    void noButton(void);
+    void noButtonClick(void);
+    void okButton(void);
+    void okButtonClick(void);
+
+private:
+    //  GUI stuff
+    MythUIText    *m_title_text;
+    MythUIText    *m_notice_text;
+    MythUIButton  *m_ok_button;
+
+    MythUIText    *m_question_text;
+    MythUIButton  *m_yes_button;
+    MythUIButton  *m_no_button;
+};
+
+#endif
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/xorgsettings.h b/abs/core/mythinstall/MythVantage-app/mythinstall/xorgsettings.h
index 88f202c..ad62564 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/xorgsettings.h
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/xorgsettings.h
@@ -109,7 +109,6 @@ static HostComboBox *HostXres()
     gc->addSelection("Auto") ;
     gc->setHelpText(QObject::tr(""));
     system ("print_xorg_res.py");
-
     QFile file("/tmp/modelines");
     QString line;
     if ( file.open(QIODevice::ReadOnly | QIODevice::Text) )
diff --git a/abs/core/mythinstall/PKGBUILD b/abs/core/mythinstall/PKGBUILD
index 73c44fe..c51cbe5 100644
--- a/abs/core/mythinstall/PKGBUILD
+++ b/abs/core/mythinstall/PKGBUILD
@@ -1,10 +1,10 @@
 # Maintainer: Jams
 pkgname=mythinstall
-pkgver=8.5
-pkgrel=2
+pkgver=8.5.1
+pkgrel=1
 pkgdesc="LinHES installer/systemconfig GUI."
 arch=('i686' 'x86_64')
-depends=('mythtv>=29')
+depends=('mythtv>=29' 'LinHES-config')
 makedepends=('mythtv>=29')
 logofiles=`ls logo*.png`
 source=('install-ui.xml' $logofiles)
@@ -33,7 +33,7 @@ package() {
     done
 }
 
-md5sums=('39d6b7bd1ee305c5523a3cf66d4c2338'
+md5sums=('4e587d53e64cb9cda12b0133a1fe1831'
          'c4c26977b723a4b5d6435ede73051d1b'
          '27ce7f89a83864dfc5abe23c61964c0c'
          '3291ad55fe6d7884fc732313f1cc2924'
diff --git a/abs/core/mythinstall/install-ui.xml b/abs/core/mythinstall/install-ui.xml
index 45b5404..4c51ce9 100755
--- a/abs/core/mythinstall/install-ui.xml
+++ b/abs/core/mythinstall/install-ui.xml
@@ -147,4 +147,44 @@
 
     </window>
 
+
+    <window name="questionnotice_screen">
+
+        <textarea name="title" from="basetextarea">
+            <area>50,10,700,40</area>
+            <align>allcenter</align>
+            <value></value>
+        </textarea>
+
+        <textarea name="notice_text" from="basetextarea">
+            <multiline>yes</multiline>
+            <area>20,60,760,460</area>
+            <value></value>
+            <align>allcenter</align>
+        </textarea>
+
+        <textarea name="question_text" from="basetextarea">
+            <multiline>yes</multiline>
+            <area>20,60,760,460</area>
+            <value></value>
+            <align>allcenter</align>
+        </textarea>
+
+        <button name="yes_button" from="basebutton">
+            <position>20,540</position>
+            <value>Yes</value>
+        </button>
+
+        <button name="ok_button" from="basebutton">
+            <position>320,540</position>
+            <value>OK</value>
+        </button>
+
+        <button name="no_button" from="basebutton">
+            <position>630,540</position>
+            <value>No</value>
+        </button>
+
+    </window>
+
 </mythuitheme>
-- 
cgit v0.12


From 13a613f53db93a13464a34ad6622b1c7b60d6d70 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Thu, 14 Dec 2017 22:31:43 +0000
Subject: linhes-theme: update install-ui.xml with new mythui screens for
 mythinstall

---
 abs/core/linhes-theme/PKGBUILD       |  6 ++--
 abs/core/linhes-theme/install-ui.xml | 63 ++++++++++++++++++++++++++++++++++++
 2 files changed, 66 insertions(+), 3 deletions(-)

diff --git a/abs/core/linhes-theme/PKGBUILD b/abs/core/linhes-theme/PKGBUILD
index 0420f3e..916e44a 100755
--- a/abs/core/linhes-theme/PKGBUILD
+++ b/abs/core/linhes-theme/PKGBUILD
@@ -1,6 +1,6 @@
 pkgname=linhes-theme
-pkgver=8.5
-pkgrel=4
+pkgver=8.5.1
+pkgrel=1
 pkgdesc="Default LinHES MythTV theme"
 arch=('i686' 'x86_64')
 license=('GPL2')
@@ -120,7 +120,7 @@ md5sums=('2dca856c2a4d1f959473512c94e43b60'
          '81a2706cd36a16a1e0c54d87f3a0857b'
          '4125880d1739b196a8041ecc3d773ee2'
          '5a8fb2a5f0e657d52be6f0a6a006ce72'
-         '36952501471b05395e4f061557447b2f'
+         '18b8ca8815f083223b70af2807546a49'
          'bfc32b9fa5dca3d46dd6f365ecb449b5'
          '326a71eb795b322a9ea26f116d890c87'
          '8fcd0acc11f4db33a9442949fb1a293d'
diff --git a/abs/core/linhes-theme/install-ui.xml b/abs/core/linhes-theme/install-ui.xml
index 4e5f139..f006b05 100644
--- a/abs/core/linhes-theme/install-ui.xml
+++ b/abs/core/linhes-theme/install-ui.xml
@@ -122,4 +122,67 @@
 
     </window>
 
+    <window name="questionnotice_screen">
+
+        <textarea name="title" from="base_heading">
+            <value></value>
+        </textarea>
+
+        <shape name="questionnotice-backdrop" from="base_backdrop">
+            <area>115,36,1050,649</area>
+        </shape>
+
+        <shape name="questionnotice-backdrop-line" from="base_backdrop_line">
+            <area>116,37,1048,647</area>
+        </shape>
+
+        <shape name="questionnotice-top-line" from="base_highlight_line">
+            <area>117,38,1046,2</area>
+        </shape>
+
+        <shape name="questionnotice-bottom-line" from="base_highlight_line">
+            <area>117,681,1046,2</area>
+        </shape>
+
+        <shape name="questionnotice-left-line" from="base_highlight_vertical_line">
+            <area>117,40,2,641</area>
+        </shape>
+
+        <shape name="questionnotice-right-line" from="base_highlight_vertical_line">
+            <area>1161,40,2,641</area>
+        </shape>
+
+        <shape name="questionnotice-bottom-seperator-line" from="base_line">
+            <area>138,620,1004,2</area>
+        </shape>
+
+        <textarea name="notice_text" from="basetextarea">
+            <multiline>yes</multiline>
+            <area>138,58,1004,562</area>
+            <font>baselarge</font>
+            <value></value>
+            <align>top,hcenter</align>
+        </textarea>
+
+        <textarea name="question_text" from="notice_text">
+            <align>allcenter</align>
+        </textarea>
+
+        <button name="yes_button" from="base_button">
+            <area>233,632,350,40</area>
+            <value>Yes</value>
+        </button>
+
+        <button name="no_button" from="base_button">
+            <area>697,632,350,40</area>
+            <value>No</value>
+        </button>
+
+        <button name="ok_button" from="base_button">
+            <area>465,632,350,40</area>
+            <value>OK</value>
+        </button>
+
+    </window>
+
 </mythuitheme>
-- 
cgit v0.12


From 996617b3dfa3b9d328514d13bc7d9878365e9a59 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Fri, 15 Dec 2017 19:02:50 +0000
Subject: zilog-firmware: fix packaging

---
 abs/core/zilog-firmware/PKGBUILD | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/abs/core/zilog-firmware/PKGBUILD b/abs/core/zilog-firmware/PKGBUILD
index c779f78..87cc82b 100644
--- a/abs/core/zilog-firmware/PKGBUILD
+++ b/abs/core/zilog-firmware/PKGBUILD
@@ -1,14 +1,14 @@
 pkgname=zilog-firmware
 pkgver=1
-pkgrel=2
+pkgrel=3
 pkgdesc="Firmware for zilog blaster"
-arch=('i586' 'i686' 'x86_64')
+arch=('x86_64')
 url="http://www.blushingpenguin.com/mark/blog/?p=24"
 source=(http://www.blushingpenguin.com/mark/lmilk/haup-ir-blaster.bin)
 
-build() {
-  cd $startdir/src/
-  mkdir -p $startdir/pkg/lib/firmware
-  install -m0755  $startdir/src/haup-ir-blaster.bin $startdir/pkg/lib/firmware
+package() {
+  cd $srcdir/
+  mkdir -p $pkgdir/usr/lib/firmware
+  install -m0755  $srcdir/haup-ir-blaster.bin $pkgdir/usr/lib/firmware
 }
 md5sums=('1c117d591bbcb733690e1b7b36202490')
-- 
cgit v0.12


From 4f72f3e1acf3f3736387a44725901ad6af13018d Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Fri, 15 Dec 2017 19:10:48 +0000
Subject: nano: update to 2.9.1

---
 abs/core/nano/PKGBUILD | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/abs/core/nano/PKGBUILD b/abs/core/nano/PKGBUILD
index 0b809b3..07211fd 100644
--- a/abs/core/nano/PKGBUILD
+++ b/abs/core/nano/PKGBUILD
@@ -3,17 +3,17 @@
 # Contributor: Judd <judd@archlinux.org>
 
 pkgname=nano
-pkgver=2.8.1
+pkgver=2.9.1
 pkgrel=1
 pkgdesc="Pico editor clone with enhancements"
-arch=('i686' 'x86_64')
+arch=('x86_64')
 license=('GPL')
 url="http://www.nano-editor.org"
 groups=('base')
 depends=('ncurses' 'file' 'sh')
 backup=('etc/nanorc')
-source=(https://www.nano-editor.org/dist/v2.8/${pkgname}-${pkgver}.tar.gz{,.asc})
-sha256sums=('a48650dab5fc069bb953d020721b6c0f650969abf5a34a27dfd6f038215c5910'
+source=(https://www.nano-editor.org/dist/v2.9/${pkgname}-${pkgver}.tar.xz{,.asc})
+sha256sums=('6316d52d0d26af3e79a13dcb4db1c7a4aeac61b37fd9381e801a4189a2ecba7c'
             'SKIP')
 validpgpkeys=('8DA6FE7BFA7A418AB3CB2354BCB356DF91009FA7' # "Chris Allegretta <chrisa@asty.org>"
               'A7F6A64A67DA09EF92782DD79DF4862AF1175C5B' # "Benno Schulenberg <bensberg@justemail.net>"
-- 
cgit v0.12


From f0aab56ffb3976db3189ad94aea7c3c7fe341906 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Wed, 20 Dec 2017 16:40:30 +0000
Subject: linhes-theme: update install-ui.xml

---
 abs/core/linhes-theme/PKGBUILD                |  6 +++---
 abs/core/linhes-theme/install-ui.xml          |  4 ++--
 abs/core/linhes-theme/recordings-ui.xml.patch | 21 +++++++++++++++------
 3 files changed, 20 insertions(+), 11 deletions(-)

diff --git a/abs/core/linhes-theme/PKGBUILD b/abs/core/linhes-theme/PKGBUILD
index 916e44a..7d12dd6 100755
--- a/abs/core/linhes-theme/PKGBUILD
+++ b/abs/core/linhes-theme/PKGBUILD
@@ -1,6 +1,6 @@
 pkgname=linhes-theme
 pkgver=8.5.1
-pkgrel=1
+pkgrel=2
 pkgdesc="Default LinHES MythTV theme"
 arch=('i686' 'x86_64')
 license=('GPL2')
@@ -112,7 +112,7 @@ md5sums=('2dca856c2a4d1f959473512c94e43b60'
          '643e7d548587b8742ed5accb6d736257'
          'dd1e013e806efc26049ea89637a51f83'
          '9fe3371a8b964a7028126405cfaa330b'
-         '537e12f58ae8da81176d8b982ac9c783'
+         '958d25f7b932c923cf9f8376063eeb57'
          'a0b6733e4a6734a3c24e8dc3b0c14e74'
          '384871202030f41148536e2e89bb1801'
          '4d01487b534e45c631734501ec0da501'
@@ -120,7 +120,7 @@ md5sums=('2dca856c2a4d1f959473512c94e43b60'
          '81a2706cd36a16a1e0c54d87f3a0857b'
          '4125880d1739b196a8041ecc3d773ee2'
          '5a8fb2a5f0e657d52be6f0a6a006ce72'
-         '18b8ca8815f083223b70af2807546a49'
+         '274b6f8cb5cd82c5ce28422decd7754b'
          'bfc32b9fa5dca3d46dd6f365ecb449b5'
          '326a71eb795b322a9ea26f116d890c87'
          '8fcd0acc11f4db33a9442949fb1a293d'
diff --git a/abs/core/linhes-theme/install-ui.xml b/abs/core/linhes-theme/install-ui.xml
index f006b05..823b0dc 100644
--- a/abs/core/linhes-theme/install-ui.xml
+++ b/abs/core/linhes-theme/install-ui.xml
@@ -170,12 +170,12 @@
 
         <button name="yes_button" from="base_button">
             <area>233,632,350,40</area>
-            <value>Yes</value>
+            <value></value>
         </button>
 
         <button name="no_button" from="base_button">
             <area>697,632,350,40</area>
-            <value>No</value>
+            <value></value>
         </button>
 
         <button name="ok_button" from="base_button">
diff --git a/abs/core/linhes-theme/recordings-ui.xml.patch b/abs/core/linhes-theme/recordings-ui.xml.patch
index 77969dc..e70625a 100644
--- a/abs/core/linhes-theme/recordings-ui.xml.patch
+++ b/abs/core/linhes-theme/recordings-ui.xml.patch
@@ -1,5 +1,5 @@
---- recordings-ui.xml.orig	2016-11-16 20:12:29.390254787 +0000
-+++ recordings-ui.xml	2016-12-23 02:34:31.313887659 +0000
+--- recordings-ui.xml.orig	2017-12-19 19:51:38.610985722 +0000
++++ recordings-ui.xml	2017-12-19 19:51:28.052356436 +0000
 @@ -105,19 +105,11 @@
          </shape>
  
@@ -30,7 +30,15 @@
                          <multiline>yes</multiline>
                      </textarea>
                  </state>
-@@ -232,16 +225,16 @@
+@@ -218,6 +211,7 @@
+                    </textarea>
+                     <textarea name="shortstartdate" from="titlesubtitle">
+                         <area>720,0,80,30</area>
++                        <cutdown>no</cutdown>
+                         <align>right,vcenter</align>
+                     </textarea>
+                     <textarea name="filesize_str" from="base_text_font_state_extrasmall">
+@@ -232,16 +226,17 @@
                      <area>0,0,898,64</area>
                      <textarea name="titlesubtitle" from="base_text_font_state_small">
                          <area>8,2,694,24</area>
@@ -41,6 +49,7 @@
                      <textarea name="shortstartdate" from="titlesubtitle">
 -                        <area>720,3,80,24</area>
 +                        <area>720,2,80,24</area>
++                        <cutdown>no</cutdown>
                          <align>right,vcenter</align>
                      </textarea>
                      <textarea name="filesize_str" from="base_text_font_state_extrasmall">
@@ -51,7 +60,7 @@
                          <cutdown>no</cutdown>
                          <align>right,vcenter</align>
                      </textarea>
-@@ -579,20 +572,20 @@
+@@ -579,20 +574,20 @@
                          <align>allcenter</align>
                      </textarea>
                      <textarea name="s00e00" from="base_text_font_state_extrasmall">
@@ -75,7 +84,7 @@
                          <font state="normal">baseextrasmall</font>
                          <align>right,vcenter</align>
                      </textarea>
-@@ -606,57 +599,48 @@
+@@ -606,57 +601,48 @@
              </statetype>
          </buttonlist>
  
@@ -145,7 +154,7 @@
              <font>basesupersmallyellow</font>
              <align>allcenter</align>
              <template>Disk space:  %1</template>
-@@ -688,7 +672,7 @@
+@@ -688,7 +674,7 @@
          <textarea name="norecordings">
              <area>350,87,906,351</area>
              <font>basemedium</font>
-- 
cgit v0.12


From efee56822326dbb2e0cf40a8316212223b909229 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Wed, 20 Dec 2017 16:46:31 +0000
Subject: mythinstall: port mythtv-setup screen and reboot screen to MythUI.

add check for more system call failures

use the BusyPopup for configure
---
 .../mythinstall/commandlineparser.cpp              |   6 +-
 .../MythVantage-app/mythinstall/fileshare.cpp      |   2 +-
 .../MythVantage-app/mythinstall/installdialog.cpp  | 317 +++++++++------------
 .../MythVantage-app/mythinstall/installdialog.h    |  15 +-
 .../mythinstall/installsettings.cpp                |  28 +-
 .../MythVantage-app/mythinstall/main.cpp           | 161 ++++++-----
 .../MythVantage-app/mythinstall/mythinstall.pro    |   4 +-
 .../MythVantage-app/mythinstall/questionnotice.cpp |  12 +-
 .../MythVantage-app/mythinstall/questionnotice.h   |   3 +-
 .../MythVantage-app/mythinstall/settemplate.cpp    |   5 +-
 abs/core/mythinstall/PKGBUILD                      |   4 +-
 abs/core/mythinstall/install-ui.xml                |   4 +-
 12 files changed, 260 insertions(+), 301 deletions(-)

diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/commandlineparser.cpp b/abs/core/mythinstall/MythVantage-app/mythinstall/commandlineparser.cpp
index 7c8f4a2..7ac1788 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/commandlineparser.cpp
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/commandlineparser.cpp
@@ -29,16 +29,16 @@ void MythInstallCommandLineParser::LoadArguments(void)
         "Show readme", "");
 
     add("-H", "help", "",
-            "Show help screen", "");
+        "Show help screen", "");
 
     add("-Q", "question", "",
-                "Display question with yes/no", "");
+        "Display question with yes/no", "");
 
     add("-b", "run_mythsetup", "",
         "Ask to start mythtv setup", "");
 
     add("-L", "show_lang", "",
-    "On install show lang/country screen", "");
+        "On install show lang/country screen", "");
 
 
 
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/fileshare.cpp b/abs/core/mythinstall/MythVantage-app/mythinstall/fileshare.cpp
index d09efd7..03aaf40 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/fileshare.cpp
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/fileshare.cpp
@@ -230,7 +230,7 @@ public:
 };
 
 void smb_busy_box() {
-    system ("nmbscan -d  > /tmp/smbdomainlist & ");
+    myth_system ("nmbscan -d  > /tmp/smbdomainlist & ");
     QString msgtext="Searching for Windows Workgroups";
     int return_code;
     MythScreenStack *popupStack = GetMythMainWindow()->GetStack("popup stack");
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.cpp b/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.cpp
index a067f98..980fa17 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.cpp
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.cpp
@@ -4,15 +4,16 @@
 #include <fstream>
 
 #include "mythcontext.h"
-//#include "tv.h"
-//#include "uitypes.h"
 #include "installdialog.h"
 #include "installsettings.h"
 #include "installationtype.h"
 #include "mv_common.h"
+#include "questionnotice.h"
 #include "mythprogressdialog.h"
 
 #include <stdlib.h>
+#include <chrono> // for milliseconds
+#include <thread> // for sleep_for
 
 #include "mythversion.h"
 #include "mythsystemlegacy.h"
@@ -36,7 +37,6 @@ WelcomeDialog::WelcomeDialog(MythScreenStack *parent, const char *name)
     scheduled_text = "";
     install_text =  "";
     version_text = "";
-    I_AM_BUSY = false;
     WORKING_ON_INSTALL = false;
     current_hostname = "";
 
@@ -57,13 +57,9 @@ WelcomeDialog::WelcomeDialog(MythScreenStack *parent, const char *name)
             SLOT(updateTime()));
     m_timeTimer->start(1000);
 
-    reboot_box = NULL;
     m_menuPopup = NULL;
-    //QTimer::singleShot(6000, this, showPopup());
 
-   // JM
     QTimer::singleShot(1000, this, SLOT(showPopup()));
-
 }
 
 bool WelcomeDialog::Create(void)
@@ -103,11 +99,15 @@ void WelcomeDialog::shutdownNow(int rc)
 //     system("rm -f /tmp/.install_percent");
 //     system("rm -f /tmp/.install_error");
     if (rc == 1)
+    {
         if(!system("/sbin/halt"))
             LOG(VB_GENERAL, LOG_ERR, "Error running halt");
+    }
     else
+    {
         if(!system("/sbin/reboot"))
             LOG(VB_GENERAL, LOG_ERR, "Error running reboot");
+    }
 }
 
 void WelcomeDialog::runLIVECD(void)
@@ -125,8 +125,6 @@ void WelcomeDialog::runLIVECD(void)
     {
         showPopup();
     }
-
-
 }
 
 bool WelcomeDialog::keyPressEvent(QKeyEvent *event)
@@ -160,8 +158,7 @@ bool WelcomeDialog::keyPressEvent(QKeyEvent *event)
 //                QByteArray tmp = cmd.toAscii();
 //                QByteArray tmp = cmd;
 //                system(tmp);
-                if(!system(qPrintable(cmd)))
-                    LOG(VB_GENERAL, LOG_ERR, "Error running MythShutdownXTermCMD");
+                myth_system(qPrintable(cmd));
             }
         }
         else
@@ -230,8 +227,9 @@ void WelcomeDialog::updateScreen(void)
     QString cmdtxt;
     cmdtxt=MV_ROOT  ;
     cmdtxt.append("bin/install_proxy.sh " );
-    if(!system(qPrintable(cmdtxt)))
-        LOG(VB_GENERAL, LOG_ERR, "Error running install_proxy.sh");
+    int sysRet = system(qPrintable(cmdtxt));
+    if (sysRet < 0)
+        LOG(VB_GENERAL, LOG_ERR, "Error running install_proxy.sh in updateScreen");
     recording_text="Press MENU for Options";
     mythvantage_text=" ";
     error_text=" ";
@@ -278,6 +276,7 @@ void WelcomeDialog::updateScreen(void)
     }
     else
         mythvantage_text="";
+
     m_recording_text->SetText(recording_text);
     m_scheduled_text->SetText(scheduled_text);
     m_mv_text->SetText(mythvantage_text);
@@ -285,88 +284,40 @@ void WelcomeDialog::updateScreen(void)
     if ( install_drive != ""  )
         install_text = "";
 
-    m_status_text->SetText(install_text );
+    m_status_text->SetText(install_text);
 //    m_updateScreenTimer->start(UPDATE_SCREEN_INTERVAL, true);
     m_updateScreenTimer->start(UPDATE_SCREEN_INTERVAL);
     if ( scheduled_text == "Done" )
     {
-        Reboot_popup () ;
+        CloseBusyPopup();
+        m_updateScreenTimer->stop();
+        Reboot_popup();
     }
     // shows the busy box when configuring the system
     if ( scheduled_text == "Configuring system")
     {
         m_recording_text->SetText(" ");
-        if  ( ! I_AM_BUSY )
-            busy_box();
+        QString msgtext = "Configuring LinHES on host " ;
+        msgtext.append(current_hostname);
+        msgtext.append("...");
+        OpenBusyPopup(msgtext);
     }
 };
 
-void WelcomeDialog::busy_box(void)
-{
-    QString msgtext = "Please wait, configuring LinHES on host " ;
-    msgtext.append(current_hostname);
-    msgtext.append("...");
-    MythScreenStack *popupStack = GetMythMainWindow()->GetStack("popup stack");
-    MythUIBusyDialog *busyPopup = new MythUIBusyDialog(msgtext, popupStack,"installbusy");
-    if (busyPopup->Create())
-    {
-        popupStack->AddScreen(busyPopup, false);
-    }
-    else
-    {
-        delete busyPopup;
-        busyPopup = NULL;
-    }
-
-
-    while ( scheduled_text == "Configuring system" )
-    {
-        qApp->processEvents ();
-        usleep(900);
-        I_AM_BUSY = true;
-    }
-
-    if (busyPopup)
-    {
-        busyPopup->Close();
-        busyPopup = NULL;
-    }
-    I_AM_BUSY = false;
-}
-
 void WelcomeDialog::busy_find_oldsettings(void)
 {
-
-     QString msgtext = "Importing Old Settings..." ;
-     MythScreenStack *popupStack = GetMythMainWindow()->GetStack("popup stack");
-     MythUIBusyDialog *busyPopup = new MythUIBusyDialog(msgtext, popupStack,
-                                                        "importsettingsbusy");
-     if (busyPopup->Create())
-     {
-         popupStack->AddScreen(busyPopup, false);
-     }
-     else
-     {
-         delete busyPopup;
-         busyPopup = NULL;
-     }
+    QString msgtext = "Importing Old Settings..." ;
+    OpenBusyPopup(msgtext);
 
     int return_code = 0;
-    while (  return_code  == 0 )
+    while ( return_code == 0 )
     {
         qApp->processEvents ();
-        usleep(900);
-        I_AM_BUSY = true;
+        std::this_thread::sleep_for(std::chrono::microseconds(900));
         return_code = myth_system("ps -ef|grep install_proxy.sh|grep -v grep > /dev/null");
     }
 
-    if (busyPopup)
-    {
-        busyPopup->Close();
-        busyPopup = NULL;
-    }
-    I_AM_BUSY = false;
-
+    CloseBusyPopup();
 }
 
 
@@ -391,19 +342,6 @@ void WelcomeDialog::updateStatusMessage(void)
 
 void WelcomeDialog::showPopup(void)
 {
-
-//    if (m_menuPopup)
- //        return;
-//
-//     QString label = tr("MythVantage Menu");
-//     MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
-//     m_menuPopup = new MythDialogBox(label, mainStack, "menuPopup");
-//
-//     if (m_menuPopup->Create())
-//         mainStack->AddScreen(m_menuPopup);
-//
-//       m_menuPopup->SetReturnEvent(this, "action");
-
     MythScreenStack *popupStack = GetMythMainWindow()->GetMainStack();
 
     m_menuPopup = new MythDialogBox("Menu", popupStack, "actionmenu");
@@ -420,7 +358,7 @@ void WelcomeDialog::showPopup(void)
     // This is a bad way to lock the buttons but it works for now.
     if ( scheduled_text.length() <= 2  )
     {
-        m_menuPopup->AddButton(tr("Install or Upgrade "),
+        m_menuPopup->AddButton(tr("Install or Upgrade"),
                                SLOT(Display_2ndpopup()));
         m_menuPopup->AddButton(tr("Run MythFrontend"),
                                SLOT(runLIVECD()));
@@ -515,7 +453,7 @@ QString WelcomeDialog::diskmodel(QString drive ,  QString tsize)
     return qline;
 }
 
-QString WelcomeDialog::findinstallsouce(void)
+QString WelcomeDialog::findinstallsource(void)
 {
     string line;
     QString currentitem;
@@ -542,6 +480,7 @@ QString WelcomeDialog::findinstallsouce(void)
             return currentitem;
         };
     }
+    return NULL;
 };
 
 void WelcomeDialog::showPopup_2(void)
@@ -566,7 +505,7 @@ void WelcomeDialog::showPopup_2(void)
     if ( NETBOOT   == "YES" )
         m_menuPopup->AddButton(("Diskless Frontend"), SLOT(install_net() ) );
 
-    QString  INSTALLSOURCE = findinstallsouce();
+    QString INSTALLSOURCE = findinstallsource();
     ifstream partitions("/proc/partitions");
     if (partitions.is_open())
     {
@@ -633,38 +572,46 @@ void WelcomeDialog::GO_popup(QString go_text)
 
 
 void WelcomeDialog::Reboot_popup(void)
-{   if (reboot_box)
-        return;
+{
     QString prompt1;
     QFile updbstatus("/tmp/.upgrade_db_failed");
     if ( updbstatus.open(QIODevice::ReadOnly | QIODevice::Text) )
     {
-        prompt1 = QObject::tr(" ");
-        prompt1.append("\n");
-        prompt1.append("An error occured while attempting to restore the database!");
-        prompt1.append("\n");
-        prompt1.append("The old database could not be restored, so a new database was created");
+        prompt1 = QObject::tr("An error occured while attempting to restore the database.");
         prompt1.append("\n");
+        prompt1.append("The old database could not be restored, so a new database was created.");
     }
     else
         prompt1 = QObject::tr("Installation of LinHES is complete!");
-        prompt1.append("\n");
 
-    reboot_box = new DialogBox(GetMythMainWindow(),  prompt1);
-    reboot_box->AddButton(QObject::tr("Reboot"));
-    reboot_box->AddButton(QObject::tr("Power Off"));
+    //as extern to be set in questionnotice.cpp
+    extern int questionReturnCode;
 
-    int returncode = 0;
-    DialogCode  dcode = reboot_box->exec();
-    reboot_box->deleteLater();
-    if (kDialogCodeButton0 ==  dcode )
+    MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
+    QuestionNoticeDialog *questionNotice =
+                        new QuestionNoticeDialog(mainStack, "Question");
+    if (questionNotice->Create("question", "Installation Complete", prompt1,
+        "Reboot", "Shutdown")) mainStack->AddScreen(questionNotice, true);
+    else
+        return;
+
+    do
+    {
+        qApp->processEvents();
+        std::this_thread::sleep_for(std::chrono::milliseconds(5));
+    } while (mainStack->TotalScreens() > 1);
+
+    int returncode;
+    if (questionReturnCode == 16)
+    {
+        LOG(VB_GENERAL, LOG_INFO, "Reboot");
         returncode = 0;
-    if (kDialogCodeButton1 == dcode )
+    }
+    else
+    {
+        LOG(VB_GENERAL, LOG_INFO, "Shutdown");
         returncode = 1;
-    if (kDialogCodeButton2 == dcode )
-        returncode = 2;
-
-    reboot_box = NULL;
+    }
     shutdownNow(returncode);
 }
 
@@ -672,18 +619,11 @@ void WelcomeDialog::Reboot_popup(void)
 
 void WelcomeDialog::MAINPopup(void)
 {
-//      if (!popup)
-//          return;
-//      popup->hide();
-//     popup->deleteLater();
-    popup = NULL;
     showPopup();
-
 }
 
 void WelcomeDialog::Display_2ndpopup(void)
 {
-    //JM VERBOSE(VB_GENERAL, "Display_2ndpopup");
     showPopup_2();
 }
 
@@ -869,7 +809,8 @@ void WelcomeDialog::install_generic(void)
             QString cmdtxt;
             cmdtxt=MV_ROOT  ;
             cmdtxt.append("bin/install_proxy.sh find_update " +  install_drive +" &");
-            if(!system(qPrintable(cmdtxt)))
+            int sysRet = system(qPrintable(cmdtxt));
+            if (sysRet < 0)
                 LOG(VB_GENERAL, LOG_ERR, "Could not run install_proxy.sh find update");
             busy_find_oldsettings();
             bool flag = false;
@@ -955,7 +896,7 @@ void WelcomeDialog::install_generic(void)
 
 void busy_network(void)
 {
-    QString msgtext = "Starting Network" ;
+    QString msgtext = "Starting Network..." ;
     MythScreenStack *popupStack = GetMythMainWindow()->GetStack("popup stack");
     MythUIBusyDialog *busyPopup = new MythUIBusyDialog(msgtext, popupStack,"installbusy");
     if (busyPopup->Create())
@@ -969,10 +910,10 @@ void busy_network(void)
     }
 
     int return_code = 0;
-    while (  return_code  == 0 )
+    while ( return_code  == 0 )
     {
         qApp->processEvents ();
-        usleep(900);
+        std::this_thread::sleep_for(std::chrono::microseconds(900));
         return_code = myth_system("ps -ef|grep install_proxy.sh| grep setup_network |grep -v grep > /dev/null");
     }
 
@@ -981,9 +922,6 @@ void busy_network(void)
         busyPopup->Close();
         busyPopup = NULL;
     }
-
-
-
 }
 
 
@@ -1000,28 +938,62 @@ int  WelcomeDialog::ask_validate_network(void)
         {
             MythProgressDialog *network_check = NULL;
             network_check = new MythProgressDialog(QObject::tr("Please wait while the network is checked..."), 7);
+            //busy_network();
+            QString msgtext = "Starting Network..." ;
+            MythScreenStack *popupStack = GetMythMainWindow()->GetStack(
+                                        "popup stack");
+            m_progressDialog = new MythUIProgressDialog(msgtext, popupStack,
+                                        "networkbusy");
+            if (m_progressDialog->Create())
+            {
+                popupStack->AddScreen(m_progressDialog, false);
+            }
+            else
+            {
+                delete m_progressDialog;
+                m_progressDialog = NULL;
+            }
+
+            if (m_progressDialog)
+                m_progressDialog->SetTotal(6);
+
             QString cmdtxt;
-            cmdtxt=MV_ROOT  ;
-            cmdtxt.append("bin/install_proxy.sh network_check_it setup_network &");
+            cmdtxt=MV_ROOT;
+            cmdtxt.append("bin/install_proxy.sh network_check_it setup_network");
             retval = system(qPrintable(cmdtxt));
-            busy_network();
+
+            //int return_code = 0;
+            //while ( return_code  == 0 )
+            //{
+            //    qApp->processEvents ();
+            //    std::this_thread::sleep_for(std::chrono::microseconds(900));
+            //    return_code = myth_system("ps -ef|grep install_proxy.sh| grep setup_network |grep -v grep > /dev/null");
+            //}
+
+
             if (network_check)
             {
                 network_check->setProgress(2);
-                cmdtxt=MV_ROOT  ;
+            if ( retval == 0)
+            {
+                m_progressDialog->SetMessage("Checking Network for this Computer...");
+                m_progressDialog->SetProgress(2);
+                cmdtxt=MV_ROOT;
                 cmdtxt.append("bin/install_proxy.sh network_check_it check_self");
                 retval = system(qPrintable(cmdtxt));
-                if ( retval != 0 )
-                {
-                    network_check->Close();
-                    pop_text="Could not find myself on the network.";
-                }
+                    if ( retval != 0 )
+                    {
+                        network_check->Close();
+                        pop_text="Could not find myself on the network.";
+                    }
+            }
             }
-
             if ( retval == 0)
             {
                 network_check->setProgress(3);
-                cmdtxt=MV_ROOT  ;
+                m_progressDialog->SetMessage("Checking Network for the Gateway Server...");
+                m_progressDialog->SetProgress(3);
+                cmdtxt=MV_ROOT;
                 cmdtxt.append("bin/install_proxy.sh network_check_it check_gw");
                 retval = system(qPrintable(cmdtxt));
                 if ( retval != 0 )
@@ -1034,7 +1006,9 @@ int  WelcomeDialog::ask_validate_network(void)
             if (retval == 0)
             {
                 network_check->setProgress(4);
-                cmdtxt=MV_ROOT  ;
+                m_progressDialog->SetMessage("Checking Network for the Nameserver...");
+                m_progressDialog->SetProgress(4);
+                cmdtxt=MV_ROOT;
                 cmdtxt.append("bin/install_proxy.sh network_check_it check_ns");
                 retval = system(qPrintable(cmdtxt));
                 if ( retval != 0 )
@@ -1047,7 +1021,9 @@ int  WelcomeDialog::ask_validate_network(void)
             if (retval == 0)
             {
                 network_check->setProgress(5);
-                cmdtxt=MV_ROOT  ;
+                m_progressDialog->SetMessage("Checking the Nameserver...");
+                m_progressDialog->SetProgress(5);
+                cmdtxt=MV_ROOT;
                 cmdtxt.append("bin/install_proxy.sh network_check_it check_names");
                 retval = system(qPrintable(cmdtxt));
                 if ( retval != 0 )
@@ -1060,7 +1036,9 @@ int  WelcomeDialog::ask_validate_network(void)
             if (retval == 0)
             {
                 network_check->setProgress(6);
-                cmdtxt=MV_ROOT  ;
+                m_progressDialog->SetMessage("Checking Network for this Hostname...");
+                m_progressDialog->SetProgress(6);
+                cmdtxt=MV_ROOT;
                 cmdtxt.append("bin/install_proxy.sh network_check_it host_names");
                 retval = system(qPrintable(cmdtxt));
                 if ( retval != 0 )
@@ -1070,6 +1048,11 @@ int  WelcomeDialog::ask_validate_network(void)
                 }
             }
 
+            if (m_progressDialog)
+            {
+                m_progressDialog->Close();
+                m_progressDialog = NULL;
+            }
             network_check->setProgress(7);
             if (network_check)
             {
@@ -1077,7 +1060,7 @@ int  WelcomeDialog::ask_validate_network(void)
                 network_check->deleteLater();
             }
 
-            if (retval != 0 )
+            if ( retval != 0 )
             {
                 DialogCode val = MythPopupBox::Show2ButtonPopup(
                                                     GetMythMainWindow(),
@@ -1085,7 +1068,7 @@ int  WelcomeDialog::ask_validate_network(void)
                                                     tr("Continue"),
                                                     tr("Try Again"),
                                                     kDialogCodeButton0);
-                if (kDialogCodeButton0 == val )
+                if ( kDialogCodeButton0 == val )
                     retval = 0;
             }
         }
@@ -1096,37 +1079,14 @@ int  WelcomeDialog::ask_validate_network(void)
 
 void WelcomeDialog::install_it(void)
 {
+    int sysRet;
     QString installtype = gCoreContext->GetSetting("HOSTinstallationtype");
-//     QString rootfs = gCoreContext->GetSetting("HOSTrootfstype");
-//     QString datafs = gCoreContext->GetSetting("HOSTdatafstype");
-//     QString rootsize = gCoreContext->GetSetting("HOSTOSsize");
-//     rootsize=rootsize + "000";
-//     QString usealldata = gCoreContext->GetSetting("HostUseALLdata");
-//     QString datasize = gCoreContext->GetSetting("HOSTDATAsize");
-//     QString uprootfs = gCoreContext->GetSetting("HOSTuprootfstype");
-//     QString useswap = gCoreContext->GetSetting("HostUseSWAP");
-//     QString swapsize = gCoreContext->GetSetting("HOSTSWAPsize");
     if ( installtype != "Upgrade"  )
         current_hostname = gCoreContext->GetSetting("HostMyhostname");
     QString clean_upgrade = getenv("CLEAN_UPGRADE");
     if ( clean_upgrade == "YES" )
         current_hostname = gCoreContext->GetSetting("HostMyhostname");
 
-//get the hostname here if upgrade then use previous declarion of hostname
-//     if ( usealldata == "1" )
-//     {
-//         datasize="ALL";
-//     }
-//     else
-//     {
-//         datasize=datasize + "000";
-//     }
-//     if ( useswap == "0" )
-//     {
-//         swapsize="NO";
-//     };
-
-
     if ( installtype == "Full/Auto" )
     {
         QString currentitem;
@@ -1143,32 +1103,22 @@ void WelcomeDialog::install_it(void)
             }
         }
         file.close();
-//        bool ok;
-//        int mem = currentitem.toInt( &ok, 10 );     // dec == 0, ok == FALSE
-
-
-//         if ( mem >= 500000 )
-//         {
-//             if ((gCoreContext->GetSetting("HostXres"))  == "1280x720" )
-//                 gCoreContext->SaveSetting("Theme", "syth-lacquer-wide");
-//         }
-
 
         QString cmdtxt=MV_ROOT  ;
         //cmdtxt.append("bin/install_proxy.sh full_install_it " + install_drive + " " + rootfs + " " + rootsize + " " +  datafs + " " + datasize + " " + swapsize + "&");
         cmdtxt.append("bin/install_proxy.sh full_install_it &");
-        if(!system(qPrintable(cmdtxt)))
+        sysRet = system(qPrintable(cmdtxt));
+        if (sysRet < 0)
             LOG(VB_GENERAL, LOG_ERR, "Error running install_proxy.sh full_install_it");
-
     }
     else if  ( installtype == "Upgrade" )
     {
         QString cmdtxt=MV_ROOT  ;
         //cmdtxt.append("bin/install_proxy.sh upgrade_it " + install_drive + " " + uprootfs +  "&");
         cmdtxt.append("bin/install_proxy.sh upgrade_it &");
-        if(!system(qPrintable(cmdtxt)))
+        sysRet = system(qPrintable(cmdtxt));
+        if (sysRet < 0)
             LOG(VB_GENERAL, LOG_ERR, "Error running install_proxy.sh upgrade_it");
-
     }
     else if (installtype=="NET")
     {
@@ -1185,20 +1135,21 @@ void WelcomeDialog::install_it(void)
         QString h;
         h=localhostname;
         cmdtxt.append("bin/restore_default_settings.sh -c save -t syssettings  -d  127.0.0.1  -h " + h);
-        if(!system(qPrintable(cmdtxt)))
+        sysRet = system(qPrintable(cmdtxt));
+        if (sysRet < 0)
             LOG(VB_GENERAL, LOG_ERR, "Error running restore_default_settings.sh");
 
         cmdtxt=MV_ROOT  ;
         //cmdtxt.append("bin/install_proxy.sh NETBOOT  " + install_drive +  "  &");
         cmdtxt.append("bin/install_proxy.sh NETBOOT &");
-        if(!system(qPrintable(cmdtxt)))
+        sysRet = system(qPrintable(cmdtxt));
+        if (sysRet < 0)
             LOG(VB_GENERAL, LOG_ERR, "Error running install_proxy.sh NETBOOT");
-
     }
 
     WORKING_ON_INSTALL = true;
-    usleep (500);
+    std::this_thread::sleep_for(std::chrono::microseconds(500));
     updateScreen();
-    usleep (500);
+    std::this_thread::sleep_for(std::chrono::microseconds(500));
     updateScreen();
 }
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.h b/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.h
index 432ea19..d256ef2 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.h
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/installdialog.h
@@ -9,8 +9,6 @@ using namespace std;
 #include "mythdialogs.h"
 #include "libmyth/dialogbox.h"
 
-
-
 #include "remoteutil.h"
 #include "programinfo.h"
 #include "mythscreentype.h"
@@ -18,6 +16,7 @@ using namespace std;
 #include "mythuitext.h"
 #include "mythdialogbox.h"
 #include "langsettings.h"
+#include <mythprogressdialog.h>
 
 class WelcomeDialog : public MythScreenType
 {
@@ -42,7 +41,7 @@ protected slots:
     void Reboot_popup();
     void MAINPopup();
     QString diskmodel(QString,QString);
-    QString findinstallsouce(void);
+    QString findinstallsource(void);
     void Display_2ndpopup();
     bool updateRecordingList(void);
     bool updateScheduledList(void);
@@ -61,19 +60,15 @@ protected slots:
     void install_generic(void);
     void install_it(void);
     void runLIVECD(void);
-    void busy_box(void);
     void busy_find_oldsettings(void);
     int ask_validate_network(void);
 private:
     void updateStatusMessage(void);
-
-    MythPopupBox *popup;   //can remove this
-    MythDialogBox *m_menuPopup;
-    DialogBox *reboot_box;
-    DialogBox *upgrade_box;
     //
     //  GUI stuff
     //
+    MythDialogBox *m_menuPopup;
+    MythUIProgressDialog  *m_progressDialog;
 
     MythUIText    *m_status_text;
     MythUIText    *m_recording_text;
@@ -102,9 +97,7 @@ private:
     string         bin_prefix;
     QString        current_hostname;
 
-    bool          I_AM_BUSY;
     bool          WORKING_ON_INSTALL;
-
 };
 
 #endif
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/installsettings.cpp b/abs/core/mythinstall/MythVantage-app/mythinstall/installsettings.cpp
index aa599ee..5eb8717 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/installsettings.cpp
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/installsettings.cpp
@@ -162,7 +162,9 @@ QString findnet_wireless()
 
     QString netdev="";
 //QString netdev="eth0 eth1 wlan0 wlan1 ath0 ";
-    system("/usr/sbin/iwconfig  > /tmp/.netinfo_wireless");
+    int sysRet = system("/usr/sbin/iwconfig  > /tmp/.netinfo_wireless");
+    if (sysRet < 0)
+        LOG(VB_GENERAL, LOG_ERR, "Error running iwconfig");
     QString line;
     QFile file("/tmp/.netinfo_wireless");
     if ( file.open(QIODevice::ReadOnly | QIODevice::Text) )
@@ -1174,7 +1176,7 @@ static HostComboBox *Hostfoldingusername()
             if ((new_line = strchr (username, '\n')))
                 new_line[0] = 0;
 
-            std::cout << "found old username " << username << endl;
+            //std::cout << "found old username " << username << endl;
             //FIXME??
             //gCoreContext->SetSetting("Hostfoldingusername", username);
             gCoreContext->SaveSetting("Hostfoldingusername", username);
@@ -2372,7 +2374,7 @@ QString NetworkOptionsFrame::find_hostname()
     cmdtxt.append("bin/systemconfig.py -m dhcp_request -d " );
     cmdtxt.append(hostparm.ThisHostDefaultInterface);
     myth_system(cmdtxt);
-    system(qPrintable(cmdtxt));
+    //system(qPrintable(cmdtxt));
     QString line;
     QFile file("/tmp/mvnetwork.dhcpinfo");
     if ( file.open(QIODevice::ReadOnly | QIODevice::Text) )
@@ -2842,7 +2844,9 @@ void  SoundOSSsettings::loadossdriver()
     cmdtxt="sudo ";
     cmdtxt.append(MV_ROOT) ;
     cmdtxt.append("bin/soundconfig.sh -t LOAD  -i OSS &");
-    system(qPrintable(cmdtxt));
+    int sysRet = system(qPrintable(cmdtxt));
+    if (sysRet < 0)
+        LOG(VB_GENERAL, LOG_ERR, "Error running soundconfig.sh");
     int return_code = 0;
 
     QString msgtext = "Loading OSS driver" ;
@@ -2903,7 +2907,9 @@ void  SoundALSAsettings::loadalsadriver()
     cmdtxt="sudo ";
     cmdtxt.append(MV_ROOT) ;
     cmdtxt.append("bin/soundconfig.sh -t LOAD  -i ALSA &");
-    system(qPrintable(cmdtxt));
+    int sysRet = system(qPrintable(cmdtxt));
+    if (sysRet < 0)
+        LOG(VB_GENERAL, LOG_ERR, "Error running soundconfig.sh");
     int return_code = 0;
 
     QString msgtext = "Loading ALSA driver" ;
@@ -3097,7 +3103,9 @@ void SoundOSSsettings::soundossgathersettings(void)
     QString cmdtxt;
     cmdtxt=MV_ROOT  ;
     cmdtxt.append("bin/soundconfig.sh -t test -i OSS -d " + hostparm.ThisHostSoundDevice + "&");
-    system(qPrintable(cmdtxt));
+    int sysRet = system(qPrintable(cmdtxt));
+    if (sysRet < 0)
+        LOG(VB_GENERAL, LOG_ERR, "Error running soundconfig.sh");
     int return_code = 0;
     QString msgtext = "Playing Test Audio" ;
 
@@ -3162,7 +3170,9 @@ void SoundALSAsettings::soundalsagathersettings(void)
     QString cmdtxt;
     cmdtxt=MV_ROOT  ;
     cmdtxt.append("bin/soundconfig.sh -t test -i ALSA -d " + hostparm.ThisHostSoundDevice + "&");
-    system(qPrintable(cmdtxt));
+    int sysRet = system(qPrintable(cmdtxt));
+    if (sysRet < 0)
+        LOG(VB_GENERAL, LOG_ERR, "Error running soundconfig.sh");
     int return_code = 0;
     QString msgtext = "Playing Test Audio" ;
     MythScreenStack *popupStack = GetMythMainWindow()->GetStack("popup stack");
@@ -3531,7 +3541,9 @@ int runsettings (bool mysqlonly , bool shownetwork , bool showhostype,
     if ( showhostype && continuerun )
     {
         displayshowhostype = showhostype;
-        system ("avahi-browse -l -r  -t  _mysql._tcp > /tmp/mysqllist");
+        int sysRet = system("avahi-browse -l -r  -t  _mysql._tcp > /tmp/mysqllist");
+        if (sysRet < 0)
+            LOG(VB_GENERAL, LOG_ERR, "Error running avahi-browse");
         MythInstallSettings settings1;
         settings1.Load();
         settings1.Save();
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/main.cpp b/abs/core/mythinstall/MythVantage-app/mythinstall/main.cpp
index 51cce48..5c2e128 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/main.cpp
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/main.cpp
@@ -3,7 +3,6 @@
 #include "installdialog.h"
 #include "installsettings.h"
 #include "password_manage.h"
-#include "autocard.h"
 #include "settemplate.h"
 #include "questionnotice.h"
 
@@ -33,7 +32,6 @@
 #include "lcddevice.h"
 #include "commandlineparser.h"
 #include "mythlogging.h"
-#include "dialogbox.h"
 #include "signalhandling.h"
 
 // libmythui
@@ -100,25 +98,25 @@ int main(int argc, char **argv)
     MythInstallCommandLineParser cmdline;
     int retval;
     if ((retval = cmdline.ConfigureLogging()) != GENERIC_EXIT_OK)
-         return retval;
+        return retval;
 
     if (!cmdline.Parse(argc, argv))
     {
-      cmdline.PrintHelp();
-      return 4;
-      return GENERIC_EXIT_INVALID_CMDLINE;
+        cmdline.PrintHelp();
+        return 4;
+        return GENERIC_EXIT_INVALID_CMDLINE;
     }
 
     if (cmdline.toBool("showhelp"))
     {
-          cmdline.PrintHelp();
-          return GENERIC_EXIT_OK;
+        cmdline.PrintHelp();
+        return GENERIC_EXIT_OK;
     }
 
     if (cmdline.toBool("showversion"))
     {
-      cmdline.PrintVersion();
-      return GENERIC_EXIT_OK;
+        cmdline.PrintVersion();
+        return GENERIC_EXIT_OK;
     }
 //--------------------Start of real stuff---------------------
     gContext = new MythContext(MYTH_BINARY_VERSION);
@@ -293,7 +291,8 @@ int main(int argc, char **argv)
         gCoreContext->ActivateSettingsCache(false);
         gCoreContext->ClearSettingsCache();
         bool runconfig = false;
-        if (!system("cp -f /etc/systemconfig /tmp/systemconfig.bak"))
+        int sysRet=system("cp -f /etc/systemconfig /tmp/systemconfig.bak");
+        if (sysRet < 0)
             LOG(VB_GENERAL, LOG_ERR, "Could not backup /etc/systemconfig.");
         QString olddb = gCoreContext->GetSetting("HostMysqlserver");
         QString oldhostype = gCoreContext->GetSetting("HostSystemType");
@@ -384,7 +383,8 @@ int main(int argc, char **argv)
                     runconfig = true;
                 }
             }
-            if (!system("rm -f /tmp/pacman_installed"))
+            int sysRet=system("rm -f /tmp/pacman_installed");
+            if (sysRet < 0)
                 LOG(VB_GENERAL, LOG_ERR, "Could not remove /tmp/pacman_installed.");
         }
         //DONE sync db with pacman
@@ -397,7 +397,8 @@ int main(int argc, char **argv)
         //save my settings in case db switches
         QString cmdtxt=MV_ROOT;
         cmdtxt.append("bin/myth_settings_wrapper.sh -c save -t syssettings  -d " + olddb);
-        if (!system(qPrintable(cmdtxt)))
+        sysRet=system(qPrintable(cmdtxt));
+        if (sysRet < 0)
             LOG(VB_GENERAL, LOG_ERR, "Could not save settings");
 
         if ( status != 0 )
@@ -413,7 +414,8 @@ int main(int argc, char **argv)
             QString cmdtxt;
             cmdtxt=MV_ROOT;
             cmdtxt.append("bin/myth_settings_wrapper.sh -c save  -t  syssettings  -d " + olddb ) ;
-            if (!system(qPrintable(cmdtxt)))
+            int sysRet=system(qPrintable(cmdtxt));
+            if (sysRet < 0)
                 LOG(VB_GENERAL, LOG_ERR, "Could not save settings");
         }
 
@@ -431,42 +433,45 @@ int main(int argc, char **argv)
             QString dbcommand = cmdtxt;
             dbcommand.append(newdb);
             run_systemconfig(modulelist,restart,dbcommand);
-
-
-
         }
-        if (!system("rm -f /tmp/systemconfig.bak"))
+        sysRet=system("rm -f /tmp/systemconfig.bak");
+        if (sysRet < 0)
             LOG(VB_GENERAL, LOG_ERR, "Could not remove /tmp/systemconfig.bak.");
 
         gCoreContext->ActivateSettingsCache(false);
         gCoreContext->ClearSettingsCache();
         if ( restart )
         {
-            DialogBox *dia = NULL;
             QString prompt;
-            QString *problems = new QString("The network address of the database has changed.");
-            problems->append("\n");
-            problems->append("The frontend will need to restart to connect to the new database.");
-            problems->append("\n");
-            dia = new DialogBox(mainWindow, problems->append("\n" ));
-            dia->AddButton(QObject::tr("OK"));
-            //int returncode = 0;
-            //returncode = dia->exec();
-            dia->exec();
-            dia->deleteLater();
-            //cout << "restarting" << endl;
+            prompt.append("The network address of the database has changed.");
+            prompt.append("\n");
+            prompt.append("The frontend will need to restart to connect to the new database.");
+            prompt.append("\n");
+
+            MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
+            QuestionNoticeDialog *questionNotice =
+                            new QuestionNoticeDialog(mainStack, "Notice");
+            if (questionNotice->Create("notice", "Restart Frontend", prompt,
+                NULL, NULL)) mainStack->AddScreen(questionNotice, true);
+            else
+                return -1;
+
+            do
+            {
+                qApp->processEvents();
+                std::this_thread::sleep_for(std::chrono::milliseconds(5));
+            } while (mainStack->TotalScreens() > 0);
+
             QString cmdtxt;
-            cmdtxt=MV_ROOT  ;
+            cmdtxt=MV_ROOT;
             cmdtxt.append("bin/systemconfig.sh  reloadfe" );
-            if (!system(qPrintable(cmdtxt)))
+            int sysRet=system(qPrintable(cmdtxt));
+            if (sysRet < 0)
                 LOG(VB_GENERAL, LOG_ERR, "Could not reload frontend.");
         }
         gCoreContext->ActivateSettingsCache(false);
         gCoreContext->ClearSettingsCache();
         gCoreContext->SendMessage("CLEAR_SETTINGS_CACHE");
-
-
-
     }//run settings
 
     else if (bShowTemplate)
@@ -487,49 +492,47 @@ int main(int argc, char **argv)
 
     else if (bRunSetup)
     {
-        DialogBox *dia = NULL;
         QString prompt;
-        QString *problems = new QString("To configure the TV cards and program guide the setup program needs to be run.");
-        problems->append("\n");
-        problems->append("\n");
-
-        problems->append("For those in North America, guide data is provided by Schedules Direct.");
-        problems->append("\n");
-        problems->append("Visit  http://www.schedulesdirect.org/  to signup for your account today");
-        problems->append("\n");
-        problems->append("\n");
-        problems->append("\n");
-
-        problems->append("If you choose to not run mythtv-setup now, the program can be run at any time by typing mythtv-setup or hitting ALT+s");
-        problems->append("\n");
-
-        problems->append("\n");
-        prompt = QObject::tr("Do you wish to run mythtv-setup ?");
-
-        dia = new DialogBox(mainWindow, problems->append("\n" + prompt));
-        dia->AddButton(QObject::tr("Yes"));
-        dia->AddButton(QObject::tr("Yes and try to autodetect cards"));
-        dia->AddButton(QObject::tr("No"));
-        int returncode = 0;
-        returncode = dia->exec();
-        DialogCode dcode = dia->exec();
-        dia->deleteLater();
-        if (kDialogCodeButton0 == dcode )
-            returncode = 0;
-        if (kDialogCodeButton1 == dcode )
-            returncode = 1;
-        if (kDialogCodeButton2 == dcode )
-            returncode = 2;
-/*
-        if (returncode == 1)
+        prompt.append("To configure the TV tuner cards and program guide, run  mythtv-setup.");
+        prompt.append("\n");
+        prompt.append("\n");
+        prompt.append("For those in North America, guide data is provided by Schedules Direct.");
+        prompt.append("\n");
+        prompt.append("Visit  http://www.schedulesdirect.org/  and signup for your account.");
+        prompt.append("\n");
+        prompt.append("\n");
+        prompt.append("If you choose to not run mythtv-setup now,");
+        prompt.append("\n");
+        prompt.append("it can be run later by typing Alt + s.");
+        prompt.append("\n");
+        prompt.append("\n");
+        prompt.append("Do you want to run mythtv-setup now?");
+
+        //as extern to be set in questionnotice.cpp
+        extern int questionReturnCode;
+
+        MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
+        QuestionNoticeDialog *questionNotice =
+                            new QuestionNoticeDialog(mainStack, "Question");
+        if (questionNotice->Create("question", "Run mythtv-setup?", prompt,
+            "Yes", "No")) mainStack->AddScreen(questionNotice, true);
+        else
+            return -1;
+
+        do
         {
-            AutoCard listcards;
-            listcards.exec();
-        }*/
+            qApp->processEvents();
+            std::this_thread::sleep_for(std::chrono::milliseconds(5));
+        } while (mainStack->TotalScreens() > 0);
 
-        return returncode;
+        if (questionReturnCode == 16)
+        {
+            int sysRet = system("mythtv-setup &");
+            if (sysRet < 1)
+                LOG(VB_GENERAL, LOG_ERR, "Could not run mythtv-setup.");
+        }
+        retval = questionReturnCode;
     }
-
     else if (bShowHelp)
     {
         QString line;
@@ -552,8 +555,8 @@ int main(int argc, char **argv)
         MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
         QuestionNoticeDialog *questionNotice = new QuestionNoticeDialog(mainStack,
                                             "Notice");
-        if (questionNotice->Create("notice", "LinHES Help", LH_HelpText))
-            mainStack->AddScreen(questionNotice, true);
+        if (questionNotice->Create("notice", "LinHES Help", LH_HelpText,
+            NULL, NULL)) mainStack->AddScreen(questionNotice, true);
         else
             return -1;
 
@@ -586,8 +589,8 @@ int main(int argc, char **argv)
         MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
         QuestionNoticeDialog *questionNotice = new QuestionNoticeDialog(mainStack,
                                             "Notice");
-        if (questionNotice->Create("notice", "Welcome to LinHES!", readmeText))
-            mainStack->AddScreen(questionNotice, true);
+        if (questionNotice->Create("notice", "Welcome to LinHES!", readmeText,
+            NULL, NULL )) mainStack->AddScreen(questionNotice, true);
         else
             return -1;
 
@@ -605,7 +608,7 @@ int main(int argc, char **argv)
         MythScreenStack *mainStack = GetMythMainWindow()->GetMainStack();
         QuestionNoticeDialog *questionNotice = new QuestionNoticeDialog(mainStack,
                                             "Question");
-        if (questionNotice->Create("question", "Question", question))
+        if (questionNotice->Create("question", "Question", question, "Yes", "No"))
             mainStack->AddScreen(questionNotice, true);
         else
             return -1;
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/mythinstall.pro b/abs/core/mythinstall/MythVantage-app/mythinstall/mythinstall.pro
index 8dd6855..6405b52 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/mythinstall.pro
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/mythinstall.pro
@@ -41,7 +41,7 @@ QMAKE_CLEAN += $(TARGET)
 //HEADERS += commandlineparser.h
 //SOURCES += main.cpp commandlineparser.cpp
 
-HEADERS += installdialog.h commandlineparser.h installsettings.h settemplate.h installationtype.h autocard.h xorgsettings.h password_manage.h misc_settings.h mv_common.h infrared.h compat-mv.h supplemental.h vnc.h fileshare.h questionnotice.h
-SOURCES += main.cpp commandlineparser.cpp installdialog.cpp installsettings.cpp settemplate.cpp installationtype.cpp autocard.cpp xorgsettings.cpp password_manage.cpp misc_settings.cpp infrared.cpp compat-mv.cpp supplemental.cpp vnc.cpp fileshare.cpp questionnotice.cpp
+HEADERS += installdialog.h commandlineparser.h installsettings.h settemplate.h installationtype.h xorgsettings.h password_manage.h misc_settings.h mv_common.h infrared.h compat-mv.h supplemental.h vnc.h fileshare.h questionnotice.h
+SOURCES += main.cpp commandlineparser.cpp installdialog.cpp installsettings.cpp settemplate.cpp installationtype.cpp xorgsettings.cpp password_manage.cpp misc_settings.cpp infrared.cpp compat-mv.cpp supplemental.cpp vnc.cpp fileshare.cpp questionnotice.cpp
 
 QT += sql xml network widgets
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.cpp b/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.cpp
index 529be89..ffd9a1d 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.cpp
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.cpp
@@ -27,7 +27,8 @@ QuestionNoticeDialog::QuestionNoticeDialog(MythScreenStack *parent,
 }
 
 bool QuestionNoticeDialog::Create(QString questionORnotice, QString title,
-                                  QString displayText)
+                                  QString displayText, QString yesButtonText,
+                                  QString noButtonText)
 {
     bool foundtheme = false;
 
@@ -56,9 +57,6 @@ bool QuestionNoticeDialog::Create(QString questionORnotice, QString title,
     m_title_text->SetVisible(true);
     m_title_text->SetText(title);
 
-    //LOG(VB_GENERAL, LOG_INFO, QString(questionORnotice));
-    //LOG(VB_GENERAL, LOG_INFO, QString(displayText));
-
     //show the correct text and buttons depending on questionORnotice
     if (questionORnotice.contains("notice"))
     {
@@ -79,13 +77,13 @@ bool QuestionNoticeDialog::Create(QString questionORnotice, QString title,
         m_no_button->SetVisible(true);
     }
 
-    m_ok_button->SetText(tr("OK"));
+    m_ok_button->SetText("OK");
     connect(m_ok_button, SIGNAL(Clicked()),
             this, SLOT(okButtonClick()));
-    m_yes_button->SetText(tr("Yes"));
+    m_yes_button->SetText(yesButtonText);
     connect(m_yes_button, SIGNAL(Clicked()),
             this, SLOT(yesButtonClick()));
-    m_no_button->SetText(tr("No"));
+    m_no_button->SetText(noButtonText);
     connect(m_no_button, SIGNAL(Clicked()),
             this, SLOT(noButtonClick()));
 
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.h b/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.h
index a2c2c79..f2d05c1 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.h
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/questionnotice.h
@@ -19,7 +19,8 @@ public:
     QuestionNoticeDialog(MythScreenStack *parent, const char *name);
     ~QuestionNoticeDialog();
 
-    bool Create(QString questionORnotice, QString title, QString displayText);
+    bool Create(QString questionORnotice, QString title, QString displayText,
+                QString yesButtonText, QString noButtonText);
 
 protected slots:
     void yesButton(void);
diff --git a/abs/core/mythinstall/MythVantage-app/mythinstall/settemplate.cpp b/abs/core/mythinstall/MythVantage-app/mythinstall/settemplate.cpp
index 8d9e671..7201304 100755
--- a/abs/core/mythinstall/MythVantage-app/mythinstall/settemplate.cpp
+++ b/abs/core/mythinstall/MythVantage-app/mythinstall/settemplate.cpp
@@ -32,8 +32,9 @@ void restart_frontend ()
     cmdtxt=MV_ROOT  ;
     cmdtxt.append("bin/systemconfig.sh  reloadfe" );
     //cout << "Calling systemconfig.sh reloadfe" << endl;
-    system(qPrintable(cmdtxt));
-    //system("/root/systemconfig.sh  reloadfe" );
+    int sysRet = system(qPrintable(cmdtxt));
+    if (sysRet < 0)
+        LOG(VB_GENERAL, LOG_ERR, "Error running systemconfig.sh reloadfe");
 }
 
 void choosetemplate (QString templateop, QString templatename  , QString templatehostname = "")
diff --git a/abs/core/mythinstall/PKGBUILD b/abs/core/mythinstall/PKGBUILD
index c51cbe5..64486cd 100644
--- a/abs/core/mythinstall/PKGBUILD
+++ b/abs/core/mythinstall/PKGBUILD
@@ -1,7 +1,7 @@
 # Maintainer: Jams
 pkgname=mythinstall
 pkgver=8.5.1
-pkgrel=1
+pkgrel=2
 pkgdesc="LinHES installer/systemconfig GUI."
 arch=('i686' 'x86_64')
 depends=('mythtv>=29' 'LinHES-config')
@@ -33,7 +33,7 @@ package() {
     done
 }
 
-md5sums=('4e587d53e64cb9cda12b0133a1fe1831'
+md5sums=('20d45199b7642c42cb60c6ce36331f5a'
          'c4c26977b723a4b5d6435ede73051d1b'
          '27ce7f89a83864dfc5abe23c61964c0c'
          '3291ad55fe6d7884fc732313f1cc2924'
diff --git a/abs/core/mythinstall/install-ui.xml b/abs/core/mythinstall/install-ui.xml
index 4c51ce9..be0e935 100755
--- a/abs/core/mythinstall/install-ui.xml
+++ b/abs/core/mythinstall/install-ui.xml
@@ -172,7 +172,7 @@
 
         <button name="yes_button" from="basebutton">
             <position>20,540</position>
-            <value>Yes</value>
+            <value></value>
         </button>
 
         <button name="ok_button" from="basebutton">
@@ -182,7 +182,7 @@
 
         <button name="no_button" from="basebutton">
             <position>630,540</position>
-            <value>No</value>
+            <value></value>
         </button>
 
     </window>
-- 
cgit v0.12


From 8812e45474ed673972c6b40378339e5557093764 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Fri, 29 Dec 2017 20:03:27 +0000
Subject: plex-media-server: update to 1.10.1.4602

---
 abs/extra/plex-media-server/PKGBUILD | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/abs/extra/plex-media-server/PKGBUILD b/abs/extra/plex-media-server/PKGBUILD
index 23fc75e..276b2c5 100644
--- a/abs/extra/plex-media-server/PKGBUILD
+++ b/abs/extra/plex-media-server/PKGBUILD
@@ -7,8 +7,8 @@
 # Contributor: Praekon <praekon@googlemail.com>
 
 pkgname=plex-media-server
-pkgver=1.9.7.4460
-_pkgsum=a39b25852
+pkgver=1.10.1.4602
+_pkgsum=f54242b6b
 pkgrel=1
 pkgdesc='Plex Media Server'
 arch=('x86_64')
@@ -45,4 +45,4 @@ md5sums=('dfd6778f5c0d3d64c2c3a71dca02b7cc'
          '97241861f2c0b7c82d1945a6c5de8e35'
          '506ec15815bba749a743780edd2323c8'
          'af6d0a81c7821b2eddb1bc137310ca1b')
-md5sums_x86_64=('19b81df06592416bcc9e90d536156e10')
+md5sums_x86_64=('ba3d53cb049edf368383154ae0d89ca5')
-- 
cgit v0.12


From ae6091b76a246ce6f0b88c9bfde7d8ecd8fd0a00 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Fri, 29 Dec 2017 20:28:23 +0000
Subject: google-chrome: update to 63.0.3239.108

---
 abs/extra/google-chrome/PKGBUILD | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/abs/extra/google-chrome/PKGBUILD b/abs/extra/google-chrome/PKGBUILD
index e7d9eb5..86f6124 100644
--- a/abs/extra/google-chrome/PKGBUILD
+++ b/abs/extra/google-chrome/PKGBUILD
@@ -5,9 +5,9 @@
 # or use: $ curl -s https://dl.google.com/linux/chrome/rpm/stable/x86_64/repodata/other.xml.gz | gzip -df | awk -F\" '/pkgid/{ sub(".*-","",$4); print $4": "$10 }'
 
 pkgname=google-chrome
-pkgver=62.0.3202.75
+pkgver=63.0.3239.108
 pkgrel=1
-pkgdesc="An attempt at creating a safer, faster, and more stable browser (Stable Channel)"
+pkgdesc="The popular and trusted web browser by Google (Stable Channel)"
 arch=('x86_64')
 url="https://www.google.com/chrome"
 license=('custom:chrome')
@@ -22,8 +22,8 @@ options=('!emptydirs' '!strip')
 install=$pkgname.install
 _channel=stable
 source=("google-chrome-${_channel}_${pkgver}_amd64.deb::https://dl.google.com/linux/direct/google-chrome-${_channel}_current_amd64.deb"
-        "$url/browser/privacy/eula_text.html"
-        'google-chrome-stable.sh')
+        'eula_text.html'
+        "google-chrome-$_channel.sh")
 
 package() {
   msg2 "Extracting the data.tar.xz..."
@@ -41,7 +41,9 @@ package() {
   done
 
   # Man page
-  gzip "$pkgdir"/usr/share/man/man1/google-chrome.1
+  if [[ -f "$pkgdir"/usr/share/man/man1/google-chrome.1 ]]; then
+    gzip "$pkgdir"/usr/share/man/man1/google-chrome.1
+  fi
 
   # License
   install -Dm644 eula_text.html "$pkgdir"/usr/share/licenses/google-chrome/eula_text.html
@@ -53,6 +55,6 @@ package() {
   rm -r "$pkgdir"/etc/cron.daily/ "$pkgdir"/opt/google/chrome/cron/
   rm "$pkgdir"/opt/google/chrome/product_logo_*.png
 }
-md5sums=('dde31453425d80944f304ed84746dbab'
+md5sums=('cc36f3a115e3e213a2bedb8b8fbe08ba'
          'd50d8f0a6940791eabc41c4f64e6a3cf'
          'ed4cf73982461af7d0d944c1cbf9f4e8')
-- 
cgit v0.12


From 3ae1448365fc23a06487aa2bb53a74e97d6e03ab Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Tue, 2 Jan 2018 20:17:37 +0000
Subject: linux: update to 4.9.73.

add patch to add wol to alx driver
---
 abs/core/linux/000-enable-alx-wol-4.9.patch | 475 ++++++++++++++++++++++++++++
 abs/core/linux/PKGBUILD                     |  10 +-
 abs/core/linux/linux.install.pkg            |   2 +-
 3 files changed, 484 insertions(+), 3 deletions(-)
 create mode 100644 abs/core/linux/000-enable-alx-wol-4.9.patch

diff --git a/abs/core/linux/000-enable-alx-wol-4.9.patch b/abs/core/linux/000-enable-alx-wol-4.9.patch
new file mode 100644
index 0000000..3428afd
--- /dev/null
+++ b/abs/core/linux/000-enable-alx-wol-4.9.patch
@@ -0,0 +1,475 @@
+diff -u drivers/net/ethernet/atheros/alx/ethtool.c drivers/net/ethernet/atheros/alx/ethtool.c
+--- drivers/net/ethernet/atheros/alx/ethtool.c	2016-12-11 20:17:54.000000000 +0100
++++ drivers/net/ethernet/atheros/alx/ethtool.c	2016-12-13 13:36:36.464047098 +0100
+@@ -299,6 +299,40 @@
+ 	}
+ }
+ 
++static void alx_get_wol(struct net_device *netdev, struct ethtool_wolinfo *wol)
++{
++	struct alx_priv *alx = netdev_priv(netdev);
++	struct alx_hw *hw = &alx->hw;
++
++	wol->supported = WAKE_MAGIC | WAKE_PHY;
++	wol->wolopts = 0;
++
++	if (hw->sleep_ctrl & ALX_SLEEP_WOL_MAGIC)
++		wol->wolopts |= WAKE_MAGIC;
++	if (hw->sleep_ctrl & ALX_SLEEP_WOL_PHY)
++		wol->wolopts |= WAKE_PHY;
++}
++
++static int alx_set_wol(struct net_device *netdev, struct ethtool_wolinfo *wol)
++{
++	struct alx_priv *alx = netdev_priv(netdev);
++	struct alx_hw *hw = &alx->hw;
++
++	if (wol->wolopts & ~(WAKE_MAGIC | WAKE_PHY))
++		return -EOPNOTSUPP;
++
++	hw->sleep_ctrl = 0;
++
++	if (wol->wolopts & WAKE_MAGIC)
++		hw->sleep_ctrl |= ALX_SLEEP_WOL_MAGIC;
++	if (wol->wolopts & WAKE_PHY)
++		hw->sleep_ctrl |= ALX_SLEEP_WOL_PHY;
++
++	device_set_wakeup_enable(&alx->hw.pdev->dev, hw->sleep_ctrl);
++
++	return 0;
++}
++
+ const struct ethtool_ops alx_ethtool_ops = {
+ 	.get_settings	= alx_get_settings,
+ 	.set_settings	= alx_set_settings,
+@@ -306,6 +340,8 @@
+ 	.set_pauseparam	= alx_set_pauseparam,
+ 	.get_msglevel	= alx_get_msglevel,
+ 	.set_msglevel	= alx_set_msglevel,
++	.get_wol	= alx_get_wol,
++	.set_wol	= alx_set_wol,
+ 	.get_link	= ethtool_op_get_link,
+ 	.get_strings	= alx_get_strings,
+ 	.get_sset_count	= alx_get_sset_count,
+diff -u drivers/net/ethernet/atheros/alx/hw.c drivers/net/ethernet/atheros/alx/hw.c
+--- drivers/net/ethernet/atheros/alx/hw.c	2016-12-11 20:17:54.000000000 +0100
++++ drivers/net/ethernet/atheros/alx/hw.c	2016-12-13 13:36:36.464047098 +0100
+@@ -332,6 +332,16 @@
+ 	alx_write_mem32(hw, ALX_STAD1, val);
+ }
+ 
++static void alx_enable_osc(struct alx_hw *hw)
++{
++	u32 val;
++
++	/* rising edge */
++	val = alx_read_mem32(hw, ALX_MISC);
++	alx_write_mem32(hw, ALX_MISC, val & ~ALX_MISC_INTNLOSC_OPEN);
++	alx_write_mem32(hw, ALX_MISC, val | ALX_MISC_INTNLOSC_OPEN);
++}
++
+ static void alx_reset_osc(struct alx_hw *hw, u8 rev)
+ {
+ 	u32 val, val2;
+@@ -848,6 +858,66 @@
+ 	}
+ }
+ 
++
++/* NOTE:
++ *    1. phy link must be established before calling this function
++ *    2. wol option (pattern,magic,link,etc.) is configed before call it.
++ */
++int alx_pre_suspend(struct alx_hw *hw, int speed, u8 duplex)
++{
++	u32 master, mac, phy, val;
++	int err = 0;
++
++	master = alx_read_mem32(hw, ALX_MASTER);
++	master &= ~ALX_MASTER_PCLKSEL_SRDS;
++	mac = hw->rx_ctrl;
++	/* 10/100 half */
++	ALX_SET_FIELD(mac, ALX_MAC_CTRL_SPEED,  ALX_MAC_CTRL_SPEED_10_100);
++	mac &= ~(ALX_MAC_CTRL_FULLD | ALX_MAC_CTRL_RX_EN | ALX_MAC_CTRL_TX_EN);
++
++	phy = alx_read_mem32(hw, ALX_PHY_CTRL);
++	phy &= ~(ALX_PHY_CTRL_DSPRST_OUT | ALX_PHY_CTRL_CLS);
++	phy |= ALX_PHY_CTRL_RST_ANALOG | ALX_PHY_CTRL_HIB_PULSE |
++	       ALX_PHY_CTRL_HIB_EN;
++
++	/* without any activity  */
++	if (!(hw->sleep_ctrl & ALX_SLEEP_ACTIVE)) {
++		err = alx_write_phy_reg(hw, ALX_MII_IER, 0);
++		if (err)
++			return err;
++		phy |= ALX_PHY_CTRL_IDDQ | ALX_PHY_CTRL_POWER_DOWN;
++	} else {
++		if (hw->sleep_ctrl & (ALX_SLEEP_WOL_MAGIC | ALX_SLEEP_CIFS))
++			mac |= ALX_MAC_CTRL_RX_EN | ALX_MAC_CTRL_BRD_EN;
++		if (hw->sleep_ctrl & ALX_SLEEP_CIFS)
++			mac |= ALX_MAC_CTRL_TX_EN;
++		if (duplex == DUPLEX_FULL)
++			mac |= ALX_MAC_CTRL_FULLD;
++		if (speed == SPEED_1000)
++			ALX_SET_FIELD(mac, ALX_MAC_CTRL_SPEED,
++				      ALX_MAC_CTRL_SPEED_1000);
++		phy |= ALX_PHY_CTRL_DSPRST_OUT;
++		err = alx_write_phy_ext(hw, ALX_MIIEXT_ANEG,
++					ALX_MIIEXT_S3DIG10,
++					ALX_MIIEXT_S3DIG10_SL);
++		if (err)
++			return err;
++	}
++
++	alx_enable_osc(hw);
++	hw->rx_ctrl = mac;
++	alx_write_mem32(hw, ALX_MASTER, master);
++	alx_write_mem32(hw, ALX_MAC_CTRL, mac);
++	alx_write_mem32(hw, ALX_PHY_CTRL, phy);
++
++	/* set val of PDLL D3PLLOFF */
++	val = alx_read_mem32(hw, ALX_PDLL_TRNS1);
++	val |= ALX_PDLL_TRNS1_D3PLLOFF_EN;
++	alx_write_mem32(hw, ALX_PDLL_TRNS1, val);
++
++	return 0;
++}
++
+ bool alx_phy_configured(struct alx_hw *hw)
+ {
+ 	u32 cfg, hw_cfg;
+@@ -920,6 +990,26 @@
+ 	return alx_read_phy_reg(hw, ALX_MII_ISR, &isr);
+ }
+ 
++int alx_config_wol(struct alx_hw *hw)
++{
++	u32 wol = 0;
++	int err = 0;
++
++	/* turn on magic packet event */
++	if (hw->sleep_ctrl & ALX_SLEEP_WOL_MAGIC)
++		wol |= ALX_WOL0_MAGIC_EN | ALX_WOL0_PME_MAGIC_EN;
++
++	/* turn on link up event */
++	if (hw->sleep_ctrl & ALX_SLEEP_WOL_PHY) {
++		wol |=  ALX_WOL0_LINK_EN | ALX_WOL0_PME_LINK;
++		/* only link up can wake up */
++		err = alx_write_phy_reg(hw, ALX_MII_IER, ALX_IER_LINK_UP);
++	}
++	alx_write_mem32(hw, ALX_WOL0, wol);
++
++	return err;
++}
++
+ void alx_disable_rss(struct alx_hw *hw)
+ {
+ 	u32 ctrl = alx_read_mem32(hw, ALX_RXQ0);
+@@ -1045,6 +1135,71 @@
+ }
+ 
+ 
++int alx_select_powersaving_speed(struct alx_hw *hw, int *speed, u8 *duplex)
++{
++	int i, err;
++	u16 lpa;
++
++	err = alx_read_phy_link(hw);
++	if (err)
++		return err;
++
++	if (hw->link_speed == SPEED_UNKNOWN) {
++		*speed = SPEED_UNKNOWN;
++		*duplex = DUPLEX_UNKNOWN;
++		return 0;
++	}
++
++	err = alx_read_phy_reg(hw, MII_LPA, &lpa);
++	if (err)
++		return err;
++
++	if (!(lpa & LPA_LPACK)) {
++		*speed = hw->link_speed;
++		return 0;
++	}
++
++	if (lpa & LPA_10FULL) {
++		*speed = SPEED_10;
++		*duplex = DUPLEX_FULL;
++	} else if (lpa & LPA_10HALF) {
++		*speed = SPEED_10;
++		*duplex = DUPLEX_HALF;
++	} else if (lpa & LPA_100FULL) {
++		*speed = SPEED_100;
++		*duplex = DUPLEX_FULL;
++	} else {
++		*speed = SPEED_100;
++		*duplex = DUPLEX_HALF;
++	}
++
++	if (*speed == hw->link_speed && *duplex == hw->duplex)
++		return 0;
++	err = alx_write_phy_reg(hw, ALX_MII_IER, 0);
++	if (err)
++		return err;
++	err = alx_setup_speed_duplex(hw, alx_speed_to_ethadv(*speed, *duplex) |
++					 ADVERTISED_Autoneg, ALX_FC_ANEG |
++					 ALX_FC_RX | ALX_FC_TX);
++	if (err)
++		return err;
++
++	/* wait for linkup */
++	for (i = 0; i < ALX_MAX_SETUP_LNK_CYCLE; i++) {
++		msleep(100);
++
++		err = alx_read_phy_link(hw);
++		if (err < 0)
++			return err;
++		if (hw->link_speed != SPEED_UNKNOWN)
++			break;
++	}
++	if (i == ALX_MAX_SETUP_LNK_CYCLE)
++		return -ETIMEDOUT;
++
++	return 0;
++}
++
+ bool alx_get_phy_info(struct alx_hw *hw)
+ {
+ 	u16  devs1, devs2;
+diff -u drivers/net/ethernet/atheros/alx/hw.h drivers/net/ethernet/atheros/alx/hw.h
+--- drivers/net/ethernet/atheros/alx/hw.h	2016-12-11 20:17:54.000000000 +0100
++++ drivers/net/ethernet/atheros/alx/hw.h	2016-12-13 13:36:36.464047098 +0100
+@@ -488,6 +488,8 @@
+ 	u8 flowctrl;
+ 	u32 adv_cfg;
+ 
++	u32 sleep_ctrl;
++
+ 	spinlock_t mdio_lock;
+ 	struct mdio_if_info mdio;
+ 	u16 phy_id[2];
+@@ -550,12 +552,14 @@
+ void alx_enable_aspm(struct alx_hw *hw, bool l0s_en, bool l1_en);
+ int alx_setup_speed_duplex(struct alx_hw *hw, u32 ethadv, u8 flowctrl);
+ void alx_post_phy_link(struct alx_hw *hw);
++int alx_pre_suspend(struct alx_hw *hw, int speed, u8 duplex);
+ int alx_read_phy_reg(struct alx_hw *hw, u16 reg, u16 *phy_data);
+ int alx_write_phy_reg(struct alx_hw *hw, u16 reg, u16 phy_data);
+ int alx_read_phy_ext(struct alx_hw *hw, u8 dev, u16 reg, u16 *pdata);
+ int alx_write_phy_ext(struct alx_hw *hw, u8 dev, u16 reg, u16 data);
+ int alx_read_phy_link(struct alx_hw *hw);
+ int alx_clear_phy_intr(struct alx_hw *hw);
++int alx_config_wol(struct alx_hw *hw);
+ void alx_cfg_mac_flowcontrol(struct alx_hw *hw, u8 fc);
+ void alx_start_mac(struct alx_hw *hw);
+ int alx_reset_mac(struct alx_hw *hw);
+@@ -564,6 +568,7 @@
+ void alx_configure_basic(struct alx_hw *hw);
+ void alx_mask_msix(struct alx_hw *hw, int index, bool mask);
+ void alx_disable_rss(struct alx_hw *hw);
++int alx_select_powersaving_speed(struct alx_hw *hw, int *speed, u8 *duplex);
+ bool alx_get_phy_info(struct alx_hw *hw);
+ void alx_update_hw_stats(struct alx_hw *hw);
+ 
+diff -u drivers/net/ethernet/atheros/alx/main.c drivers/net/ethernet/atheros/alx/main.c
+--- drivers/net/ethernet/atheros/alx/main.c	2016-12-11 20:17:54.000000000 +0100
++++ drivers/net/ethernet/atheros/alx/main.c	2016-12-13 13:36:47.736407751 +0100
+@@ -894,6 +894,7 @@
+ 	alx->rxbuf_size = ALX_MAX_FRAME_LEN(hw->mtu);
+ 	alx->tx_ringsz = 256;
+ 	alx->rx_ringsz = 512;
++  hw->sleep_ctrl = ALX_SLEEP_WOL_MAGIC | ALX_SLEEP_WOL_PHY;
+ 	hw->imt = 200;
+ 	alx->int_mask = ALX_ISR_MISC;
+ 	hw->dma_chnl = hw->max_dma_chnl;
+@@ -1150,6 +1151,65 @@
+ 	__alx_stop(netdev_priv(netdev));
+ 	return 0;
+ }
++static int __alx_shutdown(struct pci_dev *pdev, bool *wol_en)
++{
++	struct alx_priv *alx = pci_get_drvdata(pdev);
++	struct net_device *netdev = alx->dev;
++	struct alx_hw *hw = &alx->hw;
++	int err, speed;
++	u8 duplex;
++
++	netif_device_detach(netdev);
++
++	if (netif_running(netdev))
++		__alx_stop(alx);
++
++#ifdef CONFIG_PM_SLEEP
++	err = pci_save_state(pdev);
++	if (err)
++		return err;
++#endif
++
++	err = alx_select_powersaving_speed(hw, &speed, &duplex);
++	if (err)
++		return err;
++	err = alx_clear_phy_intr(hw);
++	if (err)
++		return err;
++	err = alx_pre_suspend(hw, speed, duplex);
++	if (err)
++		return err;
++	err = alx_config_wol(hw);
++	if (err)
++		return err;
++
++	*wol_en = false;
++	if (hw->sleep_ctrl & ALX_SLEEP_ACTIVE) {
++		netif_info(alx, wol, netdev,
++			   "wol: ctrl=%X, speed=%X\n",
++			   hw->sleep_ctrl, speed);
++		device_set_wakeup_enable(&pdev->dev, true);
++		*wol_en = true;
++	}
++
++	pci_disable_device(pdev);
++
++	return 0;
++}
++
++static void alx_shutdown(struct pci_dev *pdev)
++{
++	int err;
++	bool wol_en;
++
++	err = __alx_shutdown(pdev, &wol_en);
++	if (!err) {
++		pci_wake_from_d3(pdev, wol_en);
++		pci_set_power_state(pdev, PCI_D3hot);
++	} else {
++		dev_err(&pdev->dev, "shutdown fail %d\n", err);
++	}
++}
+ 
+ static void alx_link_check(struct work_struct *work)
+ {
+@@ -1637,6 +1697,8 @@
+ 		goto out_unmap;
+ 	}
+ 
++	device_set_wakeup_enable(&pdev->dev, hw->sleep_ctrl);
++
+ 	netdev_info(netdev,
+ 		    "Qualcomm Atheros AR816x/AR817x Ethernet [%pM]\n",
+ 		    netdev->dev_addr);
+@@ -1679,12 +1741,21 @@
+ static int alx_suspend(struct device *dev)
+ {
+ 	struct pci_dev *pdev = to_pci_dev(dev);
+-	struct alx_priv *alx = pci_get_drvdata(pdev);
++	int err;
++	bool wol_en;
+ 
+-	if (!netif_running(alx->dev))
+-		return 0;
+-	netif_device_detach(alx->dev);
+-	__alx_stop(alx);
++	err = __alx_shutdown(pdev, &wol_en);
++	if (err) {
++		dev_err(&pdev->dev, "shutdown fail in suspend %d\n", err);
++		return err;
++	}
++
++	if (wol_en) {
++		pci_prepare_to_sleep(pdev);
++	} else {
++		pci_wake_from_d3(pdev, false);
++		pci_set_power_state(pdev, PCI_D3hot);
++	}
+ 	return 0;
+ }
+ 
+@@ -1692,20 +1763,47 @@
+ {
+ 	struct pci_dev *pdev = to_pci_dev(dev);
+ 	struct alx_priv *alx = pci_get_drvdata(pdev);
+-	struct alx_hw *hw = &alx->hw;
+-
+-	alx_reset_phy(hw);
++  struct net_device *netdev = alx->dev;
++  struct alx_hw *hw = &alx->hw;
++  int err;
++
++  pci_set_power_state(pdev, PCI_D0);
++  pci_restore_state(pdev);
++  pci_save_state(pdev);
++
++  pci_enable_wake(pdev, PCI_D3hot, 0);
++  pci_enable_wake(pdev, PCI_D3cold, 0);
++
++  hw->link_speed = SPEED_UNKNOWN;
++  alx->int_mask = ALX_ISR_MISC;
++
++  alx_reset_pcie(hw);
++  alx_reset_phy(hw);
++
++  err = alx_reset_mac(hw);
++  if (err) {
++         netif_err(alx, hw, alx->dev,
++                   "resume:reset_mac fail %d\n", err);
++         return -EIO;
++  }
++
++  err = alx_setup_speed_duplex(hw, hw->adv_cfg, hw->flowctrl);
++  if (err) {
++         netif_err(alx, hw, alx->dev,
++                   "resume:setup_speed_duplex fail %d\n", err);
++         return -EIO;
++  }
++
++  if (netif_running(netdev)) {
++         err = __alx_open(alx, true);
++         if (err)
++                 return err;
++  }
+ 
+-	if (!netif_running(alx->dev))
+-		return 0;
+-	netif_device_attach(alx->dev);
+-	return __alx_open(alx, true);
++  netif_device_attach(netdev);
++	return err;
+ }
+ 
+-static SIMPLE_DEV_PM_OPS(alx_pm_ops, alx_suspend, alx_resume);
+-#define ALX_PM_OPS      (&alx_pm_ops)
+-#else
+-#define ALX_PM_OPS      NULL
+ #endif
+ 
+ 
+@@ -1751,6 +1849,8 @@
+ 	}
+ 
+ 	pci_set_master(pdev);
++	pci_enable_wake(pdev, PCI_D3hot, 0);
++	pci_enable_wake(pdev, PCI_D3cold, 0);
+ 
+ 	alx_reset_pcie(hw);
+ 	if (!alx_reset_mac(hw))
+@@ -1802,11 +1902,19 @@
+ 	{}
+ };
+ 
++#ifdef CONFIG_PM_SLEEP
++static SIMPLE_DEV_PM_OPS(alx_pm_ops, alx_suspend, alx_resume);
++#define ALX_PM_OPS      (&alx_pm_ops)
++#else
++#define ALX_PM_OPS      NULL
++#endif
++
+ static struct pci_driver alx_driver = {
+ 	.name        = alx_drv_name,
+ 	.id_table    = alx_pci_tbl,
+ 	.probe       = alx_probe,
+ 	.remove      = alx_remove,
++	.shutdown    = alx_shutdown,
+ 	.err_handler = &alx_err_handlers,
+ 	.driver.pm   = ALX_PM_OPS,
+ };
diff --git a/abs/core/linux/PKGBUILD b/abs/core/linux/PKGBUILD
index f7a2962..914d8b2 100644
--- a/abs/core/linux/PKGBUILD
+++ b/abs/core/linux/PKGBUILD
@@ -4,7 +4,7 @@
 pkgbase=linux
 #pkgbase=linux-custom
 _srcname=linux-4.9
-pkgver=4.9.64
+pkgver=4.9.73
 pkgrel=1
 arch=('x86_64')
 url="https://www.kernel.org/"
@@ -19,15 +19,18 @@ source=(https://www.kernel.org/pub/linux/kernel/v4.x/${_srcname}.tar.{xz,sign}
         '90-linux.hook'
         # standard config files for mkinitcpio ramdisk
         linux.preset
+        # add WOL to alx
+        '000-enable-alx-wol-4.9.patch'
         change-default-console-loglevel.patch)
 # https://www.kernel.org/pub/linux/kernel/v4.x/sha256sums.asc
 sha256sums=('029098dcffab74875e086ae970e3828456838da6e0ba22ce3f64ef764f3d7f1a'
             'SKIP'
-            'e17b3219b2b9ebdeb180e509b3a1a6eb46d957d6a95c17f4e6b6b7199067949a'
+            '2af9c1806d1c4a6b90f5b105bdb6eedba8e0610712d0bab8a906bb015b2993f3'
             'SKIP'
             '2bafc851b494310056bdc1a8bd3f5342f18c50a83594f5e5bf603406c5144ae4'
             '834bd254b56ab71d73f59b3221f056c72f559553c04718e350ab2a3e2991afe0'
             '1f036f7464da54ae510630f0edb69faa115287f86d9f17641197ffda8cfd49e0'
+            'f8f6c9e9d82fac0ad1333a15418df81e2186e6a2e257aa670d1da57b4a15cafe'
             '1256b241cd477b265a3c2d64bdc19ffe3c9bbcee82ea3994c590c2c76e767d99')
 validpgpkeys=('ABAF11C65A2970B130ABE3C479BE3E4300411886' # Linus Torvalds <torvalds@linux-foundation.org>
               '647F28654894E3BD457199BE38DBBDC86092693E' # Greg Kroah-Hartman (Linux kernel stable release signing key) <greg@kroah.com>
@@ -49,6 +52,9 @@ prepare() {
   # (relevant patch sent upstream: https://lkml.org/lkml/2011/7/26/227)
   patch -p1 -i "${srcdir}/change-default-console-loglevel.patch"
 
+  # add WOL to alx
+  patch -p0 -i "${srcdir}/000-enable-alx-wol-4.9.patch"
+
   cat "${srcdir}/config" > ./.config
 
   if [ "${_kernelname}" != "" ]; then
diff --git a/abs/core/linux/linux.install.pkg b/abs/core/linux/linux.install.pkg
index c4ca093..9229cc6 100644
--- a/abs/core/linux/linux.install.pkg
+++ b/abs/core/linux/linux.install.pkg
@@ -2,7 +2,7 @@
 # arg 2:  the old package version
 
 KERNEL_NAME=
-KERNEL_VERSION=4.9.64-1-ARCH
+KERNEL_VERSION=4.9.73-1-ARCH
 
 post_install () {
   # updating module dependencies
-- 
cgit v0.12


From 06bee69a2a5b5356be0b3b69c321dc05a4317716 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Tue, 2 Jan 2018 20:18:45 +0000
Subject: ceton_infinitv: rebuild for linux

---
 abs/core/ceton_infinitv/PKGBUILD | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/abs/core/ceton_infinitv/PKGBUILD b/abs/core/ceton_infinitv/PKGBUILD
index 0ebb33d..9768d79 100755
--- a/abs/core/ceton_infinitv/PKGBUILD
+++ b/abs/core/ceton_infinitv/PKGBUILD
@@ -2,10 +2,10 @@
 
 pkgname=ceton_infinitv
 #_kernver=`uname -r`
-_kernver=4.9.64-1-ARCH
+_kernver=4.9.73-1-ARCH
 _extramods="extramodules-4.9-ARCH"
 pkgver=2013.0326.2226
-pkgrel=23
+pkgrel=24
 usb_pkgver=0.1.0
 pci_pkgver=`echo $pkgver | tr . _`
 pkgdesc="Drivers for Ceton InfiniTV4 - pci/usb "
-- 
cgit v0.12


From 62500bed8bf6b74fb2b0783e88fd627abfd62203 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Tue, 2 Jan 2018 20:19:45 +0000
Subject: nvidia, nvidia-340xx, nvidia-304xx: rebuild for linux

---
 abs/core/nvidia-304xx/PKGBUILD | 2 +-
 abs/core/nvidia-340xx/PKGBUILD | 2 +-
 abs/core/nvidia/PKGBUILD       | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/abs/core/nvidia-304xx/PKGBUILD b/abs/core/nvidia-304xx/PKGBUILD
index c370fa8..6c7a698 100644
--- a/abs/core/nvidia-304xx/PKGBUILD
+++ b/abs/core/nvidia-304xx/PKGBUILD
@@ -6,7 +6,7 @@ pkgbase=nvidia-304xx
 pkgname=(nvidia-304xx nvidia-304xx-dkms)
 pkgver=304.137
 _extramodules=extramodules-4.9-ARCH
-pkgrel=9
+pkgrel=10
 pkgdesc="NVIDIA drivers for linux, 304xx legacy branch"
 arch=('x86_64')
 url="http://www.nvidia.com/"
diff --git a/abs/core/nvidia-340xx/PKGBUILD b/abs/core/nvidia-340xx/PKGBUILD
index a639d7f..4e5bcb4 100644
--- a/abs/core/nvidia-340xx/PKGBUILD
+++ b/abs/core/nvidia-340xx/PKGBUILD
@@ -6,7 +6,7 @@ pkgbase=nvidia-340xx
 pkgname=(nvidia-340xx nvidia-340xx-dkms)
 pkgver=340.104
 _extramodules=extramodules-4.9-ARCH
-pkgrel=8
+pkgrel=9
 pkgdesc="NVIDIA drivers for linux, 340xx legacy branch"
 arch=('x86_64')
 url="http://www.nvidia.com/"
diff --git a/abs/core/nvidia/PKGBUILD b/abs/core/nvidia/PKGBUILD
index d6db1ad..21247b9 100644
--- a/abs/core/nvidia/PKGBUILD
+++ b/abs/core/nvidia/PKGBUILD
@@ -7,7 +7,7 @@ pkgbase=nvidia
 pkgname=(nvidia nvidia-dkms)
 pkgver=387.22
 _extramodules=extramodules-4.9-ARCH
-pkgrel=8
+pkgrel=9
 pkgdesc="NVIDIA drivers for linux"
 arch=('x86_64')
 url="http://www.nvidia.com/"
-- 
cgit v0.12


From e92f8c21e93d7fe48e4c302942ce0e0b66b7c97c Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Tue, 2 Jan 2018 20:20:48 +0000
Subject: xf86-video-intel: update to 2.99.917+802

---
 abs/core/xf86-video-intel/PKGBUILD | 21 ++++++++++++++-------
 1 file changed, 14 insertions(+), 7 deletions(-)

diff --git a/abs/core/xf86-video-intel/PKGBUILD b/abs/core/xf86-video-intel/PKGBUILD
index f6f56d3..3093faa 100644
--- a/abs/core/xf86-video-intel/PKGBUILD
+++ b/abs/core/xf86-video-intel/PKGBUILD
@@ -3,16 +3,16 @@
 # Maintainer: Jan de Groot <jgc@archlinux.org>
 
 pkgname=xf86-video-intel
-_commit=7e9e92c # 7 digits
-pkgver=2.99.917+767+g7e9e92c
+_commit=af6d8e9e8f546e5cba60e3a62765c2dbd0328e83 # master
+pkgver=2.99.917+802+gaf6d8e9
 pkgrel=1
 epoch=1
-arch=(i686 x86_64)
+arch=(x86_64)
 url="https://01.org/linuxgraphics"
 license=('custom')
 install=$pkgname.install
 pkgdesc="X.org Intel i810/i830/i915/945G/G965+ video drivers"
-depends=('mesa-dri' 'libxvmc' 'pixman' 'xcb-util>=0.3.9' 'libsystemd')
+depends=('mesa' 'libxvmc' 'pixman' 'xcb-util>=0.3.9' 'libsystemd')
 makedepends=('xorg-server-devel' 'X-ABI-VIDEODRV_VERSION=23' 'libx11' 'libxrender'
              # additional deps for intel-virtual-output
              'libxrandr' 'libxinerama' 'libxcursor' 'libxtst' 'libxss'
@@ -28,13 +28,12 @@ provides=('xf86-video-intel-uxa' 'xf86-video-intel-sna')
 conflicts=('xorg-server<1.19' 'X-ABI-VIDEODRV_VERSION<23' 'X-ABI-VIDEODRV_VERSION>=24'
            'xf86-video-intel-sna' 'xf86-video-intel-uxa' 'xf86-video-i810' 'xf86-video-intel-legacy')
 groups=('xorg-drivers')
-#source=(${url}/archive/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-source=("git://anongit.freedesktop.org/xorg/driver/xf86-video-intel#commit=${_commit}")
+source=("git+https://anongit.freedesktop.org/git/xorg/driver/xf86-video-intel#commit=$_commit")
 sha256sums=('SKIP')
 
 pkgver() {
   cd $pkgname
-  git describe --long | sed 's/-/+/g'
+  git describe --tags | sed 's/-/+/g'
 }
 
 prepare() {
@@ -44,6 +43,14 @@ prepare() {
 
 build() {
   cd $pkgname
+
+  # Since pacman 5.0.2-2, hardened flags are now enabled in makepkg.conf
+  # With them, module fail to load with undefined symbol.
+  # See https://bugs.archlinux.org/task/55102 / https://bugs.archlinux.org/task/54845
+  export CFLAGS=${CFLAGS/-fno-plt}
+  export CXXFLAGS=${CXXFLAGS/-fno-plt}
+  export LDFLAGS=${LDFLAGS/,-z,now}
+
   ./configure --prefix=/usr \
     --libexecdir=/usr/lib \
     --with-default-dri=3
-- 
cgit v0.12


From 24f840f1ac56c1f78272d4b0de50844cb876aa1b Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Wed, 3 Jan 2018 21:50:55 +0000
Subject: LinHES-system: idle.py: fix wrong status on standby

mythwelcome-config.py: add settings so mythbackend will alsow work to shutdown and use the mythfrontend idle screen
---
 abs/core/LinHES-system/PKGBUILD                 | 10 +++++-----
 abs/core/LinHES-system/idle.py                  |  8 ++++----
 abs/core/LinHES-system/mythwelcome-config.py    | 15 ++++++++-------
 abs/core/LinHES-system/mythwelcome-set-alarm.sh | 10 +++++-----
 4 files changed, 22 insertions(+), 21 deletions(-)

diff --git a/abs/core/LinHES-system/PKGBUILD b/abs/core/LinHES-system/PKGBUILD
index 3ff5184..5d4252b 100755
--- a/abs/core/LinHES-system/PKGBUILD
+++ b/abs/core/LinHES-system/PKGBUILD
@@ -1,6 +1,6 @@
 pkgname=LinHES-system
-pkgver=8.5
-pkgrel=2
+pkgver=8.5.1
+pkgrel=1
 arch=('i686' 'x86_64')
 install=system.install
 pkgdesc="Everything that makes LinHES an automated system"
@@ -128,15 +128,15 @@ md5sums=('c6e6b83a1f4c35ef4501e277657ab2ac'
          '8b0298f70f97cc1dc2a58b9a73c64bd3'
          'd2f1bec810a740885d9c0a2893186587'
          'e30bf8ec8b9dcc2ceb7127375a91d8d1'
-         'e9f545c3bcf9c85b45496c281fc6a1b8'
+         'a8bbc553cd784ebed2197b96b60addc8'
          'a94fe6d980f4b810f2e2ae5352084b39'
          '0d1632ea63d8145c173c6aecf0b007f0'
          'ff689f2e9572a78d88384b2e5774f579'
          '28f29578e5b3ba84fdf2aa57cf475bcf'
          '4a1fda884dcd7d65fb2690fbdbd92a83'
          '29f451783db3220b612e00c29e3ded73'
-         'de3028ed75b53bd2f85ffbfdf64c44c2'
-         '95c092f67036a361ef7a57436f44332e'
+         '0b80d8e364652b144324f7c3e0f04ecb'
+         '3b27dd20cc35dce9bdad017087c9cf15'
          '410795ef9039e4c6c0484e706ecfd567'
          'eb879fee9603a05d5420d4ce8ed9e450'
          '02c810c2f47b7c4495fdacaf54189473'
diff --git a/abs/core/LinHES-system/idle.py b/abs/core/LinHES-system/idle.py
index 05dedac..2c1a749 100755
--- a/abs/core/LinHES-system/idle.py
+++ b/abs/core/LinHES-system/idle.py
@@ -226,8 +226,7 @@ def mythfe_check(cmdargs,cursor,mythDB):
     else:
         msg(cmdargs,"    Checking for playing mythfrontends...")
     try:
-        #frontends = mythDB.getFrontends() #use cursor instead so it doesn't test connection
-        cursor.execute("select hostname from settings where value = 'FrontendIdleTimeout'")
+        cursor.execute("select distinct hostname from settings where hostname is not null;")
         frontends=cursor.fetchall()
     except:
         return True
@@ -242,14 +241,15 @@ def mythfe_check(cmdargs,cursor,mythDB):
             location = frontend.sendQuery('Location')
 
             if location == "standbymode":
-                msg(cmdargs,"            %s's mythfrontend is in StandbyMode." %i)
-                return True
+                msg(cmdargs,"            %s's mythfrontend is in Standby Mode." %i)
+                continue
 
             if ( location.startswith('Playback ') ):
                 msg(cmdargs,"            %s's mythfrontend is PLAYING." %i)
                 return False
             else:
                 msg(cmdargs,"            %s's mythfrontend is NOT playing." %i)
+
             if '.xml' in location or 'mainmenu' in location:
                 msg(cmdargs,"            %s's mythfrontend is in MENUS." %i)
             else:
diff --git a/abs/core/LinHES-system/mythwelcome-config.py b/abs/core/LinHES-system/mythwelcome-config.py
index 204a6e9..5a8727f 100755
--- a/abs/core/LinHES-system/mythwelcome-config.py
+++ b/abs/core/LinHES-system/mythwelcome-config.py
@@ -1,6 +1,7 @@
 #!/usr/bin/env python2
 
-# This script will configure the myth db to allow MythWelcome to wake and shutdown the system.
+# This script will configure the myth db to allow MythWelcome
+# or mythbackend to wake and shutdown the system.
 
 from socket import gethostname
 from MythTV import MythDB
@@ -11,8 +12,8 @@ localhostname = gethostname()
 mythdb.settings[localhostname].MythShutdownNvramCmd = u'sudo sh -c \"/usr/LH/bin/mythwelcome-set-alarm.sh $time\"'
 mythdb.settings[localhostname].MythShutdownWakeupTimeFmt = u'time_t'
 mythdb.settings[localhostname].MythShutdownNvramRestartCmd = u''
-mythdb.settings[localhostname].MythShutdownReboot = u'sudo /sbin/reboot'
-mythdb.settings[localhostname].MythShutdownPowerOff = u'sudo /sbin/poweroff'
+mythdb.settings[localhostname].MythShutdownReboot = u'sudo /usr/bin/reboot'
+mythdb.settings[localhostname].MythShutdownPowerOff = u'sudo /usr/bin/poweroff'
 mythdb.settings[localhostname].MythShutdownXTermCmd = u'xterm'
 mythdb.settings[localhostname].MythWelcomeStartFECmd = u'/usr/LH/bin/mythfrontend-start'
 
@@ -24,7 +25,7 @@ if mythdb.settings[localhostname].HostSystemType == u'Master_backend':
     else:
         mythdb.settings.NULL.idleTimeoutSecs = u'0'
 
-mythdb.settings.NULL.WakeupTimeFormat = u'yyyy-MM-ddThh:mm:ss'
-mythdb.settings.NULL.SetWakeuptimeCommand = u'/usr/bin/mythshutdown --setwakeup $time'
-mythdb.settings.NULL.ServerHaltCommand = u'/usr/bin/mythshutdown --shutdown'
-mythdb.settings.NULL.preSDWUCheckCommand = u'/usr/LH/bin/idle.py -s -d -l -r'
+mythdb.settings.NULL.WakeupTimeFormat = u'time_t'
+mythdb.settings.NULL.SetWakeuptimeCommand = u'sudo /usr/LH/bin/mythwelcome-set-alarm.sh $time'
+mythdb.settings.NULL.ServerHaltCommand = u'sudo /usr/bin/poweroff'
+mythdb.settings.NULL.preSDWUCheckCommand = u'/usr/LH/bin/idle.py -s -d -l'
diff --git a/abs/core/LinHES-system/mythwelcome-set-alarm.sh b/abs/core/LinHES-system/mythwelcome-set-alarm.sh
index 990adf7..09ad062 100755
--- a/abs/core/LinHES-system/mythwelcome-set-alarm.sh
+++ b/abs/core/LinHES-system/mythwelcome-set-alarm.sh
@@ -1,6 +1,6 @@
 #!/bin/sh
 #$1 is the first argument to the script. It is the time in seconds since 1970
-#This is defined in mythwelcome with the time_t argument
+#This is defined in mythwelcome and mythbackend with the time_t argument.
 
 # Configure mythwelcome --setup page:
 # Command to Set Wakeup Time:     sudo sh -c "/usr/LH/bin/mythwelcome-set-alarm.sh $time"
@@ -13,10 +13,10 @@
 
 # Configure mythtv-setup Shutdown/Wakeup Options page:
 # Idletimeout (secs):             any value greater that 0
-# Wakeup time format:             yyyy-MM-ddThh:mm:ss
-# Set wakeup time command:        /usr/bin/mythshutdown --setwakeup $time
-# Server Halt command:            /usr/bin/mythshutdown --shutdown
-# Pre shutdown check command:     /usr/bin/mythshutdown --check 
+# Wakeup time format:             time_t
+# Set wakeup time command:        sudo /usr/LH/bin/mythwelcome-set-alarm.sh $time
+# Server Halt command:            sudo /usr/bin/poweroff
+# Pre shutdown check command:     /usr/bin/mythshutdown --check
 
 echo 0 > /sys/class/rtc/rtc0/wakealarm      #this clears your alarm
 echo $1 > /sys/class/rtc/rtc0/wakealarm     #this writes your alarm
-- 
cgit v0.12


From 9483401f2f1866075d574bdafc4910877367d8b1 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Thu, 4 Jan 2018 14:19:48 +0000
Subject: linhes-theme: status-ui.xml.patch: adjust length of titlesubtitle

---
 abs/core/linhes-theme/PKGBUILD            |   4 +-
 abs/core/linhes-theme/status-ui.xml.patch | 192 ++++++++++++++++++++++++++----
 2 files changed, 170 insertions(+), 26 deletions(-)

diff --git a/abs/core/linhes-theme/PKGBUILD b/abs/core/linhes-theme/PKGBUILD
index 7d12dd6..d45b85e 100755
--- a/abs/core/linhes-theme/PKGBUILD
+++ b/abs/core/linhes-theme/PKGBUILD
@@ -1,6 +1,6 @@
 pkgname=linhes-theme
 pkgver=8.5.1
-pkgrel=2
+pkgrel=4
 pkgdesc="Default LinHES MythTV theme"
 arch=('i686' 'x86_64')
 license=('GPL2')
@@ -115,7 +115,7 @@ md5sums=('2dca856c2a4d1f959473512c94e43b60'
          '958d25f7b932c923cf9f8376063eeb57'
          'a0b6733e4a6734a3c24e8dc3b0c14e74'
          '384871202030f41148536e2e89bb1801'
-         '4d01487b534e45c631734501ec0da501'
+         '979cdd540b672e3383b33188ccb247b6'
          '8312aff444945f80a76100696c81cb2e'
          '81a2706cd36a16a1e0c54d87f3a0857b'
          '4125880d1739b196a8041ecc3d773ee2'
diff --git a/abs/core/linhes-theme/status-ui.xml.patch b/abs/core/linhes-theme/status-ui.xml.patch
index 9c26d77..400f14c 100644
--- a/abs/core/linhes-theme/status-ui.xml.patch
+++ b/abs/core/linhes-theme/status-ui.xml.patch
@@ -1,53 +1,197 @@
---- status-ui.xml.orig	2017-01-12 02:25:29.328323754 +0000
-+++ status-ui.xml	2017-01-12 02:19:35.527174739 +0000
-@@ -212,9 +212,9 @@
+--- status-ui.xml.orig	2018-01-03 21:51:16.028700351 +0000
++++ status-ui.xml	2018-01-03 21:21:37.423911248 +0000
+@@ -170,100 +170,140 @@
+     </window>
  
-         <textarea name="title">
-             <area>4,4,552,64</area>
+     <window name="standbymode">
+-        <area>-1,-1,568,320</area>
++        <area>0,0,1280,720</area>
+ 
+-        <animation trigger="AboutToShow">
+-            <section>
+-                <alpha start="0" end="255" easingcurve="OutQuart"/>
+-                <zoom start="0" end="100" easingcurve="OutQuart"/>
+-            </section>
+-        </animation>
+-
+-        <animation trigger="AboutToHide">
+-            <section>
+-                <alpha start="255" end="0" easingcurve="InQuart"/>
+-                <zoom start="100" end="0" easingcurve="InQuart"/>
+-            </section>
+-        </animation>
++        <textarea name="heading" from="base_heading">
++            <value>Standby</value>
++        </textarea>
+ 
+         <shape name="standbymode-backdrop" from="base_backdrop">
+-            <area>0,0,568,320</area>
++            <area>20,36,1240,649</area>
+         </shape>
+ 
+         <shape name="standbymode-backdrop-line" from="base_backdrop_line">
+-            <area>1,1,566,318</area>
++            <area>21,37,1238,647</area>
+         </shape>
+ 
+         <shape name="standbymode-top-line" from="base_highlight_line">
+-            <area>2,2,564,2</area>
++            <area>22,38,1236,2</area>
+         </shape>
+ 
+         <shape name="standbymode-bottom-line" from="base_highlight_line">
+-            <area>2,316,564,2</area>
++            <area>22,681,1236,2</area>
+         </shape>
+ 
+         <shape name="standbymode-left-line" from="base_highlight_vertical_line">
+-            <area>2,4,2,312</area>
++            <area>22,40,2,641</area>
+         </shape>
+ 
+         <shape name="standbymode-right-line" from="base_highlight_vertical_line">
+-            <area>564,4,2,312</area>
++            <area>1256,40,2,641</area>
+         </shape>
+ 
+-        <textarea name="title">
+-            <area>4,4,552,64</area>
 -            <font>basemedium</font>
-+            <font>basemediumyellow</font>
-             <align>allcenter</align>
+-            <align>allcenter</align>
 -            <value>MythTV is in standby mode!</value>
-+            <value>MythTV is in Standby Mode</value>
-         </textarea>
+-        </textarea>
++        <shape name="standbymode-status-seperator-line" from="base_line">
++            <area>43,100,1194,2</area>
++        </shape>
++
++        <shape name="standbymode-recording-status-seperator-line" from="base_line">
++            <area>43,318,1194,2</area>
++        </shape>
++
++        <shape name="standbymode-scheduled-recording-status-seperator-line" from="base_line">
++            <area>43,536,1194,2</area>
++        </shape>
  
          <statetype name="backendstatus">
-@@ -230,7 +230,7 @@
-                 <textarea name="status">
-                     <area>4,248,552,64</area>
-                     <font>basemediumgreen</font>
+-            <area>4,4,560,312</area>
++            <area>40,40,1200,60</area>
+             <state name="idle">
+-                <area>0,0,560,312</area>
+-                <shape name="icon">
+-                    <area>74,64,412,184</area>
+-                    <type>roundbox</type>
+-                    <fill color="#80d400" />
+-                    <cornerradius>5</cornerradius>
+-                </shape>
+-                <textarea name="status">
+-                    <area>4,248,552,64</area>
+-                    <font>basemediumgreen</font>
 -                    <value>Backend is idle!</value>
++                <area>0,0,1200,60</area>
++                <textarea name="status" from="basetextarea">
++                    <area>0,0,1200,60</area>
++                    <font>baseextralarge</font>
 +                    <value>Backend is Idle</value>
                      <align>allcenter</align>
-                     <multiline>true</multiline>
+-                    <multiline>true</multiline>
                  </textarea>
-@@ -241,16 +241,16 @@
-                 </shape>
+             </state>
+             <state name="recording" from="idle">
+-                <shape name="icon">
+-                    <fill color="#d93636" />
+-                </shape>
                  <textarea name="status">
-                     <font>basemediumred</font>
+-                    <font>basemediumred</font>
 -                    <value>Backend is recording!</value>
 +                    <value>Backend is Recording</value>
                  </textarea>
              </state>
              <state name="shuttingdown" from="idle">
-                 <shape name="icon">
+-                <shape name="icon">
 -                    <fill color="#d9d900" />
-+                    <fill color="#d97616" />
-                 </shape>
+-                </shape>
                  <textarea name="status">
 -                    <font>basemediumyellow</font>
 -                    <value>Shutting Down!</value>
-+                    <font>basemediumorange</font>
 +                    <value>MythTV is Shutting Down</value>
                  </textarea>
              </state>
              <state name="offline" from="idle">
-@@ -259,7 +259,7 @@
-                 </shape>
+-                <shape name="icon">
+-                    <fill color="#d93636" />
+-                </shape>
                  <textarea name="status">
-                     <font>basemediumred</font>
+-                    <font>basemediumred</font>
 -                    <value>Backend is offline!</value>
 +                    <value>Backend is Offline</value>
                  </textarea>
              </state>
          </statetype>
+ 
++        <textarea name="currentrecordingheading" from="basetextarea">
++            <area>40,110,1200,30</area>
++            <font>basemediumlargerdarkyellow</font>
++            <align>allcenter</align>
++            <value>Currently Recording</value>
++        </textarea>
++        <textarea name="nothingrecording" depends="!currentrecording">
++            <area>40,144,1200,170</area>
++            <font>basesmall</font>
++            <align>hcenter,top</align>
++            <value>Nothing is Recording</value>
++        </textarea>
++        <buttonlist name="currentrecording">
++            <area>40,144,1200,170</area>
++            <layout>vertical</layout>
++            <spacing>4</spacing>
++            <scrollstyle>free</scrollstyle>
++            <arrange>stack</arrange>
++            <wrapstyle>items</wrapstyle>
++            <buttonarea>0,0,100%,100%</buttonarea>
++            <statetype name="buttonitem">
++                <state name="active">
++                    <textarea name="shorttimedate" from="basetextarea">
++                        <area>0,1,400,24</area>
++                        <align>right,vcenter</align>
++                    </textarea>
++                    <textarea name="channame" from="shorttimedate">
++                        <area>405,1,180,24</area>
++                        <align>allcenter</align>
++                    </textarea>
++                    <textarea name="titlesubtitle" from="shorttimedate">
++                        <area>590,1,610,24</area>
++                        <align>left,vcenter</align>
++                    </textarea>
++                </state>
++                <state name="selectedactive" from="active"/>
++                <state name="selectedinactive" from="selectedactive" />
++            </statetype>
++        </buttonlist>
++
++        <textarea name="nextrecordingheading" from="currentrecordingheading">
++            <area>40,328,1200,30</area>
++            <value>Upcoming Recordings</value>
++        </textarea>
++        <textarea name="nothingscheduled" depends="!nextrecording" from="nothingrecording">
++            <area>40,362,1200,170</area>
++            <value>No Recordings Are Scheduled</value>
++        </textarea>
++        <buttonlist name="nextrecording" from="currentrecording">
++            <area>40,362,1200,170</area>
++        </buttonlist>
++
++        <textarea name="conflictsheading" from="nextrecordingheading">
++            <area>40,546,1200,30</area>
++            <value>Recording Conflicts</value>
++        </textarea>
++        <textarea name="nothingconflicted" depends="!conflicts" from="nothingrecording">
++            <area>40,580,1200,91</area>
++            <value>No Conflicts</value>
++        </textarea>
++        <buttonlist name="conflicts" from="currentrecording">
++            <area>40,580,1200,91</area>
++        </buttonlist>
++
+     </window>
+ 
+ </mythuitheme>
-- 
cgit v0.12


From 084d8936e356adcdb833244311b203a1b3978538 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Thu, 4 Jan 2018 21:21:45 +0000
Subject: mythtv, mythplugins, mythweb: update to latest fixes

---
 abs/core/mythtv/stable-29/git_src/git_hash         |   2 +-
 abs/core/mythtv/stable-29/git_src/git_hash_web     |   2 +-
 abs/core/mythtv/stable-29/mythplugins/PKGBUILD     |   2 +-
 ...dbase-cache-for-RegisterKey-and-RegisterJ.patch | 276 +++++++++++++++++++++
 abs/core/mythtv/stable-29/mythtv/PKGBUILD          |   4 +-
 abs/core/mythtv/stable-29/mythweb/PKGBUILD         |   2 +-
 6 files changed, 283 insertions(+), 5 deletions(-)
 create mode 100644 abs/core/mythtv/stable-29/mythtv/0259-0117-UI-Provide-dbase-cache-for-RegisterKey-and-RegisterJ.patch

diff --git a/abs/core/mythtv/stable-29/git_src/git_hash b/abs/core/mythtv/stable-29/git_src/git_hash
index d869e90..c3edd34 100644
--- a/abs/core/mythtv/stable-29/git_src/git_hash
+++ b/abs/core/mythtv/stable-29/git_src/git_hash
@@ -1 +1 @@
-39b2062c069e801c9f9c4b15d198e8ef72594f55
+9dbf6706337b72b132f34d6c8e9f305609a44d7e
diff --git a/abs/core/mythtv/stable-29/git_src/git_hash_web b/abs/core/mythtv/stable-29/git_src/git_hash_web
index 5d42c24..38dfcdc 100644
--- a/abs/core/mythtv/stable-29/git_src/git_hash_web
+++ b/abs/core/mythtv/stable-29/git_src/git_hash_web
@@ -1 +1 @@
-6db62758ba7f06eb916a041292f50ec298cc01b0
+99838ff4323d7dfc20fd720d4ed3a2042592df69
diff --git a/abs/core/mythtv/stable-29/mythplugins/PKGBUILD b/abs/core/mythtv/stable-29/mythplugins/PKGBUILD
index 35d18e4..13c6da2 100644
--- a/abs/core/mythtv/stable-29/mythplugins/PKGBUILD
+++ b/abs/core/mythtv/stable-29/mythplugins/PKGBUILD
@@ -9,7 +9,7 @@ pkgname=('mytharchive'
          'mythweather'
          'mythzoneminder')
 pkgver=29
-pkgrel=7
+pkgrel=8
 arch=('i686' 'x86_64')
 url="http://www.mythtv.org"
 license=('GPL')
diff --git a/abs/core/mythtv/stable-29/mythtv/0259-0117-UI-Provide-dbase-cache-for-RegisterKey-and-RegisterJ.patch b/abs/core/mythtv/stable-29/mythtv/0259-0117-UI-Provide-dbase-cache-for-RegisterKey-and-RegisterJ.patch
new file mode 100644
index 0000000..79169e4
--- /dev/null
+++ b/abs/core/mythtv/stable-29/mythtv/0259-0117-UI-Provide-dbase-cache-for-RegisterKey-and-RegisterJ.patch
@@ -0,0 +1,276 @@
+From 53ab06dc745938d2ea74214fc10a2b5446bac01a Mon Sep 17 00:00:00 2001
+From: Lawrence Rust <lvr@softsystem.co.uk>
+Date: Wed, 5 Jun 2013 16:07:56 +0100
+Subject: [PATCH 117/333] UI: Provide dbase cache for RegisterKey and
+ RegisterJump to speed startup
+
+Signed-off-by: Lawrence Rust <lvr@softsystem.co.uk>
+---
+ mythtv/libs/libmythui/mythmainwindow.cpp |  211 +++++++++++++++++++++---------
+ 1 file changed, 147 insertions(+), 64 deletions(-)
+
+diff --git a/mythtv/libs/libmythui/mythmainwindow.cpp b/mythtv/libs/libmythui/mythmainwindow.cpp
+index c765279..226454a 100644
+--- a/mythtv/libs/libmythui/mythmainwindow.cpp
++++ b/mythtv/libs/libmythui/mythmainwindow.cpp
+@@ -25,6 +25,9 @@ using namespace std;
+ #include <QKeyEvent>
+ #include <QKeySequence>
+ #include <QSize>
++#include <QPair>
++#include <QMap>
++#include <QMutexLocker>
+ 
+ // Platform headers
+ #include "unistd.h"
+@@ -1765,67 +1768,107 @@ void MythMainWindow::BindKey(const QString &context, const QString &action,
+ void MythMainWindow::RegisterKey(const QString &context, const QString &action,
+                                  const QString &description, const QString &key)
+ {
+-    QString keybind = key;
+-
+-    MSqlQuery query(MSqlQuery::InitCon());
++    typedef QPair< QString,QString > key_t; // context, action
++    typedef QPair< QString,QString > val_t; // keybind, description
++    typedef QMap< key_t,val_t > cache_t;
++    static cache_t s_cache;
++    static QMutex s_mutex;
+ 
+-    if (d->m_useDB && query.isConnected())
++    if (s_cache.empty() && d->m_useDB)
+     {
+-        query.prepare("SELECT keylist, description FROM keybindings WHERE "
+-                      "context = :CONTEXT AND action = :ACTION AND "
+-                      "hostname = :HOSTNAME ;");
+-        query.bindValue(":CONTEXT", context);
+-        query.bindValue(":ACTION", action);
+-        query.bindValue(":HOSTNAME", GetMythDB()->GetHostName());
+-
+-        if (query.exec() && query.next())
++        MSqlQuery query(MSqlQuery::InitCon());
++        if (query.isConnected())
+         {
+-            keybind = query.value(0).toString();
+-            QString db_description = query.value(1).toString();
+-
+-            // Update keybinding description if changed
+-            if (db_description != description)
++            query.prepare("SELECT context, action, keylist, description "
++                          "FROM keybindings WHERE hostname = :HOSTNAME ;");
++            query.bindValue(":HOSTNAME", GetMythDB()->GetHostName());
++            if (query.exec())
+             {
+-                LOG(VB_GENERAL, LOG_NOTICE,
+-                    "Updating keybinding description...");
+-                query.prepare(
+-                    "UPDATE keybindings "
+-                    "SET description = :DESCRIPTION "
+-                    "WHERE context   = :CONTEXT AND "
+-                    "      action    = :ACTION  AND "
+-                    "      hostname  = :HOSTNAME");
+-
+-                query.bindValue(":DESCRIPTION", description);
+-                query.bindValue(":CONTEXT",     context);
+-                query.bindValue(":ACTION",      action);
+-                query.bindValue(":HOSTNAME",    GetMythDB()->GetHostName());
+-
+-                if (!query.exec() && !(GetMythDB()->SuppressDBMessages()))
++                QMutexLocker locker(&s_mutex);
++                while (query.next())
+                 {
+-                    MythDB::DBError("Update Keybinding", query);
++                    key_t k(query.value(0).toString(), query.value(1).toString());
++                    val_t v(query.value(2).toString(), query.value(3).toString());
++                    s_cache[k] = v;
+                 }
+             }
++            else if (!GetMythDB()->SuppressDBMessages())
++                MythDB::DBError("RegisterKey", query);
+         }
+-        else
++    }
++
++    QString keybind = key;
++    QString db_description;
++    bool bFound = false;
++    {
++        QMutexLocker locker(&s_mutex);
++        cache_t::const_iterator it = s_cache.find(key_t(context, action));
++        if (it != s_cache.end())
+         {
+-            QString inskey = keybind;
+-
+-            query.prepare("INSERT INTO keybindings (context, action, "
+-                          "description, keylist, hostname) VALUES "
+-                          "( :CONTEXT, :ACTION, :DESCRIPTION, :KEYLIST, "
+-                          ":HOSTNAME );");
+-            query.bindValue(":CONTEXT", context);
+-            query.bindValue(":ACTION", action);
++            keybind = it->first;
++            db_description = it->second;
++            bFound = true;
++        }
++    }
++
++    if (bFound)
++    {
++        // Update keybinding description if changed
++        if (db_description != description && d->m_useDB)
++        {
++            LOG(VB_GENERAL, LOG_NOTICE, "Updating keybinding description...");
++
++            MSqlQuery query(MSqlQuery::InitCon());
++
++            query.prepare(
++                "UPDATE keybindings "
++                "SET description = :DESCRIPTION "
++                "WHERE context   = :CONTEXT AND "
++                "      action    = :ACTION  AND "
++                "      hostname  = :HOSTNAME");
++
+             query.bindValue(":DESCRIPTION", description);
+-            query.bindValue(":KEYLIST", inskey);
+-            query.bindValue(":HOSTNAME", GetMythDB()->GetHostName());
++            query.bindValue(":CONTEXT",     context);
++            query.bindValue(":ACTION",      action);
++            query.bindValue(":HOSTNAME",    GetMythDB()->GetHostName());
+ 
+             if (!query.exec() && !(GetMythDB()->SuppressDBMessages()))
+             {
+-                MythDB::DBError("Insert Keybinding", query);
++                MythDB::DBError("Update Keybinding", query);
+             }
+         }
+     }
++    else if (d->m_useDB)
++    {
++        LOG(VB_GENERAL, LOG_NOTICE, QString("Add keybinding %1::%2 = %3")
++            .arg(context).arg(action).arg(keybind) );
++
++        MSqlQuery query(MSqlQuery::InitCon());
++
++        QString inskey = keybind;
++
++        query.prepare("INSERT INTO keybindings (context, action, "
++                      "description, keylist, hostname) VALUES "
++                      "( :CONTEXT, :ACTION, :DESCRIPTION, :KEYLIST, "
++                      ":HOSTNAME );");
++        query.bindValue(":CONTEXT", context);
++        query.bindValue(":ACTION", action);
++        query.bindValue(":DESCRIPTION", description);
++        query.bindValue(":KEYLIST", inskey);
++        query.bindValue(":HOSTNAME", GetMythDB()->GetHostName());
++
++        if (!query.exec() && !(GetMythDB()->SuppressDBMessages()))
++        {
++            MythDB::DBError("Insert Keybinding", query);
++        }
++        else
++        {
++            QMutexLocker locker(&s_mutex);
++            key_t k(context, action);
++            val_t v(keybind, description);
++            s_cache[k] = v;
++        }
++    }
+ 
+     BindKey(context, action, keybind);
+     d->actionText[context][action] = description;
+@@ -1930,35 +1973,75 @@ void MythMainWindow::RegisterJump(const QString &destination,
+                                   const QString &key, void (*callback)(void),
+                                   bool exittomain, QString localAction)
+ {
+-    QString keybind = key;
++    typedef QPair< QString,QString > val_t; // keylist, description
++    typedef QMap< QString,val_t > cache_t; // destination -> keylist, description
++    static cache_t s_cache;
++    static QMutex s_mutex;
+ 
+-    MSqlQuery query(MSqlQuery::InitCon());
+-    if (query.isConnected())
++    if (s_cache.empty() && d->m_useDB)
+     {
+-        query.prepare("SELECT keylist FROM jumppoints WHERE "
+-                      "destination = :DEST and hostname = :HOST ;");
+-        query.bindValue(":DEST", destination);
+-        query.bindValue(":HOST", GetMythDB()->GetHostName());
+-
+-        if (query.exec() && query.next())
++        MSqlQuery query(MSqlQuery::InitCon());
++        if (query.isConnected())
+         {
+-            keybind = query.value(0).toString();
++            query.prepare("SELECT destination, keylist, description "
++                          "FROM jumppoints WHERE hostname = :HOSTNAME ;");
++            query.bindValue(":HOSTNAME", GetMythDB()->GetHostName());
++            if (query.exec())
++            {
++                QMutexLocker locker(&s_mutex);
++                while (query.next())
++                {
++                    val_t v(query.value(1).toString(), query.value(2).toString());
++                    s_cache.insert(query.value(0).toString(), v);
++                }
++            }
++            else if (!GetMythDB()->SuppressDBMessages())
++                MythDB::DBError("RegisterJump", query);
+         }
+-        else
++    }
++
++    QString keybind = key;
++    bool bFound = false;
++    {
++        QMutexLocker locker(&s_mutex);
++        cache_t::const_iterator it = s_cache.find(destination);
++        if (it != s_cache.end())
+         {
+-            QString inskey = keybind;
++            keybind = it->first;
++            bFound = true;
++        }
++    }
+ 
+-            query.prepare("INSERT INTO jumppoints (destination, description, "
+-                          "keylist, hostname) VALUES ( :DEST, :DESC, :KEYLIST, "
+-                          ":HOST );");
++    if (!bFound)
++    {
++        MSqlQuery query(MSqlQuery::InitCon());
++        if (query.isConnected())
++        {
++            query.prepare("SELECT keylist FROM jumppoints WHERE "
++                          "destination = :DEST and hostname = :HOST ;");
+             query.bindValue(":DEST", destination);
+-            query.bindValue(":DESC", description);
+-            query.bindValue(":KEYLIST", inskey);
+             query.bindValue(":HOST", GetMythDB()->GetHostName());
+ 
+-            if (!query.exec() || !query.isActive())
++            if (query.exec() && query.next())
+             {
+-                MythDB::DBError("Insert Jump Point", query);
++                keybind = query.value(0).toString();
++            }
++            else
++            {
++                QString inskey = keybind;
++
++                query.prepare("INSERT INTO jumppoints (destination, description, "
++                              "keylist, hostname) VALUES ( :DEST, :DESC, :KEYLIST, "
++                              ":HOST );");
++                query.bindValue(":DEST", destination);
++                query.bindValue(":DESC", description);
++                query.bindValue(":KEYLIST", inskey);
++                query.bindValue(":HOST", GetMythDB()->GetHostName());
++
++                if (!query.exec() || !query.isActive())
++                {
++                    MythDB::DBError("Insert Jump Point", query);
++                }
+             }
+         }
+     }
+-- 
+1.7.9.5
+
diff --git a/abs/core/mythtv/stable-29/mythtv/PKGBUILD b/abs/core/mythtv/stable-29/mythtv/PKGBUILD
index ce77213..3a8faed 100644
--- a/abs/core/mythtv/stable-29/mythtv/PKGBUILD
+++ b/abs/core/mythtv/stable-29/mythtv/PKGBUILD
@@ -1,6 +1,6 @@
 pkgname=mythtv
 pkgver=29
-pkgrel=7
+pkgrel=8
 commit_hash=`cat ../git_src/git_hash`
 pkgdesc="A Homebrew PVR project $commit_hash"
 arch=('i686' 'x86_64')
@@ -37,6 +37,7 @@ patches=(
          '0292-UPnP-Reduce-startup-latency-by-moving-blocking-code-to-own-thread.patch'
          '0294-0283-FE-Add-network-status-to-machine-status-dialog.patch'
          '0287-MythUiImage-Don-t-block-UI-when-exiting-screens.patch'
+         '0259-0117-UI-Provide-dbase-cache-for-RegisterKey-and-RegisterJ.patch'
          )
 
 optdepends=()
@@ -135,4 +136,5 @@ md5sums=('fb5a87c52a31168a0c8fdde72f27cc45'
          '1f0dbd44f8c1a89b86bb331086f58578'
          'abaef221b00690b329f4dca18676bcd6'
          '3cccbab70c7615bc47e51790e024d5bf'
+         '4b5f00a19006b915b7ee5ab7f861599a'
          '633cd853a89aeee5388daaad21ccec28')
diff --git a/abs/core/mythtv/stable-29/mythweb/PKGBUILD b/abs/core/mythtv/stable-29/mythweb/PKGBUILD
index d294694..25dd0d9 100644
--- a/abs/core/mythtv/stable-29/mythweb/PKGBUILD
+++ b/abs/core/mythtv/stable-29/mythweb/PKGBUILD
@@ -1,6 +1,6 @@
 pkgname=mythweb
 pkgver=29
-pkgrel=2
+pkgrel=3
 commit_hash=`cat ../git_src/git_hash_web`
 pkgdesc="Web interface for MythTV's backend, $commit_hash"
 arch=('i686' 'x86_64')
-- 
cgit v0.12


From 8d3d5fc17ddda68793375eb9910213eee8f1bf67 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Tue, 9 Jan 2018 15:07:58 +0000
Subject: LinHES-system: mythwelcome-config.py: change some settings so daily
 wake is respected

---
 abs/core/LinHES-system/PKGBUILD                 | 6 +++---
 abs/core/LinHES-system/mythwelcome-config.py    | 6 +++---
 abs/core/LinHES-system/mythwelcome-set-alarm.sh | 6 +++---
 3 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/abs/core/LinHES-system/PKGBUILD b/abs/core/LinHES-system/PKGBUILD
index 5d4252b..5ecc711 100755
--- a/abs/core/LinHES-system/PKGBUILD
+++ b/abs/core/LinHES-system/PKGBUILD
@@ -1,6 +1,6 @@
 pkgname=LinHES-system
 pkgver=8.5.1
-pkgrel=1
+pkgrel=2
 arch=('i686' 'x86_64')
 install=system.install
 pkgdesc="Everything that makes LinHES an automated system"
@@ -135,8 +135,8 @@ md5sums=('c6e6b83a1f4c35ef4501e277657ab2ac'
          '28f29578e5b3ba84fdf2aa57cf475bcf'
          '4a1fda884dcd7d65fb2690fbdbd92a83'
          '29f451783db3220b612e00c29e3ded73'
-         '0b80d8e364652b144324f7c3e0f04ecb'
-         '3b27dd20cc35dce9bdad017087c9cf15'
+         '7fe42dfc99af42a45440c9c3954c3c19'
+         '411b2c22c66833cc8e85021992409f1f'
          '410795ef9039e4c6c0484e706ecfd567'
          'eb879fee9603a05d5420d4ce8ed9e450'
          '02c810c2f47b7c4495fdacaf54189473'
diff --git a/abs/core/LinHES-system/mythwelcome-config.py b/abs/core/LinHES-system/mythwelcome-config.py
index 5a8727f..f3f96fc 100755
--- a/abs/core/LinHES-system/mythwelcome-config.py
+++ b/abs/core/LinHES-system/mythwelcome-config.py
@@ -25,7 +25,7 @@ if mythdb.settings[localhostname].HostSystemType == u'Master_backend':
     else:
         mythdb.settings.NULL.idleTimeoutSecs = u'0'
 
-mythdb.settings.NULL.WakeupTimeFormat = u'time_t'
-mythdb.settings.NULL.SetWakeuptimeCommand = u'sudo /usr/LH/bin/mythwelcome-set-alarm.sh $time'
-mythdb.settings.NULL.ServerHaltCommand = u'sudo /usr/bin/poweroff'
+mythdb.settings.NULL.WakeupTimeFormat = u'yyyy-MM-ddThh:mm:ss'
+mythdb.settings.NULL.SetWakeuptimeCommand = u'/usr/bin/mythshutdown --setwakeup $time'
+mythdb.settings.NULL.ServerHaltCommand = u'/usr/bin/mythshutdown --shutdown'
 mythdb.settings.NULL.preSDWUCheckCommand = u'/usr/LH/bin/idle.py -s -d -l'
diff --git a/abs/core/LinHES-system/mythwelcome-set-alarm.sh b/abs/core/LinHES-system/mythwelcome-set-alarm.sh
index 09ad062..7b10372 100755
--- a/abs/core/LinHES-system/mythwelcome-set-alarm.sh
+++ b/abs/core/LinHES-system/mythwelcome-set-alarm.sh
@@ -13,9 +13,9 @@
 
 # Configure mythtv-setup Shutdown/Wakeup Options page:
 # Idletimeout (secs):             any value greater that 0
-# Wakeup time format:             time_t
-# Set wakeup time command:        sudo /usr/LH/bin/mythwelcome-set-alarm.sh $time
-# Server Halt command:            sudo /usr/bin/poweroff
+# Wakeup time format:             yyyy-MM-ddThh:mm:ss
+# Set wakeup time command:        /usr/bin/mythshutdown --setwakeup $time
+# Server Halt command:            /usr/bin/mythshutdown --shutdown
 # Pre shutdown check command:     /usr/bin/mythshutdown --check
 
 echo 0 > /sys/class/rtc/rtc0/wakealarm      #this clears your alarm
-- 
cgit v0.12


From d0045640af11043af151ae0768002c5382259537 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Tue, 9 Jan 2018 15:48:34 +0000
Subject: web-on-linhes: add espn.com

add /home/mythtv/.wol-custom-cmds.sh to run cmds to control a web page
---
 abs/extra/web-on-linhes/PKGBUILD              | 16 ++++++++++------
 abs/extra/web-on-linhes/web-on-linhes.sh      |  5 ++++-
 abs/extra/web-on-linhes/web-on-linhes_is.conf | 10 +++++++++-
 abs/extra/web-on-linhes/wol-custom-cmds.sh    | 13 +++++++++++++
 4 files changed, 36 insertions(+), 8 deletions(-)
 create mode 100755 abs/extra/web-on-linhes/wol-custom-cmds.sh

diff --git a/abs/extra/web-on-linhes/PKGBUILD b/abs/extra/web-on-linhes/PKGBUILD
index 0a28e81..0746933 100644
--- a/abs/extra/web-on-linhes/PKGBUILD
+++ b/abs/extra/web-on-linhes/PKGBUILD
@@ -2,22 +2,26 @@
 # Maintainer: Cecil Watson<knoppmyth@gmail.com>
 
 pkgname=web-on-linhes
-pkgver=1.3
-pkgrel=3
+pkgver=1.4
+pkgrel=1
 pkgdesc="Added multiple websites with 10' UIs to Play Online Streams."
 arch=('i686' 'x86_64')
 license=('GPL2')
 url="http://www.linhes.org/"
 depends=('google-chrome')
 install=web-on-linhes.install
-source=('web-on-linhes.sh' 'web-on-linhes_is.conf')
+source=('web-on-linhes.sh' 'web-on-linhes_is.conf' 'wol-custom-cmds.sh')
+backup=('home/mythtv/.wol-custom-cmds.sh')
 
 package() {
 	cd ${srcdir}
 	install -d ${pkgdir}/usr/LH/bin
-	install -D -m755 *.sh ${pkgdir}/usr/LH/bin
+	install -D -m755 web-on-linhes.sh ${pkgdir}/usr/LH/bin
     #add in file for gen_is.xml
     install -D -m0744 ${srcdir}/web-on-linhes_is.conf ${pkgdir}/etc/gen_is_xml.d/web-on-linhes_is.conf
+    #add wol-custom-cmds file
+    install -D -o1000 -g1000 -m755 ${srcdir}/wol-custom-cmds.sh ${pkgdir}/home/mythtv/.wol-custom-cmds.sh
 }
-md5sums=('3691faa7118ac1251c959d3bcfcba85f'
-         '61cafa7e7a11b1387202b6ef908105a7')
+md5sums=('f37e208b713ee5b5b3ac54b63597f39f'
+         '7eb75860715a84e7e75b804e159adf35'
+         '9f59fabdf944a7381919d4c8407ac21c')
diff --git a/abs/extra/web-on-linhes/web-on-linhes.sh b/abs/extra/web-on-linhes/web-on-linhes.sh
index 48414e9..3c458dd 100644
--- a/abs/extra/web-on-linhes/web-on-linhes.sh
+++ b/abs/extra/web-on-linhes/web-on-linhes.sh
@@ -7,7 +7,10 @@ irxPID=$!
 stop_xss.sh &
 xssPID=$!
 #Launches chrome in full screen
-(sleep 1; wmctrl -r "Google Chrome" -b add,fullscreen) &
+(sleep 3; wmctrl -r "Google Chrome" -b add,fullscreen) &
+#Launches file to run any custom cmds
+(sleep 4; /home/mythtv/.wol-custom-cmds.sh $@) &
+#Launch chrome
 google-chrome --no-first-run --kiosk $@
 #Once done, stops irxevent and stop_xss.sh
 kill $irxPID
diff --git a/abs/extra/web-on-linhes/web-on-linhes_is.conf b/abs/extra/web-on-linhes/web-on-linhes_is.conf
index 982bd8e..2913ec0 100755
--- a/abs/extra/web-on-linhes/web-on-linhes_is.conf
+++ b/abs/extra/web-on-linhes/web-on-linhes_is.conf
@@ -1,6 +1,14 @@
   <!--#WebOnTV-->
      <button>
        <type>STREAM</type>
+       <text>ESPN</text>
+       <action>EXEC /usr/LH/bin/web-on-linhes.sh http://www.espn.com/watch</action>
+     </button>
+  <!--#WebOnTV-->
+
+  <!--#WebOnTV-->
+     <button>
+       <type>STREAM</type>
        <text>NetFlix</text>
        <action>EXEC /usr/LH/bin/web-on-linhes.sh http://netflix.com/WiHome</action>
      </button>
@@ -17,7 +25,7 @@
   <!--#WebOnTV-->
      <button>
        <type>STREAM</type>
-       <text>TuneIn </text>
+       <text>TuneIn</text>
        <action>EXEC /usr/LH/bin/web-on-linhes.sh http://tv.tunein.com/</action>
      </button>
   <!--#WebOnTV-->
diff --git a/abs/extra/web-on-linhes/wol-custom-cmds.sh b/abs/extra/web-on-linhes/wol-custom-cmds.sh
new file mode 100755
index 0000000..2386378
--- /dev/null
+++ b/abs/extra/web-on-linhes/wol-custom-cmds.sh
@@ -0,0 +1,13 @@
+#!/bin/bash
+
+# Launch commands to control a web page
+# $@ contains the website that was opened
+# The espn example moves the mouse and clicks to make the player active
+#   Then the f key is pressed to make the video fullscreen
+
+if [[ $@ == *"espn.com"* ]];
+then
+    sleep 7
+    xdotool mousemove 722 531 click 1 click 1
+    xdotool key f
+fi
-- 
cgit v0.12


From 5e60e91aca4fdf4e178f999a73e1b197c89795db Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Tue, 9 Jan 2018 15:55:27 +0000
Subject: xdotool: update to 3.20160805.1

---
 abs/core/xdotool/PKGBUILD | 26 ++++++++++++++++----------
 1 file changed, 16 insertions(+), 10 deletions(-)

diff --git a/abs/core/xdotool/PKGBUILD b/abs/core/xdotool/PKGBUILD
index 0ce58a3..f8f1236 100644
--- a/abs/core/xdotool/PKGBUILD
+++ b/abs/core/xdotool/PKGBUILD
@@ -1,26 +1,32 @@
-# $Id: PKGBUILD 48265 2011-05-30 19:01:31Z foutrelis $
-# Maintainer: Evangelos Foutras <foutrelis@gmail.com>
+# $Id$
+# Maintainer: Evangelos Foutras <evangelos@foutrelis.com>
 # Contributor: Rttommy <rttommy@gmail.com>
 
 pkgname=xdotool
-pkgver=2.20110530.1
+pkgver=3.20160805.1
 pkgrel=1
 pkgdesc="Command-line X11 automation tool"
-arch=('i686' 'x86_64')
+arch=('x86_64')
 url="http://www.semicomplete.com/projects/xdotool/"
 license=('BSD')
-depends=('libxtst' 'libxinerama')
-source=(http://semicomplete.googlecode.com/files/$pkgname-$pkgver.tar.gz)
-sha1sums=('bf8372b2e76e8ee3884763cee6e8b3f66bf29aa6')
+depends=('libxtst' 'libxinerama' 'libxkbcommon')
+source=(https://github.com/jordansissel/xdotool/releases/download/v$pkgver/$pkgname-$pkgver.tar.gz)
+sha256sums=('35be5ff6edf0c620a0e16f09ea5e101d5173280161772fca18657d83f20fcca8')
 
 build() {
   cd "$srcdir/$pkgname-$pkgver"
+  make WITHOUT_RPATH_FIX=1
+}
+
+package() {
+  cd "$srcdir/$pkgname-$pkgver"
 
-  make
   make PREFIX="$pkgdir/usr" INSTALLMAN="$pkgdir/usr/share/man" install
 
-  # License
-  install -Dm644 COPYRIGHT "$pkgdir/usr/share/licenses/xdotool/COPYRIGHT"
+  # Remove execute bit from header file
+  chmod -x "$pkgdir/usr/include/xdo.h"
+
+  install -Dm644 COPYRIGHT "$pkgdir/usr/share/licenses/$pkgname/COPYRIGHT"
 }
 
 # vim:set ts=2 sw=2 et:
-- 
cgit v0.12


From 9b78781d4221bc00563906f7d972e1370a0ef6b1 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Tue, 16 Jan 2018 18:18:09 +0000
Subject: mythtv & mythplugins: update to latest fixes

add Auto Shutdown menu to System Menu
---
 abs/core/mythtv/stable-29/git_src/git_hash         |  2 +-
 abs/core/mythtv/stable-29/mythplugins/PKGBUILD     |  2 +-
 abs/core/mythtv/stable-29/mythtv/PKGBUILD          |  4 +-
 .../addEnableDisableAutoShutdownToSystemMenu.patch | 50 ++++++++++++++++++++++
 4 files changed, 55 insertions(+), 3 deletions(-)
 create mode 100644 abs/core/mythtv/stable-29/mythtv/addEnableDisableAutoShutdownToSystemMenu.patch

diff --git a/abs/core/mythtv/stable-29/git_src/git_hash b/abs/core/mythtv/stable-29/git_src/git_hash
index c3edd34..2ce2a78 100644
--- a/abs/core/mythtv/stable-29/git_src/git_hash
+++ b/abs/core/mythtv/stable-29/git_src/git_hash
@@ -1 +1 @@
-9dbf6706337b72b132f34d6c8e9f305609a44d7e
+771115f47d39095652f8f660d3477008a0cbce12
diff --git a/abs/core/mythtv/stable-29/mythplugins/PKGBUILD b/abs/core/mythtv/stable-29/mythplugins/PKGBUILD
index 13c6da2..a6132b3 100644
--- a/abs/core/mythtv/stable-29/mythplugins/PKGBUILD
+++ b/abs/core/mythtv/stable-29/mythplugins/PKGBUILD
@@ -9,7 +9,7 @@ pkgname=('mytharchive'
          'mythweather'
          'mythzoneminder')
 pkgver=29
-pkgrel=8
+pkgrel=9
 arch=('i686' 'x86_64')
 url="http://www.mythtv.org"
 license=('GPL')
diff --git a/abs/core/mythtv/stable-29/mythtv/PKGBUILD b/abs/core/mythtv/stable-29/mythtv/PKGBUILD
index 3a8faed..cdac547 100644
--- a/abs/core/mythtv/stable-29/mythtv/PKGBUILD
+++ b/abs/core/mythtv/stable-29/mythtv/PKGBUILD
@@ -1,6 +1,6 @@
 pkgname=mythtv
 pkgver=29
-pkgrel=8
+pkgrel=9
 commit_hash=`cat ../git_src/git_hash`
 pkgdesc="A Homebrew PVR project $commit_hash"
 arch=('i686' 'x86_64')
@@ -31,6 +31,7 @@ patches=(
          'searchMetatdataSelectedGrabber.patch'
          'addDamagedToProgDetails.patch'
          'defaultThemeLinHES.patch'
+         'addEnableDisableAutoShutdownToSystemMenu.patch'
          'mythfrontend_en_us.ts_Title_Case.patch'
          '0006-cardutil_show_displayname.patch'
          '0037-pull103-Add-heuristic-in-TMDB-script-to-detect-movie-release-years.patch'
@@ -130,6 +131,7 @@ md5sums=('fb5a87c52a31168a0c8fdde72f27cc45'
          '0f674b9cad031ba1e03aaf6b5ee1499f'
          '6add9c16bbb988067e82029327e567b2'
          'b0b238320fa78a4928dce2cea7c85071'
+         '8e4492d1777234a021f368bd6ee964ee'
          '1164214d9eb41588f8eb3382565cb003'
          '5f2bd4065b145b7b7ff09dfd6f08276c'
          '2371cf6e680179c067a6ff7756638128'
diff --git a/abs/core/mythtv/stable-29/mythtv/addEnableDisableAutoShutdownToSystemMenu.patch b/abs/core/mythtv/stable-29/mythtv/addEnableDisableAutoShutdownToSystemMenu.patch
new file mode 100644
index 0000000..b14e2e0
--- /dev/null
+++ b/abs/core/mythtv/stable-29/mythtv/addEnableDisableAutoShutdownToSystemMenu.patch
@@ -0,0 +1,50 @@
+diff --git a/mythtv/libs/libmythui/myththemedmenu.cpp b/mythtv/libs/libmythui/myththemedmenu.cpp
+index ed2e54c..77aaf73 100644
+--- a/mythtv/libs/libmythui/myththemedmenu.cpp
++++ b/mythtv/libs/libmythui/myththemedmenu.cpp
+@@ -308,6 +308,8 @@ void MythThemedMenu::ShowMenu()
+         return;
+ 
+     int override_menu = GetMythDB()->GetNumSetting("OverrideExitMenu");
++    int MythShutdownLock = GetMythDB()->GetNumSetting("MythShutdownLock");
++    int idleTimeoutSecs = GetMythDB()->GetNumSetting("idleTimeoutSecs");
+     QString label = tr("System Menu");
+     MythScreenStack* mainStack = GetMythMainWindow()->GetMainStack();
+     m_menuPopup = new MythDialogBox(label, mainStack, "menuPopup");
+@@ -325,6 +327,21 @@ void MythThemedMenu::ShowMenu()
+     if (override_menu != 7)
+         m_menuPopup->AddButton(tr("Exit application"), QVariant("exit"));
+ 
++    // don't offer to enable/disable auto shutdown if auto shutdown is disabled
++    if (idleTimeoutSecs != 0)
++    {
++        if (MythShutdownLock == 0)
++        {
++            m_menuPopup->AddButton(tr("Disable Auto Shutdown"),
++                                    QVariant("lockShutdown"));
++        }
++        else
++        {
++            m_menuPopup->AddButton(tr("Enable Auto Shutdown"),
++                                    QVariant("unlockShutdown"));
++        }
++    }
++
+     switch (override_menu)
+     {
+         case 2:
+@@ -416,6 +433,14 @@ void MythThemedMenu::customEvent(QEvent *event)
+                 QString arg("exiting_app");
+                 m_state->m_callback(m_state->m_callbackdata, arg);
+             }
++            else if (action == "lockShutdown")
++            {
++                GetMythDB()->SaveSettingOnHost("MythShutdownLock", "1", NULL);
++            }
++            else if (action == "unlockShutdown")
++            {
++                GetMythDB()->SaveSettingOnHost("MythShutdownLock", "0", NULL);
++            }
+         }
+         else if (resultid == "password")
+         {
-- 
cgit v0.12


From d3bcf5aad566eddc2514d84c148ed1f7d0ee4033 Mon Sep 17 00:00:00 2001
From: Britney Fransen <brfransen@gmail.com>
Date: Tue, 16 Jan 2018 18:22:01 +0000
Subject: supplemental-web: fe_status.py: change get frontend method and add IP
 address

---
 abs/core/supplemental-web/PKGBUILD              |  4 +--
 abs/core/supplemental-web/contents/fe_status.py | 39 +++++++++++++------------
 2 files changed, 23 insertions(+), 20 deletions(-)

diff --git a/abs/core/supplemental-web/PKGBUILD b/abs/core/supplemental-web/PKGBUILD
index ea70a2e..4fcef9e 100644
--- a/abs/core/supplemental-web/PKGBUILD
+++ b/abs/core/supplemental-web/PKGBUILD
@@ -1,7 +1,7 @@
 pkgbase=supplemental-web
 pkgname=('supplemental-web' 'supplemental-web-slave')
-pkgver=8.4
-pkgrel=3
+pkgver=8.5
+pkgrel=1
 arch=('i686' 'x86_64')
 license=('GPL')
 backup=('data/srv/httpd/cgi/extra.cfg.txt')
diff --git a/abs/core/supplemental-web/contents/fe_status.py b/abs/core/supplemental-web/contents/fe_status.py
index 993ef72..439d0c5 100644
--- a/abs/core/supplemental-web/contents/fe_status.py
+++ b/abs/core/supplemental-web/contents/fe_status.py
@@ -25,7 +25,8 @@ def parse_xml(frontend):
         tree = ET.parse(xml)
         root = tree.getroot()
     except:
-        msg("   Couldn't connect to %s" %frontend)
+        #msg("   Couldn't connect to %s" %frontend)
+        temp_dict['state'] = "offline"
         return temp_dict
 
     lst = root.find("State")
@@ -51,23 +52,25 @@ def parse_xml(frontend):
 
 
 def mythfe_status(cursor,mythDB):
-    frontends=list(Frontend.fromUPNP())
     status_dict={}
-    #try:
+    try:
         #frontends = mythDB.getFrontends() #use cursor instead so it doesn't test connection
-        #cursor.execute("select hostname from settings where value = 'FrontendIdleTimeout'")
-        #frontends=cursor.fetchall()
-    #except:
-        #msg("Excptions")
-        #return
+        cursor.execute("select distinct hostname from settings where hostname is not null;")
+        frontends=cursor.fetchall()
+    except:
+        #msg("Exceptions")
+        return
 
     for i in frontends:
+        i=''.join(i)
         try:
-            fe_hostname = socket.gethostbyaddr(i.host)[0]
+            fe_hostname = socket.gethostbyaddr(i)[0]
         except:
-            print "DNS lookup failed for %s" %i.host
-            fe_hostname = i.host
-        status_dict[fe_hostname] = parse_xml(i.host)
+            #print "DNS lookup failed for %s" %i
+            fe_hostname = socket.gethostbyname(i)
+        ip_addr = socket.gethostbyname(i)
+        fe_hostname = "%s (%s)" %(fe_hostname,ip_addr)
+        status_dict[fe_hostname] = parse_xml(ip_addr)
 
     return status_dict
 
@@ -102,12 +105,12 @@ def print_html(status_dict):
     print "</table>"
     print '</div>'
 
-    print '''
-    <div id="footer">
-       </br>
-       <p>Offline systems are not listed</p>
-    </div>
-'''
+#    print '''
+#    <div id="footer">
+#       </br>
+#       <p>Offline systems are not listed</p>
+#    </div>
+#'''
 
 
 def main():
-- 
cgit v0.12