Added a policy to configure the number of virtual desktops

This commit is contained in:
Valentin Sokolov 2023-07-27 16:33:23 +04:00
parent b732a864da
commit 449692a4fb
3 changed files with 67 additions and 1 deletions

View File

@ -145,6 +145,45 @@
</boolean>
</elements>
</policy>
<policy name="kde-desktops" class="User" displayName="$(string.kde-desktops)"
explainText="$(string.kde-desktops_help)"
key="Software\BaseALT\Policies\KDE"
presentation="$(presentation.kde-desktops-user-pr)">
<parentCategory ref="system:ALT_Settings_KDE" />
<supportedOn ref="system:SUPPORTED_AltP10" />
<elements>
<enum id="kde-desktops_setter" valueName="kwinrc.Desktops" required="true">
<item displayName="$(string.kde-desktops-one)">
<value>
<string>{"Desktops":{"Rows":"1", "Number":"1"}}</string>
</value>
</item>
<item displayName="$(string.kde-desktops-two)">
<value>
<string>{"Desktops":{"Rows":"1", "Number":"2"}}</string>
</value>
</item>
<item displayName="$(string.kde-desktops-three)">
<value>
<string>{"Desktops":{"Rows":"1", "Number":"3"}}</string>
</value>
</item>
<item displayName="$(string.kde-desktops-four)">
<value>
<string>{"Desktops":{"Rows":"1", "Number":"4"}}</string>
</value>
</item>
</enum>
<boolean id="kde-desktops_blocker" key="Software\BaseALT\Policies\KDELocks" valueName="kwinrc.FocusPolicy">
<trueValue>
<decimal value="1" />
</trueValue>
<falseValue>
<decimal value="0" />
</falseValue>
</boolean>
</elements>
</policy>
<policy name="kde-wallpaper" class="User" displayName="$(string.kde-wallpaper)"
explainText="$(string.kde-wallpaper_help)"
presentation="$(presentation.kde-wallpaper-user-pr)"

View File

@ -54,6 +54,9 @@
"English (British)"
</string>
<string id="kde-desktops">Virtual desktops</string>
<string id="kde-desktops_help">This policy allows you to configure the number of virtual desktops. The number of tables can be from one to four inclusive.</string>
<string id="kde-wallpaper">Desktop backgroung</string>
<string id="kde-wallpaper_help">This policy allows you to set images as your desktop background by specifying a file (eg /usr/share/wallpapers/table.png) containing the image.</string>
@ -122,6 +125,11 @@
<string id="kde-win-rend-High">Prefer smoother animation</string>
<string id="kde-win-rend-MostHigh">Force the smoothest animation</string>
<string id="kde-desktops-one">1</string>
<string id="kde-desktops-two">2</string>
<string id="kde-desktops-three">3</string>
<string id="kde-desktops-four">4</string>
</stringTable>
<presentationTable>
<presentation id="kde-win-activate-user-pr">
@ -139,6 +147,11 @@
<checkBox refId="kde-win-rendering_blocker">Block</checkBox>
<text>Blocking changes to this setting by the user. After restarting the device, the user's changes to the settings are not saved.</text>
</presentation>
<presentation id="kde-desktops-user-pr">
<dropdownList noSort="true" defaultItem="0" refId="kde-desktops_setter">Number of virtual desktops:</dropdownList>
<checkBox refId="kde-desktops_blocker">Block</checkBox>
<text>Blocking changes to this setting by the user. After restarting the device, the user's changes to the settings are not saved.</text>
</presentation>
<presentation id="kde-wallpaper-user-pr">
<textBox refId="kde-wallpaper-setter">
<label>File:</label>

View File

@ -55,6 +55,9 @@
</string>
<string id="kde-desktops">Виртуальные рабочие столы</string>
<string id="kde-desktops_help">Данная политика позволяет настраивать количество виртуальных рабочих столов. Количество столов может быть от одного до четырёх включительно.</string>
<string id="kde-wallpaper">Картинка фона рабочего стола</string>
<string id="kde-wallpaper_help">Данная политика позволяет установить изображения в качестве фона рабочего стола, указав файл (например, /usr/share/wallpapers/table.png), содержащий изображение.</string>
@ -123,6 +126,12 @@
<string id="kde-win-rend-High">Предпочитать более плавную анимацию</string>
<string id="kde-win-rend-MostHigh">Принудительно наиболее плавная анимация</string>
<string id="kde-desktops-one">1</string>
<string id="kde-desktops-two">2</string>
<string id="kde-desktops-three">3</string>
<string id="kde-desktops-four">4</string>
</stringTable>
<presentationTable>
<presentation id="kde-win-activate-user-pr">
@ -140,7 +149,12 @@
<checkBox refId="kde-win-rendering_blocker">Блокировать</checkBox>
<text>Блокировка изменений данной настройки пользователем. После перезагрузки устройства внесённые пользователем изменения настройки не сохраняются.</text>
</presentation>
<presentation id="kde-wallpaper-user-pr">
<presentation id="kde-desktops-user-pr">
<dropdownList noSort="true" defaultItem="0" refId="kde-desktops_setter">Количество виртуальных рабочих столов:</dropdownList>
<checkBox refId="kde-desktops_blocker">Блокировать</checkBox>
<text>Блокировка изменений данной настройки пользователем. После перезагрузки устройства внесённые пользователем изменения настройки не сохраняются.</text>
</presentation>
<presentation id="kde-wallpaper-user-pr">
<textBox refId="kde-wallpaper-setter">
<label>Файл:</label>
</textBox>