BUTR/Bannerlord.UIExtenderEx

View on GitHub
docs/articles/runtime/Registration.svg

Summary

Maintainability
Test Coverage
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="1275" height="814" contentStyleType="text/css" preserveAspectRatio="none" style="width:1275px;height:814px;background:#fff" version="1.1" viewBox="0 0 1275 814" zoomAndPan="magnify"><g><rect width="741.5" height="307.668" x="527.5" fill="none" style="stroke:#000;stroke-width:1.5" y="283.076"/><rect width="721.5" height="274.377" x="537.5" fill="none" style="stroke:#000;stroke-width:1.5" y="309.367"/><line style="stroke:#181818;stroke-width:.5;stroke-dasharray:5,5" x1="27" x2="27" y1="83.621" y2="731.326"/><line style="stroke:#181818;stroke-width:.5;stroke-dasharray:5,5" x1="288.5" x2="288.5" y1="83.621" y2="731.326"/><line style="stroke:#181818;stroke-width:.5;stroke-dasharray:5,5" x1="382.5" x2="382.5" y1="83.621" y2="731.326"/><line style="stroke:#181818;stroke-width:.5;stroke-dasharray:5,5" x1="614.5" x2="614.5" y1="83.621" y2="731.326"/><line style="stroke:#181818;stroke-width:.5;stroke-dasharray:5,5" x1="821" x2="821" y1="83.621" y2="731.326"/><line style="stroke:#181818;stroke-width:.5;stroke-dasharray:5,5" x1="971" x2="971" y1="83.621" y2="731.326"/><line style="stroke:#181818;stroke-width:.5;stroke-dasharray:5,5" x1="1129" x2="1129" y1="83.621" y2="731.326"/><text x="5" y="80.107" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="38">Game</text><ellipse cx="27" cy="13.5" fill="#E2E2F0" rx="8" ry="8" style="stroke:#181818;stroke-width:.5"/><path fill="none" d="M27,21.5 L27,48.5 M14,29.5 L40,29.5 M27,48.5 L14,63.5 M27,48.5 L40,63.5" style="stroke:#181818;stroke-width:.5"/><text x="5" y="745.434" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="38">Game</text><ellipse cx="27" cy="757.447" fill="#E2E2F0" rx="8" ry="8" style="stroke:#181818;stroke-width:.5"/><path fill="none" d="M27,765.4473 L27,792.4473 M14,773.4473 L40,773.4473 M27,792.4473 L14,807.4473 M27,792.4473 L40,807.4473" style="stroke:#181818;stroke-width:.5"/><rect width="85" height="32.621" x="246.5" y="50" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="253.5" y="72.107" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="71">SubModule</text><rect width="85" height="32.621" x="246.5" y="730.326" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="253.5" y="752.434" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="71">SubModule</text><rect width="82" height="32.621" x="341.5" y="50" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="348.5" y="72.107" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="68">UIExtender</text><rect width="82" height="32.621" x="341.5" y="730.326" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="348.5" y="752.434" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="68">UIExtender</text><rect width="134" height="32.621" x="547.5" y="50" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="554.5" y="72.107" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="120">UIExtenderRuntime</text><rect width="134" height="32.621" x="547.5" y="730.326" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="554.5" y="752.434" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="120">UIExtenderRuntime</text><rect width="129" height="32.621" x="757" y="50" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="764" y="72.107" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="115">PrefabComponent</text><rect width="129" height="32.621" x="757" y="730.326" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="764" y="752.434" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="115">PrefabComponent</text><rect width="141" height="32.621" x="901" y="50" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="908" y="72.107" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="127">GauntletMoviePatch</text><rect width="141" height="32.621" x="901" y="730.326" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="908" y="752.434" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="127">GauntletMoviePatch</text><rect width="154" height="32.621" x="1052" y="50" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="1059" y="72.107" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="140">ViewModelComponent</text><rect width="154" height="32.621" x="1052" y="730.326" fill="#E2E2F0" rx="2.5" ry="2.5" style="stroke:#181818;stroke-width:.5"/><text x="1059" y="752.434" fill="#000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="140">ViewModelComponent</text><polygon fill="#181818" points="277 112.912 287 116.912 277 120.912 281 116.912" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1" x1="27" x2="283" y1="116.912" y2="116.912"/><text x="34" y="111.649" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="238">OnBeforeInitialModuleScreenSetAsRoot()</text><polygon fill="#181818" points="370.5 144.203 380.5 148.203 370.5 152.203 374.5 148.203" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1" x1="289" x2="376.5" y1="148.203" y2="148.203"/><text x="296" y="142.94" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="56">Register()</text><line style="stroke:#181818;stroke-width:1" x1="382.5" x2="424.5" y1="179.494" y2="179.494"/><line style="stroke:#181818;stroke-width:1" x1="424.5" x2="424.5" y1="179.494" y2="192.494"/><line style="stroke:#181818;stroke-width:1" x1="383.5" x2="424.5" y1="192.494" y2="192.494"/><polygon fill="#181818" points="393.5 188.494 383.5 192.494 393.5 196.494 389.5 192.494" style="stroke:#181818;stroke-width:1"/><text x="389.5" y="174.231" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="119">Find attributed types</text><line style="stroke:#181818;stroke-width:1" x1="382.5" x2="424.5" y1="223.785" y2="223.785"/><line style="stroke:#181818;stroke-width:1" x1="424.5" x2="424.5" y1="223.785" y2="236.785"/><line style="stroke:#181818;stroke-width:1" x1="383.5" x2="424.5" y1="236.785" y2="236.785"/><polygon fill="#181818" points="393.5 232.785 383.5 236.785 393.5 240.785 389.5 236.785" style="stroke:#181818;stroke-width:1"/><text x="389.5" y="218.523" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="218">Create runtime for module and store it</text><polygon fill="#181818" points="602.5 264.076 612.5 268.076 602.5 272.076 606.5 268.076" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1" x1="382.5" x2="608.5" y1="268.076" y2="268.076"/><text x="389.5" y="262.813" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="56">Register()</text><path fill="#EEE" d="M527.5,283.0762 L600.5,283.0762 L600.5,292.3672 L590.5,302.3672 L527.5,302.3672 L527.5,283.0762" style="stroke:#000;stroke-width:1.5"/><rect width="741.5" height="307.668" x="527.5" fill="none" style="stroke:#000;stroke-width:1.5" y="283.076"/><text x="542.5" y="298.104" fill="#000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="28">loop</text><text x="615.5" y="296.946" fill="#000" font-family="sans-serif" font-size="11" font-weight="bold" lengthAdjust="spacing" textLength="80">[for each type]</text><path fill="#EEE" d="M537.5,309.3672 L598.5,309.3672 L598.5,318.6582 L588.5,328.6582 L537.5,328.6582 L537.5,309.3672" style="stroke:#000;stroke-width:1.5"/><rect width="721.5" height="274.377" x="537.5" fill="none" style="stroke:#000;stroke-width:1.5" y="309.367"/><text x="552.5" y="324.396" fill="#000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="16">alt</text><text x="613.5" y="323.237" fill="#000" font-family="sans-serif" font-size="11" font-weight="bold" lengthAdjust="spacing" textLength="102">[prefab extension]</text><polygon fill="#181818" points="809.5 347.949 819.5 351.949 809.5 355.949 813.5 351.949" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1" x1="614.5" x2="815.5" y1="351.949" y2="351.949"/><text x="621.5" y="346.687" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="90">RegisterPatch()</text><polygon fill="#181818" points="625.5 361.949 615.5 365.949 625.5 369.949 621.5 365.949" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1;stroke-dasharray:2,2" x1="619.5" x2="820.5" y1="365.949" y2="365.949"/><line style="stroke:#181818;stroke-width:1" x1="821.5" x2="863.5" y1="397.24" y2="397.24"/><line style="stroke:#181818;stroke-width:1" x1="863.5" x2="863.5" y1="397.24" y2="410.24"/><line style="stroke:#181818;stroke-width:1" x1="822.5" x2="863.5" y1="410.24" y2="410.24"/><polygon fill="#181818" points="832.5 406.24 822.5 410.24 832.5 414.24 828.5 410.24" style="stroke:#181818;stroke-width:1"/><text x="828.5" y="391.978" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="136">store extension for later</text><polygon fill="#181818" points="625.5 420.24 615.5 424.24 625.5 428.24 621.5 424.24" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1;stroke-dasharray:2,2" x1="619.5" x2="820.5" y1="424.24" y2="424.24"/><polygon fill="#181818" points="959.5 451.531 969.5 455.531 959.5 459.531 963.5 455.531" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1" x1="614.5" x2="965.5" y1="455.531" y2="455.531"/><text x="621.5" y="450.269" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="141">Register(AutoGenName)</text><polygon fill="#181818" points="625.5 465.531 615.5 469.531 625.5 473.531 621.5 469.531" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1;stroke-dasharray:2,2" x1="619.5" x2="970.5" y1="469.531" y2="469.531"/><line style="stroke:#000;stroke-width:1;stroke-dasharray:2,2" x1="537.5" x2="1259" y1="478.531" y2="478.531"/><text x="542.5" y="490.401" fill="#000" font-family="sans-serif" font-size="11" font-weight="bold" lengthAdjust="spacing" textLength="140">[if view model extension]</text><polygon fill="#181818" points="1117 513.453 1127 517.453 1117 521.453 1121 517.453" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1" x1="614.5" x2="1123" y1="517.453" y2="517.453"/><text x="621.5" y="512.19" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="150">RegisterViewModelMixin()</text><line style="stroke:#181818;stroke-width:1" x1="1129" x2="1171" y1="548.744" y2="548.744"/><line style="stroke:#181818;stroke-width:1" x1="1171" x2="1171" y1="548.744" y2="561.744"/><line style="stroke:#181818;stroke-width:1" x1="1130" x2="1171" y1="561.744" y2="561.744"/><polygon fill="#181818" points="1140 557.744 1130 561.744 1140 565.744 1136 561.744" style="stroke:#181818;stroke-width:1"/><text x="1136" y="543.481" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="111">store mixin for later</text><polygon fill="#181818" points="625.5 571.744 615.5 575.744 625.5 579.744 621.5 575.744" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1;stroke-dasharray:2,2" x1="619.5" x2="1128" y1="575.744" y2="575.744"/><line style="stroke:#181818;stroke-width:1" x1="614.5" x2="656.5" y1="621.035" y2="621.035"/><line style="stroke:#181818;stroke-width:1" x1="656.5" x2="656.5" y1="621.035" y2="634.035"/><line style="stroke:#181818;stroke-width:1" x1="615.5" x2="656.5" y1="634.035" y2="634.035"/><polygon fill="#181818" points="625.5 630.035 615.5 634.035 625.5 638.035 621.5 634.035" style="stroke:#181818;stroke-width:1"/><text x="621.5" y="615.773" fill="#000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="56">Patching</text><text x="681.5" y="615.773" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="133">(see separate diagram)</text><path fill="#FEFFDD" d="M436,647.0352 L436,674.0352 L792,674.0352 L792,657.0352 L782,647.0352 L436,647.0352" style="stroke:#181818;stroke-width:.5"/><path fill="#FEFFDD" d="M782,647.0352 L782,657.0352 L792,657.0352 L782,647.0352" style="stroke:#181818;stroke-width:.5"/><text x="442" y="666.063" fill="#000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" textLength="335">See `ViewModelPatching` and `PrefabPatching` diagrams.</text><polygon fill="#181818" points="393.5 681.326 383.5 685.326 393.5 689.326 389.5 685.326" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1;stroke-dasharray:2,2" x1="387.5" x2="613.5" y1="685.326" y2="685.326"/><polygon fill="#181818" points="300 695.326 290 699.326 300 703.326 296 699.326" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1;stroke-dasharray:2,2" x1="294" x2="381.5" y1="699.326" y2="699.326"/><polygon fill="#181818" points="38 709.326 28 713.326 38 717.326 34 713.326" style="stroke:#181818;stroke-width:1"/><line style="stroke:#181818;stroke-width:1;stroke-dasharray:2,2" x1="32" x2="288" y1="713.326" y2="713.326"/></g></svg>