mirror of
https://github.com/Anuken/Mindustry.git
synced 2026-10-05 04:40:25 +03:00
Compare commits
1
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
beaa1da276 |
@@ -563,7 +563,11 @@ public class SettingsMenuDialog extends BaseDialog{
|
||||
Core.settings.put("swapdiagonal", false);
|
||||
}
|
||||
|
||||
dev.checkPref("console", false);
|
||||
dev.checkPref("console", false, val -> {
|
||||
if(val == false && ui.consolefrag != null){
|
||||
ui.consolefrag.close();
|
||||
}
|
||||
});
|
||||
dev.checkPref("drawhitboxes", false);
|
||||
dev.checkPref("showperformance", false);
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ public class ConsoleFragment extends Table{
|
||||
font = Fonts.def;
|
||||
|
||||
visible(() -> {
|
||||
if(input.keyTap(Binding.console) && settings.getBool("console") && (scene.getKeyboardFocus() == chatfield || !(scene.getKeyboardFocus() instanceof TextField)) && !ui.chatfrag.shown()){
|
||||
if(input.keyTap(Binding.console) && (settings.getBool("console") || shown) && (scene.getKeyboardFocus() == chatfield || !(scene.getKeyboardFocus() instanceof TextField)) && !ui.chatfrag.shown()){
|
||||
shown = !shown;
|
||||
if(shown && !open && settings.getBool("console")){
|
||||
toggle();
|
||||
@@ -227,6 +227,11 @@ public class ConsoleFragment extends Table{
|
||||
open = false; //never true on mobile
|
||||
}
|
||||
|
||||
public void close(){
|
||||
shown = false;
|
||||
open = false;
|
||||
}
|
||||
|
||||
public void toggle(){
|
||||
|
||||
if(!open){
|
||||
|
||||
Reference in New Issue
Block a user