Files
VOREStation/code/modules/tgui_panel/external.dm
Kashargul 542b35e56f tgui 516 (#16990)
* tgui 516

* nuking

* .

* .

* redux test

* this

* no longer in use

* removes debugs for now until someone ports the macro handling

* import types

* .

* maxWidth

* temp fix

* fix type import

* fix that

* also that

* version up

* also push this while on it

* rid of that

* dependency up

* allow mark up inputs

* update

* mb to search

* add scroll to nanoMap

* type fixing

* Update ExportTab.tsx

* Update index.tsx

* Update XenoarchReplicator.tsx

* Update XenoarchReplicator_clothing_vr.tsx

* Update XenoarchReplicator_clothing_vr.tsx

* Update XenoarchReplicator.tsx

* crew monitor improvements

* types
2025-02-13 18:30:38 +01:00

46 lines
1.4 KiB
Plaintext

/*!
* Copyright (c) 2020 Aleksej Komarov
* SPDX-License-Identifier: MIT
*/
/client/var/datum/tgui_panel/tgui_panel
/**
* tgui panel / chat troubleshooting verb
*/
/client/verb/fix_tgui_panel()
set name = "Fix chat"
set category = "OOC.Debug"
var/action
log_tgui(src, "Started fixing.", context = "verb/fix_tgui_panel")
nuke_chat()
// Failed to fix, using tgalert as fallback
action = tgalert(src, "Did that work?", "", "Yes", "No, switch to old ui")
if (action == "No, switch to old ui")
winset(src, "legacy_output_selector", "left=output_legacy")
log_tgui(src, "Failed to fix.", context = "verb/fix_tgui_panel")
/client/proc/nuke_chat()
// Catch all solution (kick the whole thing in the pants)
winset(src, "legacy_output_selector", "left=output_legacy")
if(!tgui_panel || !istype(tgui_panel))
log_tgui(src, "tgui_panel datum is missing",
context = "verb/fix_tgui_panel")
tgui_panel = new(src)
tgui_panel.initialize(force = TRUE)
// Force show the panel to see if there are any errors
winset(src, "legacy_output_selector", "left=output_browser")
if(prefs?.read_preference(/datum/preference/toggle/browser_dev_tools))
winset(src, null, "browser-options=[DEFAULT_CLIENT_BROWSER_OPTIONS],devtools")
/client/verb/refresh_tgui()
set name = "Refresh TGUI"
set category = "OOC.Debug"
for(var/window_id in tgui_windows)
var/datum/tgui_window/window = tgui_windows[window_id]
window.reinitialize()