aboutsummaryrefslogtreecommitdiff
path: root/src/WixToolset.Core.WindowsInstaller/Decompile
diff options
context:
space:
mode:
authorRob Mensching <rob@firegiant.com>2020-06-25 14:43:50 -0700
committerRob Mensching <rob@firegiant.com>2020-06-25 14:50:31 -0700
commit38afa9e7bc7eacc021f8805f607368a05751e3c3 (patch)
tree803b0a8d9a06a7d6f7c4df408437017ae21a883e /src/WixToolset.Core.WindowsInstaller/Decompile
parent8968578d50858721317d410549a9f9b5c62bf1f7 (diff)
downloadwix-38afa9e7bc7eacc021f8805f607368a05751e3c3.tar.gz
wix-38afa9e7bc7eacc021f8805f607368a05751e3c3.tar.bz2
wix-38afa9e7bc7eacc021f8805f607368a05751e3c3.zip
The Great Tuple to Symbol Rename (tm)
Diffstat (limited to 'src/WixToolset.Core.WindowsInstaller/Decompile')
-rw-r--r--src/WixToolset.Core.WindowsInstaller/Decompile/Decompiler.cs218
1 files changed, 109 insertions, 109 deletions
diff --git a/src/WixToolset.Core.WindowsInstaller/Decompile/Decompiler.cs b/src/WixToolset.Core.WindowsInstaller/Decompile/Decompiler.cs
index 7c3fd6be..72985c1c 100644
--- a/src/WixToolset.Core.WindowsInstaller/Decompile/Decompiler.cs
+++ b/src/WixToolset.Core.WindowsInstaller/Decompile/Decompiler.cs
@@ -14,7 +14,7 @@ namespace WixToolset.Core.WindowsInstaller
14 using System.Xml.Linq; 14 using System.Xml.Linq;
15 using WixToolset.Core; 15 using WixToolset.Core;
16 using WixToolset.Data; 16 using WixToolset.Data;
17 using WixToolset.Data.Tuples; 17 using WixToolset.Data.Symbols;
18 using WixToolset.Data.WindowsInstaller; 18 using WixToolset.Data.WindowsInstaller;
19 using WixToolset.Data.WindowsInstaller.Rows; 19 using WixToolset.Data.WindowsInstaller.Rows;
20 using WixToolset.Extensibility; 20 using WixToolset.Extensibility;
@@ -92,7 +92,7 @@ namespace WixToolset.Core.WindowsInstaller
92 92
93 private OutputType OutputType { get; set; } 93 private OutputType OutputType { get; set; }
94 94
95 private Dictionary<string, WixActionTuple> StandardActions { get; } 95 private Dictionary<string, WixActionSymbol> StandardActions { get; }
96 96
97 /// <summary> 97 /// <summary>
98 /// Decompile the database file. 98 /// Decompile the database file.
@@ -262,23 +262,23 @@ namespace WixToolset.Core.WindowsInstaller
262 /// <summary> 262 /// <summary>
263 /// Creates an action element. 263 /// Creates an action element.
264 /// </summary> 264 /// </summary>
265 /// <param name="actionTuple">The action from which the element should be created.</param> 265 /// <param name="actionSymbol">The action from which the element should be created.</param>
266 private void CreateActionElement(WixActionTuple actionTuple) 266 private void CreateActionElement(WixActionSymbol actionSymbol)
267 { 267 {
268 Wix.ISchemaElement actionElement = null; 268 Wix.ISchemaElement actionElement = null;
269 269
270 if (null != this.core.GetIndexedElement("CustomAction", actionTuple.Action)) // custom action 270 if (null != this.core.GetIndexedElement("CustomAction", actionSymbol.Action)) // custom action
271 { 271 {
272 var custom = new Wix.Custom(); 272 var custom = new Wix.Custom();
273 273
274 custom.Action = actionTuple.Action; 274 custom.Action = actionSymbol.Action;
275 275
276 if (null != actionTuple.Condition) 276 if (null != actionSymbol.Condition)
277 { 277 {
278 custom.Content = actionTuple.Condition; 278 custom.Content = actionSymbol.Condition;
279 } 279 }
280 280
281 switch (actionTuple.Sequence) 281 switch (actionSymbol.Sequence)
282 { 282 {
283 case (-4): 283 case (-4):
284 custom.OnExit = Wix.ExitType.suspend; 284 custom.OnExit = Wix.ExitType.suspend;
@@ -293,35 +293,35 @@ namespace WixToolset.Core.WindowsInstaller
293 custom.OnExit = Wix.ExitType.success; 293 custom.OnExit = Wix.ExitType.success;
294 break; 294 break;
295 default: 295 default:
296 if (null != actionTuple.Before) 296 if (null != actionSymbol.Before)
297 { 297 {
298 custom.Before = actionTuple.Before; 298 custom.Before = actionSymbol.Before;
299 } 299 }
300 else if (null != actionTuple.After) 300 else if (null != actionSymbol.After)
301 { 301 {
302 custom.After = actionTuple.After; 302 custom.After = actionSymbol.After;
303 } 303 }
304 else if (actionTuple.Sequence.HasValue) 304 else if (actionSymbol.Sequence.HasValue)
305 { 305 {
306 custom.Sequence = actionTuple.Sequence.Value; 306 custom.Sequence = actionSymbol.Sequence.Value;
307 } 307 }
308 break; 308 break;
309 } 309 }
310 310
311 actionElement = custom; 311 actionElement = custom;
312 } 312 }
313 else if (null != this.core.GetIndexedElement("Dialog", actionTuple.Action)) // dialog 313 else if (null != this.core.GetIndexedElement("Dialog", actionSymbol.Action)) // dialog
314 { 314 {
315 var show = new Wix.Show(); 315 var show = new Wix.Show();
316 316
317 show.Dialog = actionTuple.Action; 317 show.Dialog = actionSymbol.Action;
318 318
319 if (null != actionTuple.Condition) 319 if (null != actionSymbol.Condition)
320 { 320 {
321 show.Content = actionTuple.Condition; 321 show.Content = actionSymbol.Condition;
322 } 322 }
323 323
324 switch (actionTuple.Sequence) 324 switch (actionSymbol.Sequence)
325 { 325 {
326 case (-4): 326 case (-4):
327 show.OnExit = Wix.ExitType.suspend; 327 show.OnExit = Wix.ExitType.suspend;
@@ -336,17 +336,17 @@ namespace WixToolset.Core.WindowsInstaller
336 show.OnExit = Wix.ExitType.success; 336 show.OnExit = Wix.ExitType.success;
337 break; 337 break;
338 default: 338 default:
339 if (null != actionTuple.Before) 339 if (null != actionSymbol.Before)
340 { 340 {
341 show.Before = actionTuple.Before; 341 show.Before = actionSymbol.Before;
342 } 342 }
343 else if (null != actionTuple.After) 343 else if (null != actionSymbol.After)
344 { 344 {
345 show.After = actionTuple.After; 345 show.After = actionSymbol.After;
346 } 346 }
347 else if (actionTuple.Sequence.HasValue) 347 else if (actionSymbol.Sequence.HasValue)
348 { 348 {
349 show.Sequence = actionTuple.Sequence.Value; 349 show.Sequence = actionSymbol.Sequence.Value;
350 } 350 }
351 break; 351 break;
352 } 352 }
@@ -355,18 +355,18 @@ namespace WixToolset.Core.WindowsInstaller
355 } 355 }
356 else // possibly a standard action without suggested sequence information 356 else // possibly a standard action without suggested sequence information
357 { 357 {
358 actionElement = this.CreateStandardActionElement(actionTuple); 358 actionElement = this.CreateStandardActionElement(actionSymbol);
359 } 359 }
360 360
361 // add the action element to the appropriate sequence element 361 // add the action element to the appropriate sequence element
362 if (null != actionElement) 362 if (null != actionElement)
363 { 363 {
364 var sequenceTable = actionTuple.SequenceTable.ToString(); 364 var sequenceTable = actionSymbol.SequenceTable.ToString();
365 var sequenceElement = (Wix.IParentElement)this.sequenceElements[sequenceTable]; 365 var sequenceElement = (Wix.IParentElement)this.sequenceElements[sequenceTable];
366 366
367 if (null == sequenceElement) 367 if (null == sequenceElement)
368 { 368 {
369 switch (actionTuple.SequenceTable) 369 switch (actionSymbol.SequenceTable)
370 { 370 {
371 case SequenceTable.AdminExecuteSequence: 371 case SequenceTable.AdminExecuteSequence:
372 sequenceElement = new Wix.AdminExecuteSequence(); 372 sequenceElement = new Wix.AdminExecuteSequence();
@@ -397,7 +397,7 @@ namespace WixToolset.Core.WindowsInstaller
397 } 397 }
398 catch (System.ArgumentException) // action/dialog is not valid for this sequence 398 catch (System.ArgumentException) // action/dialog is not valid for this sequence
399 { 399 {
400 this.Messaging.Write(WarningMessages.IllegalActionInSequence(actionTuple.SourceLineNumbers, actionTuple.SequenceTable.ToString(), actionTuple.Action)); 400 this.Messaging.Write(WarningMessages.IllegalActionInSequence(actionSymbol.SourceLineNumbers, actionSymbol.SequenceTable.ToString(), actionSymbol.Action));
401 } 401 }
402 } 402 }
403 } 403 }
@@ -405,40 +405,40 @@ namespace WixToolset.Core.WindowsInstaller
405 /// <summary> 405 /// <summary>
406 /// Creates a standard action element. 406 /// Creates a standard action element.
407 /// </summary> 407 /// </summary>
408 /// <param name="actionTuple">The action row from which the element should be created.</param> 408 /// <param name="actionSymbol">The action row from which the element should be created.</param>
409 /// <returns>The created element.</returns> 409 /// <returns>The created element.</returns>
410 private Wix.ISchemaElement CreateStandardActionElement(WixActionTuple actionTuple) 410 private Wix.ISchemaElement CreateStandardActionElement(WixActionSymbol actionSymbol)
411 { 411 {
412 Wix.ActionSequenceType actionElement = null; 412 Wix.ActionSequenceType actionElement = null;
413 413
414 switch (actionTuple.Action) 414 switch (actionSymbol.Action)
415 { 415 {
416 case "AllocateRegistrySpace": 416 case "AllocateRegistrySpace":
417 actionElement = new Wix.AllocateRegistrySpace(); 417 actionElement = new Wix.AllocateRegistrySpace();
418 break; 418 break;
419 case "AppSearch": 419 case "AppSearch":
420 this.StandardActions.TryGetValue(actionTuple.Id.Id, out var appSearchActionRow); 420 this.StandardActions.TryGetValue(actionSymbol.Id.Id, out var appSearchActionRow);
421 421
422 if (null != actionTuple.Before || null != actionTuple.After || (null != appSearchActionRow && actionTuple.Sequence != appSearchActionRow.Sequence)) 422 if (null != actionSymbol.Before || null != actionSymbol.After || (null != appSearchActionRow && actionSymbol.Sequence != appSearchActionRow.Sequence))
423 { 423 {
424 var appSearch = new Wix.AppSearch(); 424 var appSearch = new Wix.AppSearch();
425 425
426 if (null != actionTuple.Condition) 426 if (null != actionSymbol.Condition)
427 { 427 {
428 appSearch.Content = actionTuple.Condition; 428 appSearch.Content = actionSymbol.Condition;
429 } 429 }
430 430
431 if (null != actionTuple.Before) 431 if (null != actionSymbol.Before)
432 { 432 {
433 appSearch.Before = actionTuple.Before; 433 appSearch.Before = actionSymbol.Before;
434 } 434 }
435 else if (null != actionTuple.After) 435 else if (null != actionSymbol.After)
436 { 436 {
437 appSearch.After = actionTuple.After; 437 appSearch.After = actionSymbol.After;
438 } 438 }
439 else if (actionTuple.Sequence.HasValue) 439 else if (actionSymbol.Sequence.HasValue)
440 { 440 {
441 appSearch.Sequence = actionTuple.Sequence.Value; 441 appSearch.Sequence = actionSymbol.Sequence.Value;
442 } 442 }
443 443
444 return appSearch; 444 return appSearch;
@@ -449,7 +449,7 @@ namespace WixToolset.Core.WindowsInstaller
449 break; 449 break;
450 case "CCPSearch": 450 case "CCPSearch":
451 var ccpSearch = new Wix.CCPSearch(); 451 var ccpSearch = new Wix.CCPSearch();
452 Decompiler.SequenceRelativeAction(actionTuple, ccpSearch); 452 Decompiler.SequenceRelativeAction(actionSymbol, ccpSearch);
453 return ccpSearch; 453 return ccpSearch;
454 case "CostFinalize": 454 case "CostFinalize":
455 actionElement = new Wix.CostFinalize(); 455 actionElement = new Wix.CostFinalize();
@@ -468,7 +468,7 @@ namespace WixToolset.Core.WindowsInstaller
468 break; 468 break;
469 case "DisableRollback": 469 case "DisableRollback":
470 var disableRollback = new Wix.DisableRollback(); 470 var disableRollback = new Wix.DisableRollback();
471 Decompiler.SequenceRelativeAction(actionTuple, disableRollback); 471 Decompiler.SequenceRelativeAction(actionSymbol, disableRollback);
472 return disableRollback; 472 return disableRollback;
473 case "DuplicateFiles": 473 case "DuplicateFiles":
474 actionElement = new Wix.DuplicateFiles(); 474 actionElement = new Wix.DuplicateFiles();
@@ -481,22 +481,22 @@ namespace WixToolset.Core.WindowsInstaller
481 break; 481 break;
482 case "FindRelatedProducts": 482 case "FindRelatedProducts":
483 var findRelatedProducts = new Wix.FindRelatedProducts(); 483 var findRelatedProducts = new Wix.FindRelatedProducts();
484 Decompiler.SequenceRelativeAction(actionTuple, findRelatedProducts); 484 Decompiler.SequenceRelativeAction(actionSymbol, findRelatedProducts);
485 return findRelatedProducts; 485 return findRelatedProducts;
486 case "ForceReboot": 486 case "ForceReboot":
487 var forceReboot = new Wix.ForceReboot(); 487 var forceReboot = new Wix.ForceReboot();
488 Decompiler.SequenceRelativeAction(actionTuple, forceReboot); 488 Decompiler.SequenceRelativeAction(actionSymbol, forceReboot);
489 return forceReboot; 489 return forceReboot;
490 case "InstallAdminPackage": 490 case "InstallAdminPackage":
491 actionElement = new Wix.InstallAdminPackage(); 491 actionElement = new Wix.InstallAdminPackage();
492 break; 492 break;
493 case "InstallExecute": 493 case "InstallExecute":
494 var installExecute = new Wix.InstallExecute(); 494 var installExecute = new Wix.InstallExecute();
495 Decompiler.SequenceRelativeAction(actionTuple, installExecute); 495 Decompiler.SequenceRelativeAction(actionSymbol, installExecute);
496 return installExecute; 496 return installExecute;
497 case "InstallExecuteAgain": 497 case "InstallExecuteAgain":
498 var installExecuteAgain = new Wix.InstallExecuteAgain(); 498 var installExecuteAgain = new Wix.InstallExecuteAgain();
499 Decompiler.SequenceRelativeAction(actionTuple, installExecuteAgain); 499 Decompiler.SequenceRelativeAction(actionSymbol, installExecuteAgain);
500 return installExecuteAgain; 500 return installExecuteAgain;
501 case "InstallFiles": 501 case "InstallFiles":
502 actionElement = new Wix.InstallFiles(); 502 actionElement = new Wix.InstallFiles();
@@ -521,7 +521,7 @@ namespace WixToolset.Core.WindowsInstaller
521 break; 521 break;
522 case "LaunchConditions": 522 case "LaunchConditions":
523 var launchConditions = new Wix.LaunchConditions(); 523 var launchConditions = new Wix.LaunchConditions();
524 Decompiler.SequenceRelativeAction(actionTuple, launchConditions); 524 Decompiler.SequenceRelativeAction(actionSymbol, launchConditions);
525 return launchConditions; 525 return launchConditions;
526 case "MigrateFeatureStates": 526 case "MigrateFeatureStates":
527 actionElement = new Wix.MigrateFeatureStates(); 527 actionElement = new Wix.MigrateFeatureStates();
@@ -585,7 +585,7 @@ namespace WixToolset.Core.WindowsInstaller
585 break; 585 break;
586 case "RemoveExistingProducts": 586 case "RemoveExistingProducts":
587 var removeExistingProducts = new Wix.RemoveExistingProducts(); 587 var removeExistingProducts = new Wix.RemoveExistingProducts();
588 Decompiler.SequenceRelativeAction(actionTuple, removeExistingProducts); 588 Decompiler.SequenceRelativeAction(actionSymbol, removeExistingProducts);
589 return removeExistingProducts; 589 return removeExistingProducts;
590 case "RemoveFiles": 590 case "RemoveFiles":
591 actionElement = new Wix.RemoveFiles(); 591 actionElement = new Wix.RemoveFiles();
@@ -607,15 +607,15 @@ namespace WixToolset.Core.WindowsInstaller
607 break; 607 break;
608 case "ResolveSource": 608 case "ResolveSource":
609 var resolveSource = new Wix.ResolveSource(); 609 var resolveSource = new Wix.ResolveSource();
610 Decompiler.SequenceRelativeAction(actionTuple, resolveSource); 610 Decompiler.SequenceRelativeAction(actionSymbol, resolveSource);
611 return resolveSource; 611 return resolveSource;
612 case "RMCCPSearch": 612 case "RMCCPSearch":
613 var rmccpSearch = new Wix.RMCCPSearch(); 613 var rmccpSearch = new Wix.RMCCPSearch();
614 Decompiler.SequenceRelativeAction(actionTuple, rmccpSearch); 614 Decompiler.SequenceRelativeAction(actionSymbol, rmccpSearch);
615 return rmccpSearch; 615 return rmccpSearch;
616 case "ScheduleReboot": 616 case "ScheduleReboot":
617 var scheduleReboot = new Wix.ScheduleReboot(); 617 var scheduleReboot = new Wix.ScheduleReboot();
618 Decompiler.SequenceRelativeAction(actionTuple, scheduleReboot); 618 Decompiler.SequenceRelativeAction(actionSymbol, scheduleReboot);
619 return scheduleReboot; 619 return scheduleReboot;
620 case "SelfRegModules": 620 case "SelfRegModules":
621 actionElement = new Wix.SelfRegModules(); 621 actionElement = new Wix.SelfRegModules();
@@ -672,13 +672,13 @@ namespace WixToolset.Core.WindowsInstaller
672 actionElement = new Wix.WriteRegistryValues(); 672 actionElement = new Wix.WriteRegistryValues();
673 break; 673 break;
674 default: 674 default:
675 this.Messaging.Write(WarningMessages.UnknownAction(actionTuple.SourceLineNumbers, actionTuple.SequenceTable.ToString(), actionTuple.Action)); 675 this.Messaging.Write(WarningMessages.UnknownAction(actionSymbol.SourceLineNumbers, actionSymbol.SequenceTable.ToString(), actionSymbol.Action));
676 return null; 676 return null;
677 } 677 }
678 678
679 if (actionElement != null) 679 if (actionElement != null)
680 { 680 {
681 this.SequenceStandardAction(actionTuple, actionElement); 681 this.SequenceStandardAction(actionSymbol, actionElement);
682 } 682 }
683 683
684 return actionElement; 684 return actionElement;
@@ -687,48 +687,48 @@ namespace WixToolset.Core.WindowsInstaller
687 /// <summary> 687 /// <summary>
688 /// Applies the condition and sequence to a standard action element based on the action row data. 688 /// Applies the condition and sequence to a standard action element based on the action row data.
689 /// </summary> 689 /// </summary>
690 /// <param name="actionTuple">Action data from the database.</param> 690 /// <param name="actionSymbol">Action data from the database.</param>
691 /// <param name="actionElement">Element to be sequenced.</param> 691 /// <param name="actionElement">Element to be sequenced.</param>
692 private void SequenceStandardAction(WixActionTuple actionTuple, Wix.ActionSequenceType actionElement) 692 private void SequenceStandardAction(WixActionSymbol actionSymbol, Wix.ActionSequenceType actionElement)
693 { 693 {
694 if (null != actionTuple.Condition) 694 if (null != actionSymbol.Condition)
695 { 695 {
696 actionElement.Content = actionTuple.Condition; 696 actionElement.Content = actionSymbol.Condition;
697 } 697 }
698 698
699 if ((null != actionTuple.Before || null != actionTuple.After) && 0 == actionTuple.Sequence) 699 if ((null != actionSymbol.Before || null != actionSymbol.After) && 0 == actionSymbol.Sequence)
700 { 700 {
701 this.Messaging.Write(WarningMessages.DecompiledStandardActionRelativelyScheduledInModule(actionTuple.SourceLineNumbers, actionTuple.SequenceTable.ToString(), actionTuple.Action)); 701 this.Messaging.Write(WarningMessages.DecompiledStandardActionRelativelyScheduledInModule(actionSymbol.SourceLineNumbers, actionSymbol.SequenceTable.ToString(), actionSymbol.Action));
702 } 702 }
703 else if (actionTuple.Sequence.HasValue) 703 else if (actionSymbol.Sequence.HasValue)
704 { 704 {
705 actionElement.Sequence = actionTuple.Sequence.Value; 705 actionElement.Sequence = actionSymbol.Sequence.Value;
706 } 706 }
707 } 707 }
708 708
709 /// <summary> 709 /// <summary>
710 /// Applies the condition and relative sequence to an action element based on the action row data. 710 /// Applies the condition and relative sequence to an action element based on the action row data.
711 /// </summary> 711 /// </summary>
712 /// <param name="actionTuple">Action data from the database.</param> 712 /// <param name="actionSymbol">Action data from the database.</param>
713 /// <param name="actionElement">Element to be sequenced.</param> 713 /// <param name="actionElement">Element to be sequenced.</param>
714 private static void SequenceRelativeAction(WixActionTuple actionTuple, Wix.ActionModuleSequenceType actionElement) 714 private static void SequenceRelativeAction(WixActionSymbol actionSymbol, Wix.ActionModuleSequenceType actionElement)
715 { 715 {
716 if (null != actionTuple.Condition) 716 if (null != actionSymbol.Condition)
717 { 717 {
718 actionElement.Content = actionTuple.Condition; 718 actionElement.Content = actionSymbol.Condition;
719 } 719 }
720 720
721 if (null != actionTuple.Before) 721 if (null != actionSymbol.Before)
722 { 722 {
723 actionElement.Before = actionTuple.Before; 723 actionElement.Before = actionSymbol.Before;
724 } 724 }
725 else if (null != actionTuple.After) 725 else if (null != actionSymbol.After)
726 { 726 {
727 actionElement.After = actionTuple.After; 727 actionElement.After = actionSymbol.After;
728 } 728 }
729 else if (actionTuple.Sequence.HasValue) 729 else if (actionSymbol.Sequence.HasValue)
730 { 730 {
731 actionElement.Sequence = actionTuple.Sequence.Value; 731 actionElement.Sequence = actionSymbol.Sequence.Value;
732 } 732 }
733 } 733 }
734 734
@@ -2507,53 +2507,53 @@ namespace WixToolset.Core.WindowsInstaller
2507 2507
2508 if (null != table) 2508 if (null != table)
2509 { 2509 {
2510 var actionTuples = new List<WixActionTuple>(); 2510 var actionSymbols = new List<WixActionSymbol>();
2511 var needAbsoluteScheduling = this.SuppressRelativeActionSequencing; 2511 var needAbsoluteScheduling = this.SuppressRelativeActionSequencing;
2512 var nonSequencedActionRows = new Dictionary<string, WixActionTuple>(); 2512 var nonSequencedActionRows = new Dictionary<string, WixActionSymbol>();
2513 var suppressedRelativeActionRows = new Dictionary<string, WixActionTuple>(); 2513 var suppressedRelativeActionRows = new Dictionary<string, WixActionSymbol>();
2514 2514
2515 // create a sorted array of actions in this table 2515 // create a sorted array of actions in this table
2516 foreach (var row in table.Rows) 2516 foreach (var row in table.Rows)
2517 { 2517 {
2518 var action = row.FieldAsString(0); 2518 var action = row.FieldAsString(0);
2519 var actionTuple = new WixActionTuple(null, new Identifier(AccessModifier.Public, sequenceTable, action)); 2519 var actionSymbol = new WixActionSymbol(null, new Identifier(AccessModifier.Public, sequenceTable, action));
2520 2520
2521 actionTuple.Action = action; 2521 actionSymbol.Action = action;
2522 2522
2523 if (null != row[1]) 2523 if (null != row[1])
2524 { 2524 {
2525 actionTuple.Condition = Convert.ToString(row[1]); 2525 actionSymbol.Condition = Convert.ToString(row[1]);
2526 } 2526 }
2527 2527
2528 actionTuple.Sequence = Convert.ToInt32(row[2]); 2528 actionSymbol.Sequence = Convert.ToInt32(row[2]);
2529 2529
2530 actionTuple.SequenceTable = sequenceTable; 2530 actionSymbol.SequenceTable = sequenceTable;
2531 2531
2532 actionTuples.Add(actionTuple); 2532 actionSymbols.Add(actionSymbol);
2533 } 2533 }
2534 actionTuples = actionTuples.OrderBy(t => t.Sequence).ToList(); 2534 actionSymbols = actionSymbols.OrderBy(t => t.Sequence).ToList();
2535 2535
2536 for (var i = 0; i < actionTuples.Count && !needAbsoluteScheduling; i++) 2536 for (var i = 0; i < actionSymbols.Count && !needAbsoluteScheduling; i++)
2537 { 2537 {
2538 var actionTuple = actionTuples[i]; 2538 var actionSymbol = actionSymbols[i];
2539 this.StandardActions.TryGetValue(actionTuple.Id.Id, out var standardActionRow); 2539 this.StandardActions.TryGetValue(actionSymbol.Id.Id, out var standardActionRow);
2540 2540
2541 // create actions for custom actions, dialogs, AppSearch when its moved, and standard actions with non-standard conditions 2541 // create actions for custom actions, dialogs, AppSearch when its moved, and standard actions with non-standard conditions
2542 if ("AppSearch" == actionTuple.Action || null == standardActionRow || actionTuple.Condition != standardActionRow.Condition) 2542 if ("AppSearch" == actionSymbol.Action || null == standardActionRow || actionSymbol.Condition != standardActionRow.Condition)
2543 { 2543 {
2544 WixActionTuple previousActionTuple = null; 2544 WixActionSymbol previousActionSymbol = null;
2545 WixActionTuple nextActionTuple = null; 2545 WixActionSymbol nextActionSymbol = null;
2546 2546
2547 // find the previous action row if there is one 2547 // find the previous action row if there is one
2548 if (0 <= i - 1) 2548 if (0 <= i - 1)
2549 { 2549 {
2550 previousActionTuple = actionTuples[i - 1]; 2550 previousActionSymbol = actionSymbols[i - 1];
2551 } 2551 }
2552 2552
2553 // find the next action row if there is one 2553 // find the next action row if there is one
2554 if (actionTuples.Count > i + 1) 2554 if (actionSymbols.Count > i + 1)
2555 { 2555 {
2556 nextActionTuple = actionTuples[i + 1]; 2556 nextActionSymbol = actionSymbols[i + 1];
2557 } 2557 }
2558 2558
2559 // the logic for setting the before or after attribute for an action: 2559 // the logic for setting the before or after attribute for an action:
@@ -2565,47 +2565,47 @@ namespace WixToolset.Core.WindowsInstaller
2565 // 6. If this action is AppSearch and has all standard information, ignore it. 2565 // 6. If this action is AppSearch and has all standard information, ignore it.
2566 // 7. If this action is standard and has a non-standard condition, create the action without any scheduling information. 2566 // 7. If this action is standard and has a non-standard condition, create the action without any scheduling information.
2567 // 8. Everything must be absolutely sequenced. 2567 // 8. Everything must be absolutely sequenced.
2568 if ((null != previousActionTuple && actionTuple.Sequence == previousActionTuple.Sequence) || (null != nextActionTuple && actionTuple.Sequence == nextActionTuple.Sequence)) 2568 if ((null != previousActionSymbol && actionSymbol.Sequence == previousActionSymbol.Sequence) || (null != nextActionSymbol && actionSymbol.Sequence == nextActionSymbol.Sequence))
2569 { 2569 {
2570 needAbsoluteScheduling = true; 2570 needAbsoluteScheduling = true;
2571 } 2571 }
2572 else if (null != nextActionTuple && this.StandardActions.ContainsKey(nextActionTuple.Id.Id) && actionTuple.Sequence + 1 == nextActionTuple.Sequence) 2572 else if (null != nextActionSymbol && this.StandardActions.ContainsKey(nextActionSymbol.Id.Id) && actionSymbol.Sequence + 1 == nextActionSymbol.Sequence)
2573 { 2573 {
2574 actionTuple.Before = nextActionTuple.Action; 2574 actionSymbol.Before = nextActionSymbol.Action;
2575 } 2575 }
2576 else if (null != previousActionTuple && this.StandardActions.ContainsKey(previousActionTuple.Id.Id) && actionTuple.Sequence - 1 == previousActionTuple.Sequence) 2576 else if (null != previousActionSymbol && this.StandardActions.ContainsKey(previousActionSymbol.Id.Id) && actionSymbol.Sequence - 1 == previousActionSymbol.Sequence)
2577 { 2577 {
2578 actionTuple.After = previousActionTuple.Action; 2578 actionSymbol.After = previousActionSymbol.Action;
2579 } 2579 }
2580 else if (null == standardActionRow && null != previousActionTuple && actionTuple.Sequence - 1 == previousActionTuple.Sequence && previousActionTuple.Before != actionTuple.Action) 2580 else if (null == standardActionRow && null != previousActionSymbol && actionSymbol.Sequence - 1 == previousActionSymbol.Sequence && previousActionSymbol.Before != actionSymbol.Action)
2581 { 2581 {
2582 actionTuple.After = previousActionTuple.Action; 2582 actionSymbol.After = previousActionSymbol.Action;
2583 } 2583 }
2584 else if (null == standardActionRow && null != previousActionTuple && actionTuple.Sequence != previousActionTuple.Sequence && null != nextActionTuple && actionTuple.Sequence + 1 == nextActionTuple.Sequence) 2584 else if (null == standardActionRow && null != previousActionSymbol && actionSymbol.Sequence != previousActionSymbol.Sequence && null != nextActionSymbol && actionSymbol.Sequence + 1 == nextActionSymbol.Sequence)
2585 { 2585 {
2586 actionTuple.Before = nextActionTuple.Action; 2586 actionSymbol.Before = nextActionSymbol.Action;
2587 } 2587 }
2588 else if ("AppSearch" == actionTuple.Action && null != standardActionRow && actionTuple.Sequence == standardActionRow.Sequence && actionTuple.Condition == standardActionRow.Condition) 2588 else if ("AppSearch" == actionSymbol.Action && null != standardActionRow && actionSymbol.Sequence == standardActionRow.Sequence && actionSymbol.Condition == standardActionRow.Condition)
2589 { 2589 {
2590 // ignore an AppSearch row which has the WiX standard sequence and a standard condition 2590 // ignore an AppSearch row which has the WiX standard sequence and a standard condition
2591 } 2591 }
2592 else if (null != standardActionRow && actionTuple.Condition != standardActionRow.Condition) // standard actions get their standard sequence numbers 2592 else if (null != standardActionRow && actionSymbol.Condition != standardActionRow.Condition) // standard actions get their standard sequence numbers
2593 { 2593 {
2594 nonSequencedActionRows.Add(actionTuple.Id.Id, actionTuple); 2594 nonSequencedActionRows.Add(actionSymbol.Id.Id, actionSymbol);
2595 } 2595 }
2596 else if (0 < actionTuple.Sequence) 2596 else if (0 < actionSymbol.Sequence)
2597 { 2597 {
2598 needAbsoluteScheduling = true; 2598 needAbsoluteScheduling = true;
2599 } 2599 }
2600 } 2600 }
2601 else 2601 else
2602 { 2602 {
2603 suppressedRelativeActionRows.Add(actionTuple.Id.Id, actionTuple); 2603 suppressedRelativeActionRows.Add(actionSymbol.Id.Id, actionSymbol);
2604 } 2604 }
2605 } 2605 }
2606 2606
2607 // create the actions now that we know if they must be absolutely or relatively scheduled 2607 // create the actions now that we know if they must be absolutely or relatively scheduled
2608 foreach (var actionRow in actionTuples) 2608 foreach (var actionRow in actionSymbols)
2609 { 2609 {
2610 var key = actionRow.Id.Id; 2610 var key = actionRow.Id.Id;
2611 2611
@@ -2650,7 +2650,7 @@ namespace WixToolset.Core.WindowsInstaller
2650 { 2650 {
2651 foreach (var row in table.Rows) 2651 foreach (var row in table.Rows)
2652 { 2652 {
2653 var actionRow = new WixActionTuple(null, new Identifier(AccessModifier.Public, sequenceTable, row.FieldAsString(0))); 2653 var actionRow = new WixActionSymbol(null, new Identifier(AccessModifier.Public, sequenceTable, row.FieldAsString(0)));
2654 2654
2655 actionRow.Action = row.FieldAsString(0); 2655 actionRow.Action = row.FieldAsString(0);
2656 2656