Jump to content
Korean Random

Отключение интерфейса в ангаре


Recommended Posts

Собственно вопрос возможно ли реализовать полное отключение и соответствено последующие включение интерфейса в ангаре.

Link to comment
Short link
Share on other sites

1 hour ago, Spectr20 said:

Неа мне нужно полное отключение

в орионе запусти находясь в ангаре

from gui.app_loader.loader import g_appLoader
from gui.Scaleform.framework import ViewTypes

hide_interface = False
try:
	app = g_appLoader.getDefLobbyApp()
	if app is not None:
		for comp in app.containerManager.getView(ViewTypes.VIEW).components.values():
			comp.flashObject.visible = hide_interface
		v = app.containerManager.getView(ViewTypes.LOBBY_SUB)
		if v is not None:
			v.flashObject.visible = hide_interface
except:
	import traceback
	traceback.print_exc()

Включение на True поменяй False, хотя это скорее поломает интерфейс уже

Edited by SkepticalFox
Link to comment
Short link
Share on other sites

Почему так сложно?

 

Выключение

from gui.app_loader.loader import g_appLoader
app = g_appLoader.getApp()
app.component.visible = False
app.graphicsOptimizationManager.switchOptimizationEnabled(False)

 

Включение

from gui.app_loader.loader import g_appLoader
app = g_appLoader.getApp()
app.component.visible = True
app.graphicsOptimizationManager.switchOptimizationEnabled(True)

И ничего не ломает.

Edited by Mixaill
исправил опечатку
  • Upvote 3
Link to comment
Short link
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...