File tree Expand file tree Collapse file tree
src/client/kotlin/com/github/fdh911 Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11package com.github.fdh911.modules
22
3+ import com.github.fdh911.render.Unicodes
34import com.github.fdh911.ui.UIWindow
45import imgui.ImGui
56import net.fabricmc.fabric.api.client.rendering.v1.WorldRenderContext
@@ -24,8 +25,10 @@ object ModuleList {
2425 }
2526
2627 val window = UIWindow (" Modules" ) {
27- for (module in modules)
28- if (ImGui .selectable(module.name))
28+ for (module in modules) {
29+ val title = " ${if (module.toggled) Unicodes .CHECKBOX_1 else Unicodes .CHECKBOX_0 } ${module.name} "
30+ if (ImGui .selectable(title))
2931 + module.getWindow()
32+ }
3033 }
3134}
Original file line number Diff line number Diff line change @@ -4,7 +4,9 @@ enum class Unicodes(val s: String) {
44 REMOVE (" \uf00d " ),
55 DUPLICATE (" \uf24d " ),
66 ANGLE_UP (" \uf106 " ),
7- ANGLE_DOWN (" \uf107 " );
7+ ANGLE_DOWN (" \uf107 " ),
8+ CHECKBOX_0 (" \uf0c8 " ),
9+ CHECKBOX_1 (" \uf14a " );
810
911 companion object {
1012 override fun toString () = entries.joinToString { it.s }
You can’t perform that action at this time.
0 commit comments