40 layoutRoot =
g_Game.GetWorkspace().CreateWidgets(
"gui/layouts/new_ui/notifications/day_z_input_device_warning.layout");
41 m_WrapperWidget =
WrapSpacerWidget.Cast(layoutRoot.FindAnyWidget(
"Wrapper"));
42 m_CaptionWidget =
TextWidget.Cast(layoutRoot.FindAnyWidget(
"Caption"));
43 m_DeviceListWidget =
RichTextWidget.Cast(layoutRoot.FindAnyWidget(
"DeviceList"));
44 m_ActionTextWidget =
RichTextWidget.Cast(layoutRoot.FindAnyWidget(
"ActionText"));
46 g_Game.GetMission().GetOnInputDeviceConnected().Insert(UpdateDisconnectedDevices);
47 g_Game.GetMission().GetOnInputDeviceDisconnected().Insert(UpdateDisconnectedDevices);
50 if (
g_Game.GetUIManager() &&
g_Game.GetUIManager().IsDialogVisible())
51 g_Game.GetUIManager().CloseDialog();