Merge pull request #3903 from Mailaender/gameinit-redundancy
Removed the now redundant per mod Install/DownloadPackagesLogic
This commit is contained in:
@@ -14,10 +14,10 @@ using OpenRA.Widgets;
|
||||
|
||||
namespace OpenRA.Mods.RA.Widgets.Logic
|
||||
{
|
||||
public class RAInstallLogic
|
||||
public class InstallLogic : Widget
|
||||
{
|
||||
[ObjectCreator.UseCtor]
|
||||
public RAInstallLogic(Widget widget, Dictionary<string, string> installData, Action continueLoading)
|
||||
public InstallLogic(Widget widget, Dictionary<string, string> installData, Action continueLoading)
|
||||
{
|
||||
var panel = widget.Get("INSTALL_PANEL");
|
||||
var args = new WidgetArgs()
|
||||
@@ -30,6 +30,15 @@ namespace OpenRA.Mods.RA.Widgets.Logic
|
||||
panel.Get<ButtonWidget>("DOWNLOAD_BUTTON").OnClick = () =>
|
||||
Ui.OpenWindow("INSTALL_DOWNLOAD_PANEL", args);
|
||||
|
||||
if (installData.ContainsKey("FilesToCopy") && !string.IsNullOrEmpty(installData["FilesToCopy"]) &&
|
||||
installData.ContainsKey("FilesToExtract") && !string.IsNullOrEmpty(installData["FilesToExtract"]))
|
||||
{
|
||||
args = new WidgetArgs(args)
|
||||
{
|
||||
{ "filesToCopy", installData["FilesToCopy"].Split(',') },
|
||||
{ "filesToExtract", installData["FilesToExtract"].Split(',') },
|
||||
};
|
||||
}
|
||||
panel.Get<ButtonWidget>("INSTALL_BUTTON").OnClick = () =>
|
||||
Ui.OpenWindow("INSTALL_FROMCD_PANEL", args);
|
||||
|
||||
Reference in New Issue
Block a user