MCPcopy Create free account
hub / github.com/FSGModding/FSG_Mod_Assistant / themeUpdater

Method themeUpdater

lib/modAssist_window_lib.js:640–658  ·  view source on GitHub ↗

* update window theme

()

Source from the content-addressed store, hash-verified

638 * update window theme
639 */
640 themeUpdater() {
641 for ( const thisWinKey in this.win ) {
642 if ( this.isVisible(thisWinKey) ) {
643 this.sendToWindow(thisWinKey, 'win:updateTheme', this.#themeCurrentColor)
644 this.win[thisWinKey].setTitleBarOverlay({
645 color : this.#themeColors[this.#themeCurrentColor].background,
646 symbolColor : this.#themeColors[this.#themeCurrentColor].font,
647 })
648 }
649 }
650 this.multiWin = this.multiWin.filter((x) => !x.isDestroyed())
651 for ( const displayWin of this.multiWin ) {
652 displayWin.webContents.send('win:updateTheme')
653 displayWin.setTitleBarOverlay({
654 color : this.#themeColors[this.#themeCurrentColor].background,
655 symbolColor : this.#themeColors[this.#themeCurrentColor].font,
656 })
657 }
658 }
659 // #endregion
660
661 // #region size & position

Callers 2

constructorMethod · 0.80
changeThemeMethod · 0.80

Calls 2

isVisibleMethod · 0.80
sendToWindowMethod · 0.80

Tested by

no test coverage detected