mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-21 05:39:42 +00:00
Bring back empty script message
This commit is contained in:
parent
7361a1c6fd
commit
89e0de2314
5 changed files with 14 additions and 2 deletions
|
@ -268,6 +268,7 @@ namespace MWGui
|
|||
getWidget(mScriptBox, "ScriptBox");
|
||||
getWidget(mScriptView, "ScriptView");
|
||||
getWidget(mScriptAdapter, "ScriptAdapter");
|
||||
getWidget(mScriptDisabled, "ScriptDisabled");
|
||||
|
||||
#ifndef WIN32
|
||||
// hide gamma controls since it currently does not work under Linux
|
||||
|
@ -899,11 +900,12 @@ namespace MWGui
|
|||
for (const WeightedPage& weightedPage : weightedPages)
|
||||
mScriptList->addItem(weightedPage.mName, weightedPage.mIndex);
|
||||
|
||||
// Hide script settings tab when the game world isn't loaded and scripts couldn't add their settings
|
||||
// Hide script settings when the game world isn't loaded
|
||||
bool disabled = LuaUi::scriptSettingsPageCount() == 0;
|
||||
mScriptFilter->setVisible(!disabled);
|
||||
mScriptList->setVisible(!disabled);
|
||||
mScriptBox->setVisible(!disabled);
|
||||
mScriptDisabled->setVisible(disabled);
|
||||
|
||||
LuaUi::attachPageAt(mCurrentPage, mScriptAdapter);
|
||||
mScriptView->setCanvasSize(mScriptAdapter->getSize());
|
||||
|
|
|
@ -53,6 +53,7 @@ namespace MWGui
|
|||
MyGUI::EditBox* mScriptFilter;
|
||||
MyGUI::ListBox* mScriptList;
|
||||
MyGUI::Widget* mScriptBox;
|
||||
MyGUI::Widget* mScriptDisabled;
|
||||
MyGUI::ScrollView* mScriptView;
|
||||
LuaUi::LuaAdapter* mScriptAdapter;
|
||||
int mCurrentPage;
|
||||
|
|
|
@ -45,6 +45,7 @@ ReflectionShaderDetailWorld: "World"
|
|||
Refraction: "Refraction"
|
||||
Screenshot: "Screenshot"
|
||||
Scripts: "Scripts"
|
||||
ScriptsDisabled: "Load a game to access script settings."
|
||||
SecondaryLanguage: "Secondary Language"
|
||||
SecondaryLanguageTooltip: "Localization files for this language may be used if the primary language files lack the necessary lines."
|
||||
TextureFiltering: "Texture Filtering"
|
||||
|
|
|
@ -45,6 +45,7 @@ ReflectionShaderDetailWorld: "Мир"
|
|||
Refraction: "Рефракция"
|
||||
Screenshot: "Снимок экрана"
|
||||
Scripts: "Скрипты"
|
||||
ScriptsDisabled: "Загрузите игру, чтобы получить доступ к настройкам скриптов."
|
||||
SecondaryLanguage: "Дополнительный язык"
|
||||
SecondaryLanguageTooltip: "Язык, строки на котором будут использоваться, если соответствующие строки на основном языке не найдены."
|
||||
TextureFiltering: "Фильтрация текстур"
|
||||
|
|
|
@ -639,10 +639,17 @@
|
|||
<Widget type="TabItem">
|
||||
<Property key="Caption" value=" #{SettingsMenu:Scripts} "/>
|
||||
|
||||
<Widget name="ScriptDisabled" type="EditBox" skin="SandText" position_real="0 0 1 1" align="HStretch Top">
|
||||
<Property key="Caption" value="#{SettingsMenu:ScriptsDisabled}"/>
|
||||
<Property key="TextAlign" value="Center"/>
|
||||
<Property key="MultiLine" value="true"/>
|
||||
<Property key="WordWrap" value="true"/>
|
||||
<Property key="Static" value="true"/>
|
||||
</Widget>
|
||||
|
||||
<Widget type="HBox" position_real="0 0 1 0.99" align="Stretch">
|
||||
<Property key="Padding" value="0"/>
|
||||
<Property key="Spacing" value="0"/>
|
||||
|
||||
<Widget type="VBox" align="Left VStretch">
|
||||
<UserString key="VStretch" value="true"/>
|
||||
|
||||
|
|
Loading…
Reference in a new issue