mirror of
https://github.com/alexcrea/CustomAnvil.git
synced 2026-08-28 08:25:56 +02:00
multiples config related add
Some checks are pending
Java CI with Gradle / build (push) Waiting to run
Some checks are pending
Java CI with Gradle / build (push) Waiting to run
- Disable console debug by default - Display log on get to console and not "click to copy"
This commit is contained in:
parent
7ea708ec14
commit
447859848b
9 changed files with 74 additions and 19 deletions
|
|
@ -91,6 +91,7 @@ object ConfigOptions {
|
|||
// Debug flag
|
||||
const val DEBUG_LOGGING = "debug_log"
|
||||
const val VERBOSE_DEBUG_LOGGING = "debug_log_verbose"
|
||||
const val SHOW_CONSOLE_DEBUG_LOGGING = "display_debug_in_console"
|
||||
|
||||
// ----------------------
|
||||
// Default config values
|
||||
|
|
@ -129,8 +130,9 @@ object ConfigOptions {
|
|||
const val DEFAULT_MONEY_MULTIPLIER = 1.0
|
||||
|
||||
// Debug flag
|
||||
private const val DEFAULT_DEBUG_LOG = false
|
||||
private const val DEFAULT_VERBOSE_DEBUG_LOG = false
|
||||
const val DEFAULT_DEBUG_LOG = false
|
||||
const val DEFAULT_VERBOSE_DEBUG_LOG = false
|
||||
const val DEFAULT_SHOW_CONSOLE_DEBUG_LOGGING = false
|
||||
|
||||
var OVERRIDE_DEBUG_LOG: Boolean? = null
|
||||
var OVERRIDE_VERBOSE_DEBUG_LOG: Boolean? = null
|
||||
|
|
@ -471,6 +473,19 @@ object ConfigOptions {
|
|||
.getBoolean(VERBOSE_DEBUG_LOGGING, DEFAULT_VERBOSE_DEBUG_LOG)
|
||||
}
|
||||
|
||||
/**
|
||||
* Whether to show debug in console
|
||||
*/
|
||||
val showDebugLogInConsole: Boolean
|
||||
get() {
|
||||
val overrider = OVERRIDE_VERBOSE_DEBUG_LOG
|
||||
if(overrider != null) return overrider
|
||||
|
||||
return ConfigHolder.DEFAULT_CONFIG
|
||||
.config
|
||||
.getBoolean(SHOW_CONSOLE_DEBUG_LOGGING, DEFAULT_SHOW_CONSOLE_DEBUG_LOGGING)
|
||||
}
|
||||
|
||||
/**
|
||||
* Is the dialog menu for rename enabled
|
||||
*/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue