mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 18:41:51 +00:00
missing content report moved to xml
This commit is contained in:
parent
61ca91b525
commit
132016d33f
9 changed files with 78 additions and 44 deletions
7
res/layouts/reports/missing_content.xml
Normal file
7
res/layouts/reports/missing_content.xml
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
<panel size='500' color='#00000080' padding='8' context='menu'>
|
||||
<label>@missing-content</label>
|
||||
<panel id='content_panel' size='480,100' color='#00000080' scrollable='true' max-length='400'>
|
||||
<!-- content is generated in script -->
|
||||
</panel>
|
||||
<button onclick='menu:back()'>@Back to Main Menu</button>
|
||||
</panel>
|
||||
5
res/layouts/reports/missing_content.xml.lua
Normal file
5
res/layouts/reports/missing_content.xml.lua
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
function on_open(report)
|
||||
for i, entry in ipairs(report.content) do
|
||||
document.content_panel:add(gui.template("content_entry", entry))
|
||||
end
|
||||
end
|
||||
4
res/layouts/templates/content_entry.xml
Normal file
4
res/layouts/templates/content_entry.xml
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
<panel size='500,20' color='0' orientation='horizontal' padding='2'>
|
||||
<label color='#80808080'>[%{type}]</label>
|
||||
<label color='#FF333380'>"%{name}</label>
|
||||
</panel>
|
||||
Loading…
Add table
Add a link
Reference in a new issue