android: Improve workflow on devices with root

During initial scan of application, detect if root access is available
and track it.  If user later selects "Click here for ways to fix this".
display a new dialogue that offers to push the layer directly.

If pushing fails, fall back to production dialogue.

Also add a new persistent setting to enable automatic layer pushing.
This commit is contained in:
Cody Northrop
2017-08-07 14:41:36 -06:00
committed by Baldur Karlsson
parent 6c40e4e651
commit fb8eef23d0
8 changed files with 149 additions and 11 deletions
@@ -63,6 +63,7 @@ SettingsDialog::SettingsDialog(ICaptureContext &ctx, QWidget *parent)
}
ui->Android_AdbExecutablePath->setText(m_Ctx.Config().Android_AdbExecutablePath);
ui->Android_MaxConnectTimeout->setValue(m_Ctx.Config().Android_MaxConnectTimeout);
ui->Android_AutoPushLayerToApp->setChecked(m_Ctx.Config().Android_AutoPushLayerToApp);
ui->TextureViewer_ResetRange->setChecked(m_Ctx.Config().TextureViewer_ResetRange);
ui->TextureViewer_PerTexSettings->setChecked(m_Ctx.Config().TextureViewer_PerTexSettings);
@@ -378,3 +379,10 @@ void SettingsDialog::on_Android_AdbExecutablePath_textEdited(const QString &adb)
m_Ctx.Config().Save();
}
void SettingsDialog::on_Android_AutoPushLayerToApp_toggled(bool checked)
{
m_Ctx.Config().Android_AutoPushLayerToApp = ui->Android_AutoPushLayerToApp->isChecked();
m_Ctx.Config().Save();
}