master #8

Merged
asmeron merged 12 commits from YanTheKaller/libublsettingsui-gtk3:master into master 2 years ago

1
.gitignore vendored

@ -146,3 +146,4 @@ ublsettings-ui-debug
.install-debug.sh
debug/
ubl-settings-test
terminal-commands

@ -123,8 +123,15 @@ install: check
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "com.ublinux.${PKGNAME}.cancel-symbolic.svg"
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/status/" "com.ublinux.${PKGNAME}.checked.svg"
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/status/" "com.ublinux.${PKGNAME}.warning.svg"
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/status/" "com.ublinux.${PKGNAME}.important.svg"
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "com.ublinux.${PKGNAME}.config-changes-symbolic.svg"
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "com.ublinux.${PKGNAME}.config-module-symbolic.svg"
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "com.ublinux.${PKGNAME}.config-sandbox-symbolic.svg"
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "com.ublinux.${PKGNAME}.config-sandbox-ram-home-symbolic.svg"
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "com.ublinux.${PKGNAME}.config-sandbox-hdd-symbolic.svg"
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "com.ublinux.${PKGNAME}.config-sandbox-hdd-home-symbolic.svg"
@if [ -z ${DESTDIR} ]; then \
[ -d "${DESTDIR}/usr/share/icons/hicolor/" ] && gtk-update-icon-cache -fiq "${DESTDIR}${PREFIX}/share/icons/hicolor/" &>/dev/null || true; \
[ -d "${DESTDIR}/usr/share/icons/hicolor/" ] && gtk-update-icon-cache -fiq "${DESTDIR}/usr/share/icons/hicolor/" &>/dev/null || true; \
update-desktop-database --quiet &>/dev/null || true; \
[ -d "${DESTDIR}/usr/share/applications" ] && touch "${DESTDIR}/usr/share/applications" &>/dev/null || true; \
ldconfig -n ${DESTDIR}${PREFIX}/lib; \

@ -0,0 +1,53 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
viewBox="0 0 512 512"
version="1.1"
id="svg4"
sodipodi:docname="all.svg"
width="512"
height="512"
inkscape:version="1.1.2 (0a00cf5339, 2022-02-04, custom)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<defs
id="defs8" />
<sodipodi:namedview
id="namedview6"
pagecolor="#ffffff"
bordercolor="#999999"
borderopacity="1"
inkscape:pageshadow="0"
inkscape:pageopacity="0"
inkscape:pagecheckerboard="0"
showgrid="false"
inkscape:zoom="0.49917265"
inkscape:cx="-135.22375"
inkscape:cy="401.66463"
inkscape:window-width="1920"
inkscape:window-height="1027"
inkscape:window-x="1920"
inkscape:window-y="0"
inkscape:window-maximized="1"
inkscape:current-layer="layer2" />
<!--! Font Awesome Free 6.4.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2023 Fonticons, Inc. -->
<g
inkscape:groupmode="layer"
id="layer1"
inkscape:label="1">
<path
id="path2"
style="stroke:none;fill:#4d4d4d;fill-opacity:1"
d="M 64 0 C 28.7 0 0 28.7 0 64 L 0 384 C 0 419.3 28.7 448 64 448 L 262.14453 448 L 254.78516 440.47656 C 243.743 429.55188 240.01739 414.12201 243.36523 400 L 64 400 C 55.2 400 48 392.8 48 384 L 48 64 C 48 55.2 55.2 48 64 48 L 80 48 L 80 152 C 80 165.3 90.7 176 104 176 L 296 176 C 309.3 176 320 165.3 320 152 L 320 51.900391 L 320.80078 52.699219 L 395.40039 127.09961 L 395.30078 127.19922 C 398.30078 130.19922 400 134.3 400 138.5 L 400 362.70508 L 446.19727 316.1543 C 446.74396 315.60173 447.33182 315.11774 447.90039 314.60156 L 447.90039 138.59961 C 447.90039 121.59961 441.19922 105.30078 429.19922 93.300781 L 354.80078 18.699219 C 342.80078 6.6992188 326.5 0 309.5 0 L 64 0 z M 128 48 L 272 48 L 272 128 L 128 128 L 128 48 z M 224 224 C 188.65378 224 160 252.65375 160 288 C 160 323.34625 188.65378 352 224 352 C 259.34622 352 288 323.34625 288 288 C 288 252.65375 259.34622 224 224 224 z M 335.71484 400 L 349.11719 413.97852 L 362.99023 400 L 335.71484 400 z " />
</g>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="2">
<path
d="m 493.97503,362.9975 c 9.4,-9.4 9.4,-24.6 0,-33.9 -9.4,-9.3 -24.6,-9.4 -33.9,0 l -111,111 -47,-47 c -9.4,-9.4 -24.6,-9.4 -33.9,0 -9.3,9.4 -9.4,24.6 0,33.9 l 64,64 c 9.4,9.4 24.6,9.4 33.9,0 z"
id="path850"
style="fill:#4d4d4d;fill-opacity:1" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.7 KiB

@ -0,0 +1,63 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
viewBox="0 0 512 512"
version="1.1"
id="svg4"
sodipodi:docname="module.svg"
width="512"
height="512"
inkscape:version="1.1.2 (0a00cf5339, 2022-02-04, custom)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<defs
id="defs8" />
<sodipodi:namedview
id="namedview6"
pagecolor="#ffffff"
bordercolor="#999999"
borderopacity="1"
inkscape:pageshadow="0"
inkscape:pageopacity="0"
inkscape:pagecheckerboard="0"
showgrid="false"
inkscape:zoom="0.5"
inkscape:cx="581"
inkscape:cy="243"
inkscape:window-width="1920"
inkscape:window-height="1027"
inkscape:window-x="1920"
inkscape:window-y="0"
inkscape:window-maximized="1"
inkscape:current-layer="layer2" />
<!--! Font Awesome Free 6.4.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2023 Fonticons, Inc. -->
<g
inkscape:groupmode="layer"
id="layer1"
inkscape:label="1">
<path
id="path2"
style="stroke:none;fill:#4d4d4d;fill-opacity:1"
d="M 64 0 C 28.7 0 0 28.7 0 64 L 0 384 C 0 419.3 28.7 448 64 448 L 250.80664 448 C 252.85692 437.39801 260.82763 430.85145 266.15234 428.17578 A 25.685575 25.685575 0 0 1 266.25586 428.125 L 289.92578 416.36523 L 266.24023 404.57812 A 25.685575 25.685575 0 0 1 266.10547 404.51172 C 264.1747 403.53668 261.90509 401.99523 259.68945 400 L 64 400 C 55.2 400 48 392.8 48 384 L 48 64 C 48 55.2 55.2 48 64 48 L 80 48 L 80 152 C 80 165.3 90.7 176 104 176 L 296 176 C 309.3 176 320 165.3 320 152 L 320 51.900391 L 320.80078 52.699219 L 395.40039 127.09961 L 395.30078 127.19922 C 398.30078 130.19922 400 134.3 400 138.5 L 400 231.29688 C 402.5955 231.71967 405.1502 232.3846 407.5957 233.35547 A 25.685575 25.685575 0 0 1 408.8418 233.88867 L 447.90039 251.83203 L 447.90039 138.59961 C 447.90039 121.59961 441.19922 105.30078 429.19922 93.300781 L 354.80078 18.699219 C 342.80078 6.6992188 326.5 0 309.5 0 L 64 0 z M 128 48 L 272 48 L 272 128 L 128 128 L 128 48 z M 224 224 C 188.65378 224 160 252.65375 160 288 C 160 323.34625 188.65378 352 224 352 C 240.36862 352 255.25321 345.80224 266.57031 335.69336 C 260.54681 332.81581 250.26758 325.22564 250.26758 310.63477 C 250.26758 295.74183 261.03734 288.08256 267.01172 285.35352 L 286.87109 276.22852 C 281.33897 246.51246 255.31965 224 224 224 z M 379.67188 425.92969 C 385.97942 428.62297 379.93885 426.7368 386.6582 428.11133 C 393.37756 429.48586 387.08291 428.84961 393.94141 428.84961 C 400.79991 428.84961 394.50526 429.48586 401.22461 428.11133 C 407.94396 426.7368 401.90338 428.62297 408.21094 425.92969 A 25.685575 25.685575 0 0 1 393.94141 427.26562 A 25.685575 25.685575 0 0 1 379.67188 425.92969 z " />
</g>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="2">
<path
id="path2-3"
style="fill:#008000;stroke-width:0.570322"
sodipodi:type="inkscape:offset"
inkscape:radius="0"
inkscape:original="M 389.75195 257.22656 L 277.68359 308.71484 C 275.37378 309.76994 275.37378 311.49779 277.68359 312.55859 L 389.75195 364.05469 A 11.452064 11.452064 0 0 0 398.11914 364.05469 L 510.19336 312.55859 C 512.47464 311.49779 512.47464 309.76994 510.19336 308.71484 L 398.11914 257.22656 A 11.338 11.338 0 0 0 389.75195 257.22656 z M 304.52344 364.05469 L 277.68359 377.41602 C 275.4023 378.55666 275.4023 380.43389 277.68359 381.58594 L 389.75781 437.36328 A 10.607987 10.607987 0 0 0 398.125 437.36328 L 510.19336 381.58594 C 512.50316 380.43389 512.50316 378.56237 510.19336 377.41602 L 483.35352 364.05469 A 10.619394 10.619394 0 0 0 474.98047 364.05469 L 398.125 402.31055 A 10.653613 10.653613 0 0 1 389.75781 402.31055 L 312.90039 364.05469 A 10.636503 10.636503 0 0 0 304.52344 364.05469 z M 304.52344 437.79102 L 277.68359 451.125 C 275.4023 452.27135 275.4023 454.14255 277.68359 455.2832 L 389.75781 511.07227 A 10.607987 10.607987 0 0 0 398.125 511.07227 L 510.19336 455.2832 C 512.50316 454.14255 512.50316 452.27213 510.19336 451.1543 L 483.35352 437.79102 A 10.619394 10.619394 0 0 0 474.98047 437.79102 L 398.125 476.00195 A 10.556658 10.556658 0 0 1 389.75781 476.00195 L 312.90039 437.79102 A 10.636503 10.636503 0 0 0 304.52344 437.79102 z "
d="m 389.75195,257.22656 -112.06836,51.48828 c -2.30981,1.0551 -2.30981,2.78295 0,3.84375 l 112.06836,51.4961 a 11.452064,11.452064 0 0 0 8.36719,0 l 112.07422,-51.4961 c 2.28128,-1.0608 2.28128,-2.78865 0,-3.84375 L 398.11914,257.22656 a 11.338,11.338 0 0 0 -8.36719,0 z m -85.22851,106.82813 -26.83985,13.36133 c -2.28129,1.14064 -2.28129,3.01787 0,4.16992 l 112.07422,55.77734 a 10.607987,10.607987 0 0 0 8.36719,0 l 112.06836,-55.77734 c 2.3098,-1.15205 2.3098,-3.02357 0,-4.16992 l -26.83984,-13.36133 a 10.619394,10.619394 0 0 0 -8.37305,0 L 398.125,402.31055 a 10.653613,10.653613 0 0 1 -8.36719,0 l -76.85742,-38.25586 a 10.636503,10.636503 0 0 0 -8.37695,0 z m 0,73.73633 -26.83985,13.33398 c -2.28129,1.14635 -2.28129,3.01755 0,4.1582 l 112.07422,55.78907 a 10.607987,10.607987 0 0 0 8.36719,0 L 510.19336,455.2832 c 2.3098,-1.14065 2.3098,-3.01107 0,-4.1289 l -26.83984,-13.36328 a 10.619394,10.619394 0 0 0 -8.37305,0 L 398.125,476.00195 a 10.556658,10.556658 0 0 1 -8.36719,0 l -76.85742,-38.21093 a 10.636503,10.636503 0 0 0 -8.37695,0 z" />
<path
id="path2-3-6"
style="fill:#4d4d4d;fill-opacity:1;stroke-width:0.570322"
sodipodi:type="inkscape:offset"
inkscape:radius="0"
inkscape:original="M 389.75195 257.22656 L 277.68359 308.71484 C 275.37378 309.76994 275.37378 311.49779 277.68359 312.55859 L 389.75195 364.05469 A 11.452064 11.452064 0 0 0 398.11914 364.05469 L 510.19336 312.55859 C 512.47464 311.49779 512.47464 309.76994 510.19336 308.71484 L 398.11914 257.22656 A 11.338 11.338 0 0 0 389.75195 257.22656 z M 304.52344 364.05469 L 277.68359 377.41602 C 275.4023 378.55666 275.4023 380.43389 277.68359 381.58594 L 389.75781 437.36328 A 10.607987 10.607987 0 0 0 398.125 437.36328 L 510.19336 381.58594 C 512.50316 380.43389 512.50316 378.56237 510.19336 377.41602 L 483.35352 364.05469 A 10.619394 10.619394 0 0 0 474.98047 364.05469 L 398.125 402.31055 A 10.653613 10.653613 0 0 1 389.75781 402.31055 L 312.90039 364.05469 A 10.636503 10.636503 0 0 0 304.52344 364.05469 z M 304.52344 437.79102 L 277.68359 451.125 C 275.4023 452.27135 275.4023 454.14255 277.68359 455.2832 L 389.75781 511.07227 A 10.607987 10.607987 0 0 0 398.125 511.07227 L 510.19336 455.2832 C 512.50316 454.14255 512.50316 452.27213 510.19336 451.1543 L 483.35352 437.79102 A 10.619394 10.619394 0 0 0 474.98047 437.79102 L 398.125 476.00195 A 10.556658 10.556658 0 0 1 389.75781 476.00195 L 312.90039 437.79102 A 10.636503 10.636503 0 0 0 304.52344 437.79102 z "
d="m 389.75195,257.22656 -112.06836,51.48828 c -2.30981,1.0551 -2.30981,2.78295 0,3.84375 l 112.06836,51.4961 a 11.452064,11.452064 0 0 0 8.36719,0 l 112.07422,-51.4961 c 2.28128,-1.0608 2.28128,-2.78865 0,-3.84375 L 398.11914,257.22656 a 11.338,11.338 0 0 0 -8.36719,0 z m -85.22851,106.82813 -26.83985,13.36133 c -2.28129,1.14064 -2.28129,3.01787 0,4.16992 l 112.07422,55.77734 a 10.607987,10.607987 0 0 0 8.36719,0 l 112.06836,-55.77734 c 2.3098,-1.15205 2.3098,-3.02357 0,-4.16992 l -26.83984,-13.36133 a 10.619394,10.619394 0 0 0 -8.37305,0 L 398.125,402.31055 a 10.653613,10.653613 0 0 1 -8.36719,0 l -76.85742,-38.25586 a 10.636503,10.636503 0 0 0 -8.37695,0 z m 0,73.73633 -26.83985,13.33398 c -2.28129,1.14635 -2.28129,3.01755 0,4.1582 l 112.07422,55.78907 a 10.607987,10.607987 0 0 0 8.36719,0 L 510.19336,455.2832 c 2.3098,-1.14065 2.3098,-3.01107 0,-4.1289 l -26.83984,-13.36328 a 10.619394,10.619394 0 0 0 -8.37305,0 L 398.125,476.00195 a 10.556658,10.556658 0 0 1 -8.36719,0 l -76.85742,-38.21093 a 10.636503,10.636503 0 0 0 -8.37695,0 z" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 7.9 KiB

@ -0,0 +1,53 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
viewBox="0 0 512 512"
version="1.1"
id="svg4"
sodipodi:docname="profile.svg"
width="512"
height="512"
inkscape:version="1.1.2 (0a00cf5339, 2022-02-04, custom)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<defs
id="defs8" />
<sodipodi:namedview
id="namedview6"
pagecolor="#ffffff"
bordercolor="#999999"
borderopacity="1"
inkscape:pageshadow="0"
inkscape:pageopacity="0"
inkscape:pagecheckerboard="0"
showgrid="false"
inkscape:zoom="1"
inkscape:cx="317.5"
inkscape:cy="369.5"
inkscape:window-width="1920"
inkscape:window-height="1027"
inkscape:window-x="1920"
inkscape:window-y="0"
inkscape:window-maximized="1"
inkscape:current-layer="layer2" />
<!--! Font Awesome Free 6.4.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2023 Fonticons, Inc. -->
<g
inkscape:groupmode="layer"
id="layer1"
inkscape:label="1">
<path
id="path2"
style="stroke:none;fill:#4d4d4d;fill-opacity:1"
d="M 64 0 C 28.7 0 0 28.7 0 64 L 0 384 C 0 419.3 28.7 448 64 448 L 274.23242 448 C 285.12035 426.60094 301.6191 409.65973 321.33008 400 L 64 400 C 55.2 400 48 392.8 48 384 L 48 64 C 48 55.2 55.2 48 64 48 L 80 48 L 80 152 C 80 165.3 90.7 176 104 176 L 296 176 C 309.3 176 320 165.3 320 152 L 320 51.900391 L 320.80078 52.699219 L 395.40039 127.09961 L 395.30078 127.19922 C 398.30078 130.19922 400 134.3 400 138.5 L 400 229.82812 C 417.65778 229.84231 434.09291 235.04288 447.90039 243.96289 L 447.90039 138.59961 C 447.90039 121.59961 441.19922 105.30078 429.19922 93.300781 L 354.80078 18.699219 C 342.80078 6.6992186 326.5 0 309.5 0 L 64 0 z M 128 48 L 272 48 L 272 128 L 128 128 L 128 48 z M 224 224 C 188.65378 224 160 252.65375 160 288 C 160 323.34625 188.65378 352 224 352 C 259.34622 352 288 323.34625 288 288 C 288 252.65375 259.34622 224 224 224 z " />
</g>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="2">
<path
d="m 398.66308,382.61981 c 35.34625,0 63.99997,-28.65378 63.99997,-64 0,-35.34622 -28.65372,-64 -63.99997,-64 -35.34625,0 -63.99997,28.65378 -63.99997,64 0,35.34622 28.65372,64 63.99997,64 z m -32,32 c -44.2,0 -80,35.8 -80,80 0,8.8 7.2,16 16,16 h 192 c 8.8,0 16,-7.2 16,-16 0,-44.2 -35.8,-80 -80,-80 z"
id="path850"
style="fill:#4d4d4d;fill-opacity:1" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.7 KiB

@ -0,0 +1,54 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
viewBox="0 0 512 512"
version="1.1"
id="svg4"
sodipodi:docname="sandbox.svg"
width="512"
height="512"
inkscape:version="1.1.2 (0a00cf5339, 2022-02-04, custom)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<defs
id="defs8" />
<sodipodi:namedview
id="namedview6"
pagecolor="#ffffff"
bordercolor="#999999"
borderopacity="1"
inkscape:pageshadow="0"
inkscape:pageopacity="0"
inkscape:pagecheckerboard="0"
showgrid="false"
inkscape:zoom="1"
inkscape:cx="180.5"
inkscape:cy="284.5"
inkscape:window-width="1920"
inkscape:window-height="1027"
inkscape:window-x="1920"
inkscape:window-y="0"
inkscape:window-maximized="1"
inkscape:current-layer="layer2" />
<!--! Font Awesome Free 6.4.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2023 Fonticons, Inc. -->
<g
inkscape:groupmode="layer"
id="layer1"
inkscape:label="1">
<path
id="path1858"
d="M 64 0 C 28.7 0 0 28.7 0 64 L 0 384 C 0 419.3 28.7 448 64 448 L 300.46484 448 L 345.62695 402.83594 L 342.79102 400 L 64 400 C 55.2 400 48 392.8 48 384 L 48 64 C 48 55.2 55.2 48 64 48 L 80 48 L 80 152 C 80 165.3 90.7 176 104 176 L 296 176 C 309.3 176 320 165.3 320 152 L 320 51.900391 L 320.80078 52.699219 L 395.40039 127.09961 L 395.30078 127.19922 C 398.30078 130.19922 400 134.3 400 138.5 L 400 339.89453 L 404.28516 344.17969 L 447.90039 300.5625 L 447.90039 138.59961 C 447.90039 121.59961 441.19922 105.30078 429.19922 93.300781 L 354.80078 18.699219 C 342.80078 6.6992188 326.5 0 309.5 0 L 64 0 z M 128 48 L 272 48 L 272 128 L 128 128 L 128 48 z M 224 224 C 188.65378 224 160 252.65375 160 288 C 160 323.34625 188.65378 352 224 352 C 259.34622 352 288 323.34625 288 288 C 288 252.65375 259.34622 224 224 224 z "
style="stroke:none;fill:#4d4d4d;fill-opacity:1" />
</g>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="2"
style="display:inline">
<path
d="m 316.57154,315.12344 c 10.19164,-10.19164 26.67173,-10.19164 36.75494,0 l 50.95819,50.95818 50.95819,-50.95818 c 10.19163,-10.19164 26.67173,-10.19164 36.75494,0 10.08322,10.19163 10.19164,26.67173 0,36.75494 l -50.95818,50.95819 50.95818,50.95819 c 10.19164,10.19163 10.19164,26.67173 0,36.75494 -10.19163,10.08322 -26.67173,10.19164 -36.75494,0 l -50.95819,-50.95818 -50.95819,50.95818 c -10.19163,10.19164 -26.67173,10.19164 -36.75494,0 -10.08322,-10.19164 -10.19164,-26.67173 0,-36.75494 l 50.95818,-50.95819 -50.95818,-50.95819 c -10.19164,-10.19163 -10.19164,-26.67173 0,-36.75494 z"
id="path850"
style="fill:#4d4d4d;stroke-width:1.08422;fill-opacity:1" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.0 KiB

@ -0,0 +1,53 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
viewBox="0 0 512 512"
version="1.1"
id="svg4"
sodipodi:docname="profile.svg"
width="512"
height="512"
inkscape:version="1.1.2 (0a00cf5339, 2022-02-04, custom)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<defs
id="defs8" />
<sodipodi:namedview
id="namedview6"
pagecolor="#ffffff"
bordercolor="#999999"
borderopacity="1"
inkscape:pageshadow="0"
inkscape:pageopacity="0"
inkscape:pagecheckerboard="0"
showgrid="false"
inkscape:zoom="1"
inkscape:cx="317.5"
inkscape:cy="369.5"
inkscape:window-width="1920"
inkscape:window-height="1027"
inkscape:window-x="1920"
inkscape:window-y="0"
inkscape:window-maximized="1"
inkscape:current-layer="layer2" />
<!--! Font Awesome Free 6.4.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2023 Fonticons, Inc. -->
<g
inkscape:groupmode="layer"
id="layer1"
inkscape:label="1">
<path
id="path2"
style="stroke:none;fill:#4d4d4d;fill-opacity:1"
d="M 64 0 C 28.7 0 0 28.7 0 64 L 0 384 C 0 419.3 28.7 448 64 448 L 274.23242 448 C 285.12035 426.60094 301.6191 409.65973 321.33008 400 L 64 400 C 55.2 400 48 392.8 48 384 L 48 64 C 48 55.2 55.2 48 64 48 L 80 48 L 80 152 C 80 165.3 90.7 176 104 176 L 296 176 C 309.3 176 320 165.3 320 152 L 320 51.900391 L 320.80078 52.699219 L 395.40039 127.09961 L 395.30078 127.19922 C 398.30078 130.19922 400 134.3 400 138.5 L 400 229.82812 C 417.65778 229.84231 434.09291 235.04288 447.90039 243.96289 L 447.90039 138.59961 C 447.90039 121.59961 441.19922 105.30078 429.19922 93.300781 L 354.80078 18.699219 C 342.80078 6.6992186 326.5 0 309.5 0 L 64 0 z M 128 48 L 272 48 L 272 128 L 128 128 L 128 48 z M 224 224 C 188.65378 224 160 252.65375 160 288 C 160 323.34625 188.65378 352 224 352 C 259.34622 352 288 323.34625 288 288 C 288 252.65375 259.34622 224 224 224 z " />
</g>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="2">
<path
d="m 398.66308,382.61981 c 35.34625,0 63.99997,-28.65378 63.99997,-64 0,-35.34622 -28.65372,-64 -63.99997,-64 -35.34625,0 -63.99997,28.65378 -63.99997,64 0,35.34622 28.65372,64 63.99997,64 z m -32,32 c -44.2,0 -80,35.8 -80,80 0,8.8 7.2,16 16,16 h 192 c 8.8,0 16,-7.2 16,-16 0,-44.2 -35.8,-80 -80,-80 z"
id="path850"
style="fill:#4d4d4d;fill-opacity:1" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.7 KiB

@ -0,0 +1,54 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
viewBox="0 0 512 512"
version="1.1"
id="svg4"
sodipodi:docname="sandbox.svg"
width="512"
height="512"
inkscape:version="1.1.2 (0a00cf5339, 2022-02-04, custom)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<defs
id="defs8" />
<sodipodi:namedview
id="namedview6"
pagecolor="#ffffff"
bordercolor="#999999"
borderopacity="1"
inkscape:pageshadow="0"
inkscape:pageopacity="0"
inkscape:pagecheckerboard="0"
showgrid="false"
inkscape:zoom="1"
inkscape:cx="180.5"
inkscape:cy="284.5"
inkscape:window-width="1920"
inkscape:window-height="1027"
inkscape:window-x="1920"
inkscape:window-y="0"
inkscape:window-maximized="1"
inkscape:current-layer="layer2" />
<!--! Font Awesome Free 6.4.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2023 Fonticons, Inc. -->
<g
inkscape:groupmode="layer"
id="layer1"
inkscape:label="1">
<path
id="path1858"
d="M 64 0 C 28.7 0 0 28.7 0 64 L 0 384 C 0 419.3 28.7 448 64 448 L 300.46484 448 L 345.62695 402.83594 L 342.79102 400 L 64 400 C 55.2 400 48 392.8 48 384 L 48 64 C 48 55.2 55.2 48 64 48 L 80 48 L 80 152 C 80 165.3 90.7 176 104 176 L 296 176 C 309.3 176 320 165.3 320 152 L 320 51.900391 L 320.80078 52.699219 L 395.40039 127.09961 L 395.30078 127.19922 C 398.30078 130.19922 400 134.3 400 138.5 L 400 339.89453 L 404.28516 344.17969 L 447.90039 300.5625 L 447.90039 138.59961 C 447.90039 121.59961 441.19922 105.30078 429.19922 93.300781 L 354.80078 18.699219 C 342.80078 6.6992188 326.5 0 309.5 0 L 64 0 z M 128 48 L 272 48 L 272 128 L 128 128 L 128 48 z M 224 224 C 188.65378 224 160 252.65375 160 288 C 160 323.34625 188.65378 352 224 352 C 259.34622 352 288 323.34625 288 288 C 288 252.65375 259.34622 224 224 224 z "
style="stroke:none;fill:#4d4d4d;fill-opacity:1" />
</g>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="2"
style="display:inline">
<path
d="m 316.57154,315.12344 c 10.19164,-10.19164 26.67173,-10.19164 36.75494,0 l 50.95819,50.95818 50.95819,-50.95818 c 10.19163,-10.19164 26.67173,-10.19164 36.75494,0 10.08322,10.19163 10.19164,26.67173 0,36.75494 l -50.95818,50.95819 50.95818,50.95819 c 10.19164,10.19163 10.19164,26.67173 0,36.75494 -10.19163,10.08322 -26.67173,10.19164 -36.75494,0 l -50.95819,-50.95818 -50.95819,50.95818 c -10.19163,10.19164 -26.67173,10.19164 -36.75494,0 -10.08322,-10.19164 -10.19164,-26.67173 0,-36.75494 l 50.95818,-50.95819 -50.95818,-50.95819 c -10.19164,-10.19163 -10.19164,-26.67173 0,-36.75494 z"
id="path850"
style="fill:#4d4d4d;stroke-width:1.08422;fill-opacity:1" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.0 KiB

@ -0,0 +1,55 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
viewBox="0 0 24 24"
id="svg2"
version="1.1"
inkscape:version="1.1.2 (0a00cf5339, 2022-02-04, custom)"
sodipodi:docname="com.ublinux.libublsettingsui-gtk3.important.svg"
width="24"
height="24"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:dc="http://purl.org/dc/elements/1.1/">
<metadata
id="metadata12">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<defs
id="defs10" />
<sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1920"
inkscape:window-height="1023"
id="namedview8"
showgrid="false"
inkscape:zoom="18.96875"
inkscape:cx="5.4827018"
inkscape:cy="9.3311367"
inkscape:current-layer="svg2"
inkscape:pagecheckerboard="0"
inkscape:window-x="0"
inkscape:window-y="0"
inkscape:window-maximized="1" />
<path
id="path4136-2"
style="opacity:1;fill:#4d4d4d;fill-opacity:1"
d="M 11.292969,22.976562 A 11.000002,11 3.688344 0 1 1.0234375,11.292969 11.000002,11 3.688344 0 1 12.707031,1.0234375 11.000002,11 3.688344 0 1 22.976562,12.707031 11.000002,11 3.688344 0 1 11.292969,22.976562 Z M 11.996094,18 h 0.0078 C 12.556173,18 13,17.5561 13,17.003906 V 9.9960935 c 0,-0.552419 -0.443827,-0.996094 -0.996094,-0.996094 h -0.0078 C 11.443827,8.9999995 11,9.4436745 11,9.9960935 V 17.003906 C 11,17.5561 11.443827,18 11.996094,18 Z M 12,6.9999995 c 0.554,0 1,-0.446 1,-1 0,-0.554 -0.446,-1 -1,-1 -0.554,0 -1,0.446 -1,1 0,0.554 0.446,1 1,1 z" />
</svg>

After

Width:  |  Height:  |  Size: 2.1 KiB

@ -5,12 +5,12 @@
<object class="GtkImage" id="image8">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="icon-name">process-stop-symbolic</property>
<property name="icon-name">com.ublinux.libublsettingsui-gtk3.cancel-symbolic</property>
</object>
<object class="GtkImage" id="image9">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="icon-name">emblem-ok-symbolic</property>
<property name="icon-name">com.ublinux.libublsettingsui-gtk3.accept-symbolic</property>
</object>
<object class="GtkApplicationWindow" id="helpConfirmationWindow">
<property name="can-focus">False</property>
@ -53,14 +53,14 @@
<object class="GtkBox">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="margin-top">10</property>
<property name="orientation">vertical</property>
<property name="spacing">5</property>
<child>
<object class="GtkLabel">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="margin-top">10</property>
<property name="margin-bottom">5</property>
<property name="label" translatable="yes">Would you like to read documentation in the Web?</property>
<property name="wrap">True</property>
<property name="xalign">0</property>
@ -83,11 +83,8 @@
<property name="can-focus">False</property>
<property name="halign">start</property>
<property name="valign">start</property>
<property name="margin-right">10</property>
<property name="margin-end">10</property>
<property name="label" translatable="yes">You will be redirected to documentation website where documentation is
translated and supported by community.</property>
<property name="wrap">True</property>
<property name="xalign">0</property>
<style>
<class name="fgnb"/>

@ -44,38 +44,19 @@
<column type="gchararray"/>
</columns>
</object>
<object class="GtkDialog" id="Window">
<object class="GtkWindow" id="Window">
<property name="width-request">450</property>
<property name="height-request">500</property>
<property name="can-focus">False</property>
<property name="modal">True</property>
<property name="icon-name">com.ublinux.libublsettingsui-gtk3</property>
<property name="type-hint">dialog</property>
<child internal-child="vbox">
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="margin-bottom">5</property>
<property name="orientation">vertical</property>
<property name="spacing">5</property>
<child internal-child="action_area">
<object class="GtkButtonBox">
<property name="can-focus">False</property>
<property name="layout-style">end</property>
<child>
<placeholder/>
</child>
<child>
<placeholder/>
</child>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="pack-type">end</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkBox" id="StatusBox">
<property name="visible">True</property>
@ -92,83 +73,106 @@
</packing>
</child>
<child>
<object class="GtkScrolledWindow">
<object class="GtkBox">
<property name="visible">True</property>
<property name="can-focus">True</property>
<property name="shadow-type">in</property>
<property name="can-focus">False</property>
<property name="margin-start">5</property>
<property name="margin-end">5</property>
<property name="margin-bottom">5</property>
<property name="orientation">vertical</property>
<child>
<object class="GtkTreeView" id="ParametersTree">
<object class="GtkScrolledWindow">
<property name="visible">True</property>
<property name="can-focus">True</property>
<property name="model">liststore1</property>
<child internal-child="selection">
<object class="GtkTreeSelection">
<property name="mode">none</property>
</object>
</child>
<property name="shadow-type">in</property>
<child>
<object class="GtkTreeViewColumn">
<property name="title" translatable="yes">Save</property>
<object class="GtkTreeView" id="ParametersTree">
<property name="visible">True</property>
<property name="can-focus">True</property>
<property name="model">liststore1</property>
<property name="enable-grid-lines">horizontal</property>
<property name="tooltip-column">3</property>
<child internal-child="selection">
<object class="GtkTreeSelection">
<property name="mode">none</property>
</object>
</child>
<child>
<object class="GtkCellRendererToggle" id="ToggleCell"/>
<attributes>
<attribute name="cell-background">4</attribute>
<attribute name="sensitive">5</attribute>
<attribute name="active">0</attribute>
</attributes>
<object class="GtkTreeViewColumn">
<property name="title" translatable="yes">Save</property>
<child>
<object class="GtkCellRendererToggle" id="ToggleCell"/>
<attributes>
<attribute name="cell-background">4</attribute>
<attribute name="sensitive">5</attribute>
<attribute name="active">0</attribute>
</attributes>
</child>
</object>
</child>
</object>
</child>
<child>
<object class="GtkTreeViewColumn">
<property name="resizable">True</property>
<property name="title" translatable="yes">Parameter</property>
<child>
<object class="GtkCellRendererText"/>
<attributes>
<attribute name="cell-background">4</attribute>
<attribute name="sensitive">5</attribute>
<attribute name="text">1</attribute>
</attributes>
<object class="GtkTreeViewColumn">
<property name="resizable">True</property>
<property name="title" translatable="yes">Parameter</property>
<child>
<object class="GtkCellRendererText">
<property name="wrap-width">150</property>
</object>
<attributes>
<attribute name="cell-background">4</attribute>
<attribute name="sensitive">5</attribute>
<attribute name="text">1</attribute>
</attributes>
</child>
</object>
</child>
</object>
</child>
<child>
<object class="GtkTreeViewColumn">
<property name="resizable">True</property>
<property name="sizing">fixed</property>
<property name="title" translatable="yes">Old value</property>
<child>
<object class="GtkCellRendererText"/>
<attributes>
<attribute name="cell-background">4</attribute>
<attribute name="sensitive">5</attribute>
<attribute name="text">2</attribute>
</attributes>
<object class="GtkTreeViewColumn" id="OldValueColumn">
<property name="resizable">True</property>
<property name="sizing">fixed</property>
<property name="title" translatable="yes">Old value</property>
<child>
<object class="GtkCellRendererText" id="OldValueCell">
<property name="wrap-width">250</property>
</object>
<attributes>
<attribute name="cell-background">4</attribute>
<attribute name="sensitive">5</attribute>
<attribute name="text">2</attribute>
</attributes>
</child>
</object>
</child>
</object>
</child>
<child>
<object class="GtkTreeViewColumn">
<property name="sizing">autosize</property>
<property name="title" translatable="yes">New value</property>
<child>
<object class="GtkCellRendererText"/>
<attributes>
<attribute name="cell-background">4</attribute>
<attribute name="sensitive">5</attribute>
<attribute name="text">3</attribute>
</attributes>
<object class="GtkTreeViewColumn" id="NewValueColumn">
<property name="sizing">autosize</property>
<property name="title" translatable="yes">New value</property>
<child>
<object class="GtkCellRendererText" id="NewValueCell">
<property name="wrap-width">250</property>
</object>
<attributes>
<attribute name="cell-background">4</attribute>
<attribute name="sensitive">5</attribute>
<attribute name="text">3</attribute>
</attributes>
</child>
</object>
</child>
</object>
</child>
</object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
<property name="position">2</property>
</packing>
</child>
</object>

@ -261,6 +261,25 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
<property name="position">1</property>
</packing>
</child>
<child>
<object class="GtkImage" id="ModeStatusImage">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="margin-start">5</property>
<property name="margin-end">5</property>
<property name="margin-top">5</property>
<property name="margin-bottom">5</property>
<property name="pixel-size">25</property>
<property name="icon-name">com.ublinux.libublsettingsui-gtk3.statemode-yellow-symbolic</property>
<property name="icon_size">6</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="pack-type">end</property>
<property name="position">2</property>
</packing>
</child>
</object>
<packing>
<property name="expand">False</property>

@ -121,14 +121,38 @@ msgstr ""
msgid "Local configuration saving succeeded."
msgstr ""
#: source/libublsettingsui-gtk3.h:64
#: source/libublsettingsui-gtk3.h:65
msgid "Parameter"
msgstr ""
#: source/libublsettingsui-gtk3.h:65
#: source/libublsettingsui-gtk3.h:66
msgid "Old value"
msgstr ""
#: source/libublsettingsui-gtk3.h:66
#: source/libublsettingsui-gtk3.h:67
msgid "New value"
msgstr ""
#: source/libublsettingsui-gtk3.h:72
msgid "Full saving mode"
msgstr ""
#: source/libublsettingsui-gtk3.h:73
msgid "Saving into module"
msgstr ""
#: source/libublsettingsui-gtk3.h:74
msgid "Sandbox mode"
msgstr ""
#: source/libublsettingsui-gtk3.h:75
msgid "Sandbox with profile saving"
msgstr ""
#: source/libublsettingsui-gtk3.h:76
msgid "HDD sandbox"
msgstr ""
#: source/libublsettingsui-gtk3.h:77
msgid "HDD sandbox with profile saving"
msgstr ""

@ -125,14 +125,38 @@ msgstr "Успешно записана глобальная конфигура
msgid "Local configuration saving succeeded."
msgstr "Успешно записана локальная конфигурация"
#: source/libublsettingsui-gtk3.h:64
#: source/libublsettingsui-gtk3.h:65
msgid "Parameter"
msgstr "Параметр"
#: source/libublsettingsui-gtk3.h:65
#: source/libublsettingsui-gtk3.h:66
msgid "Old value"
msgstr "Старое значение"
#: source/libublsettingsui-gtk3.h:66
#: source/libublsettingsui-gtk3.h:67
msgid "New value"
msgstr "Новое значение"
#: source/libublsettingsui-gtk3.h:72
msgid "Full saving mode"
msgstr "Полное сохранение"
#: source/libublsettingsui-gtk3.h:73
msgid "Saving into module"
msgstr "Сохранение в модуль"
#: source/libublsettingsui-gtk3.h:74
msgid "Sandbox mode"
msgstr "Полная песочница в ОЗУ"
#: source/libublsettingsui-gtk3.h:75
msgid "Sandbox with profile saving"
msgstr "Песочница с сохранением профиля пользователя"
#: source/libublsettingsui-gtk3.h:76
msgid "HDD sandbox"
msgstr "Полная песочница на HDD"
#: source/libublsettingsui-gtk3.h:77
msgid "HDD sandbox with profile saving"
msgstr "Полная песочница на HDD с сохранением профиля пользователя"

@ -1,6 +1,50 @@
#include "libublsettingsui-gtk3.h"
static char *__yon_config_mode=NULL;
char *yon_ubl_save_mode_get_icon_name(SAVE_MODE_TYPE type){
switch (type){
case SAVE_MODE_FULL:
return "com.ublinux.libublsettingsui-gtk3.config-changes-symbolic";
break;
case SAVE_MODE_MODULE:
return "com.ublinux.libublsettingsui-gtk3.config-module-symbolic";
break;
case SAVE_MODE_SANDBOX:
return "com.ublinux.libublsettingsui-gtk3.config-sandbox-symbolic";
break;
case SAVE_MODE_RAM_HOME:
return "com.ublinux.libublsettingsui-gtk3.config-sandbox-ram-home-symbolic";
break;
case SAVE_MODE_HDD:
return "com.ublinux.libublsettingsui-gtk3.config-sandbox-hdd-symbolic";
break;
case SAVE_MODE_HDD_HOME:
return "com.ublinux.libublsettingsui-gtk3.config-sandbox-hdd-home-symbolic";
break;
}
}
SAVE_MODE_TYPE yon_ubl_save_mode_get_type(char *type){
if (!strcmp(type,"changes")){
return SAVE_MODE_FULL;
}
if (!strcmp(type,"module")){
return SAVE_MODE_MODULE;
}
if (!strcmp(type,"sandbox")){
return SAVE_MODE_SANDBOX;
}
if (!strcmp(type,"sandbox_ram_home")){
return SAVE_MODE_RAM_HOME;
}
if (!strcmp(type,"sandbox_hdd")){
return SAVE_MODE_HDD;
}
if (!strcmp(type,"sandbox_hdd_home")){
return SAVE_MODE_HDD_HOME;
}
}
//signal emmit handlers - no header initialization
@ -60,6 +104,7 @@ void on_about(GtkWidget *self, char *version_application){
gtk_about_dialog_set_version(GTK_ABOUT_DIALOG(window),version_application);
gtk_about_dialog_set_comments(GTK_ABOUT_DIALOG(window),template_app_information.app_title);
gtk_about_dialog_set_logo_icon_name(GTK_ABOUT_DIALOG(window),yon_char_append("com.ublinux.",template_app_information.app_tech_name));
gtk_about_dialog_set_program_name(GTK_ABOUT_DIALOG(window),template_app_information.app_tech_name);
gtk_label_set_text(GTK_LABEL(title),template_app_information.app_title);
g_signal_connect(G_OBJECT(window),"activate-link",G_CALLBACK(on_link),NULL);
gtk_widget_set_visible(hideButtonBox,0);
@ -147,6 +192,13 @@ void on_save_parameters(GtkWidget *self, template_saving_window *window){
free(final_command);
}
}
if (window->type==YON_CONFIG_BOTH) {
if (template_config->load_mode==1){
yon_config_save_registered("system");
} else if (template_config->load_mode==0){
yon_config_save_registered("global");
}
}
textdomain(template_ui_LocaleName);
if (window->type == YON_CONFIG_GLOBAL)
yon_ubl_status_box_render(GLOBAL_SAVE_SUCCESS_LABEL,BACKGROUND_IMAGE_SUCCESS_TYPE);
@ -160,6 +212,19 @@ void on_save_parameters(GtkWidget *self, template_saving_window *window){
on_subwindow_close(self);
}
// void on_column_resize(GtkTreeVieolumn *self,GParamSpec *pspec,GtkCellRenderer *renderer){
// GtkWidget *tree = gtk_tree_view_column_get_tree_view(self);
// GtkTreeModel *model = gtk_tree_view_get_model(GTK_TREE_VIEW(tree));
// // g_object_ref(model);
// // gtk_tree_view_set_model(GTK_TREE_VIEW(tree),NULL);
// int width = gtk_tree_view_column_get_width(self);
// GValue *val=g_malloc0(sizeof(GValue));
// g_object_get_property(G_OBJECT(renderer),"wrap-width",val);
// g_value_set_int(val,width);
// g_object_set_property(G_OBJECT(renderer),"wrap-width",val);
// gtk_tree_view_set_model(GTK_TREE_VIEW(tree),model);wC
// }
template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
if (((type==YON_CONFIG_LOCAL&& template_config->load_mode==1)||(type==YON_CONFIG_GLOBAL&& template_config->load_mode==0))){
yon_config_save_registered(path);
@ -171,6 +236,7 @@ template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
else if (type == YON_CONFIG_BOTH)
yon_ubl_status_box_render(GLOBAL_LOCAL_SAVE_SUCCESS_LABEL,BACKGROUND_IMAGE_SUCCESS_TYPE);
textdomain(template_app_information.app_locale);
return NULL;
} else {
char *config_to_save = NULL;
if (type==YON_CONFIG_GLOBAL) config_to_save="global";
@ -182,7 +248,6 @@ template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
config_to_save="system";
}
}
yon_config_set_status(0);
config_str config_compare=NULL;
int compare_size=0;
va_list args;
@ -243,6 +308,10 @@ template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
window->CancelButton = yon_gtk_builder_get_widget(builder,"CancelButton");
window->ToggleCell = GTK_CELL_RENDERER(gtk_builder_get_object(builder,"ToggleCell"));
window->list = GTK_LIST_STORE(gtk_builder_get_object(builder,"liststore1"));
window->OldValueColumn = GTK_TREE_VIEW_COLUMN(gtk_builder_get_object(builder,"OldValueColumn"));
window->OldValueCell = GTK_CELL_RENDERER(gtk_builder_get_object(builder,"OldValueCell"));
window->NewValueColumn = GTK_TREE_VIEW_COLUMN(gtk_builder_get_object(builder,"NewValueColumn"));
window->NewValueCell = GTK_CELL_RENDERER(gtk_builder_get_object(builder,"NewValueCell"));
window->type=type;
window->filteredModel = GTK_TREE_MODEL(gtk_builder_get_object(builder,"listfilter1"));
gtk_tree_model_filter_set_visible_column(GTK_TREE_MODEL_FILTER(window->filteredModel),5);
@ -255,6 +324,8 @@ template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
g_signal_connect(G_OBJECT(window->CancelButton),"clicked",G_CALLBACK(on_subwindow_close),NULL);
g_signal_connect(G_OBJECT(window->SaveButton),"clicked", G_CALLBACK(on_save_parameters),window);
g_signal_connect(G_OBJECT(window->ToggleCell),"toggled", G_CALLBACK(on_save_window_parameter_switched),window);
// g_signal_connect(G_OBJECT(window->OldValueColumn),"notify::width",G_CALLBACK(on_column_resize),window->OldValueCell);
// g_signal_connect(G_OBJECT(window->NewValueColumn),"notify::width",G_CALLBACK(on_column_resize),window->NewValueCell);
int config_size=0;
config_str config_strings = yon_config_get_all(&config_size);
if (config_strings){
@ -305,22 +376,22 @@ template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
if (!yon_char_is_empty(name)&&!strcmp(name,config_keys[i])){
if (!yon_config_check_ignore(name)){
gtk_list_store_set(window->list,&iter,3,compare_value,4,NULL,6,section,-1);
if ((value&&!strcmp(value,compare_value))||yon_char_is_empty(compare_value)){
if ((value&&!strcmp(value,compare_value))){ //||yon_char_is_empty(compare_value)
gtk_list_store_set(window->list,&iter,0,0,3,value,5,0,-1);
} else {
gtk_list_store_set(window->list,&iter,5,1,-1);
gtk_list_store_set(window->list,&iter,0,1,5,1,-1);
}
} else {
printf ("%s ignored\n",name);
}
found=1;
break;
}
}
if (!found){
GtkTreeIter itar;
gtk_list_store_append(window->list,&itar);
gtk_list_store_set(window->list,&itar,0,1,1,compare_name,3,compare_value,5,1,6,section,-1);
if (!yon_config_check_ignore(compare_name)&&!yon_char_is_empty(compare_value)){
GtkTreeIter itar;
gtk_list_store_append(window->list,&itar);
gtk_list_store_set(window->list,&itar,0,1,1,compare_name,3,compare_value,5,1,6,section,-1);
}
}
free(compare_value);
free(compare_name);
@ -344,9 +415,14 @@ int yon_confirmation_dialog_call(GtkWidget *self,dialog_confirmation_data *data)
gtk_window_set_icon_name(GTK_WINDOW(dialog),yon_char_append("com.ublinux.",template_app_information.app_tech_name));
gtk_window_set_title(GTK_WINDOW(dialog),template_app_information.app_title);
gtk_widget_set_size_request(dialog,450,-1);
GList *list = gtk_container_get_children(GTK_CONTAINER(gtk_dialog_get_content_area(GTK_DIALOG(dialog))));
gtk_widget_set_margin_bottom((GtkWidget*)g_list_nth_data(list,g_list_length(list)-1),5);
gtk_widget_set_margin_end((GtkWidget*)g_list_nth_data(list,g_list_length(list)-1),5);
GList *list = gtk_container_get_children(GTK_CONTAINER(gtk_dialog_get_header_bar(GTK_DIALOG(dialog))));
GtkWidget *image_cancel = gtk_image_new_from_icon_name("com.ublinux.libublsettingsui-gtk3.cancel-symbolic",GTK_ICON_SIZE_BUTTON);
GtkWidget *image_accept = gtk_image_new_from_icon_name("com.ublinux.libublsettingsui-gtk3.accept-symbolic",GTK_ICON_SIZE_BUTTON);
gtk_button_set_image((GtkButton*)g_list_nth_data(list,0),image_cancel);
gtk_button_set_image((GtkButton*)g_list_nth_data(list,1),image_accept);
gtk_style_context_add_class(gtk_widget_get_style_context((GtkWidget*)g_list_nth_data(list,0)),"marginright");
gtk_style_context_add_class(gtk_widget_get_style_context((GtkWidget*)g_list_nth_data(list,1)),"marginright");
g_list_free(list);
GtkWidget *header_label = gtk_label_new(template_app_information.app_title);
gtk_widget_show(header_label);
@ -425,6 +501,7 @@ template_main_window *setup_window(){
widgets->InterfaceBox = yon_gtk_builder_get_widget(builder,"InterfaceBox");
GtkWidget *HatIcon = yon_gtk_builder_get_widget(builder,"HatIcon");
GtkWidget *HeadImage = yon_gtk_builder_get_widget(builder,"HeadImage");
GtkWidget *ModeStatusImage = yon_gtk_builder_get_widget(builder,"ModeStatusImage");
widgets->DocumentationMenuItem = yon_ubl_menu_item_documentation_new(DOCUMENTATION_LABEL);
widgets->AboutMenuItem = yon_ubl_menu_item_about_new(ABOUT_LABEL);
@ -449,7 +526,36 @@ template_main_window *setup_window(){
g_signal_connect(G_OBJECT(widgets->DocumentationMenuItem),"activate",G_CALLBACK(on_open_documentation_confirmation),template_app_information.wiki_link);
g_signal_connect(G_OBJECT(widgets->AboutMenuItem),"activate",G_CALLBACK(on_about),NULL);
if (yon_char_is_empty(__yon_config_mode)){
int size;
config_str cnf = yon_config_load(SAVE_MODE_GET_COMMAND,&size);
__yon_config_mode=yon_char_new(cnf[0]);
if (__yon_config_mode[strlen(__yon_config_mode)-1]=='\n') __yon_config_mode[strlen(__yon_config_mode)-1]='\0';
yon_char_parsed_free(cnf,size);
if (!yon_char_is_empty(__yon_config_mode)&&strcmp(__yon_config_mode,"(null)")){
gtk_image_set_from_pixbuf(GTK_IMAGE(ModeStatusImage),gtk_icon_theme_load_icon_for_scale(gtk_icon_theme_get_default(),yon_ubl_save_mode_get_icon_name(yon_ubl_save_mode_get_type(__yon_config_mode)),25,1,GTK_ICON_LOOKUP_FORCE_SIZE,NULL));
char *tooltip_text=NULL;
switch (yon_ubl_save_mode_get_type(__yon_config_mode)){
case SAVE_MODE_FULL: tooltip_text = SAVE_MODE_FULL_LABEL;
break;
case SAVE_MODE_MODULE: tooltip_text = SAVE_MODE_MODULE_LABEL;
break;
case SAVE_MODE_SANDBOX: tooltip_text = SAVE_MODE_SANDBOX_LABEL;
break;
case SAVE_MODE_RAM_HOME: tooltip_text = SAVE_MODE_RAM_HOME_LABEL;
break;
case SAVE_MODE_HDD: tooltip_text = SAVE_MODE_HDD_LABEL;
break;
case SAVE_MODE_HDD_HOME: tooltip_text = SAVE_MODE_HDD_HOME_LABEL;
break;
}
gtk_widget_set_tooltip_text(ModeStatusImage,tooltip_text);
} else {
free(__yon_config_mode);
__yon_config_mode=NULL;
gtk_widget_hide(ModeStatusImage);
}
}
gtk_widget_show(widgets->Window);
return widgets;
}

@ -9,8 +9,9 @@
#include <libintl.h>
#include <getopt.h>
#include <libintl.h>
#ifdef WEBKIT_INCLUDE
#include <webkit2/webkit2.h>
#endif
#define ui_WIKI_LINK "https://wiki.ublinux.ru/ru/Программное_обеспечениерограммы_и_утилиты/Все/ublsettingsui-gtk3"
#define _(String) gettext(String)
@ -64,8 +65,33 @@
#define PARAMETER_LABEL _("Parameter")
#define OLD_VALUE_LABEL _("Old value")
#define NEW_VALUE_LABEL _("New value")
#define SYSTEMBOOT_STATEMODE "SYSTEMBOOT_STATEMODE"
#define SYSTEMBOOT_STATEMODE_SECTION "[system]"
#define SAVE_MODE_FULL_LABEL _("Full saving mode")
#define SAVE_MODE_MODULE_LABEL _("Saving into module")
#define SAVE_MODE_SANDBOX_LABEL _("Sandbox mode")
#define SAVE_MODE_RAM_HOME_LABEL _("Sandbox with profile saving")
#define SAVE_MODE_HDD_LABEL _("HDD sandbox")
#define SAVE_MODE_HDD_HOME_LABEL _("HDD sandbox with profile saving")
#endif
#define SAVE_MODE_GET_COMMAND "ubconfig --raw --source system get [config] SYSTEMBOOT_STATEMODE"
typedef enum SAVE_MODE_TYPE {
SAVE_MODE_FULL,
SAVE_MODE_MODULE,
SAVE_MODE_SANDBOX,
SAVE_MODE_RAM_HOME,
SAVE_MODE_HDD,
SAVE_MODE_HDD_HOME,
} SAVE_MODE_TYPE;
char *yon_ubl_save_mode_get_icon_name(SAVE_MODE_TYPE type);
SAVE_MODE_TYPE yon_ubl_save_mode_get_type(char *type);
typedef struct {
GtkWidget *interface;
@ -151,6 +177,10 @@ typedef struct {
GtkWidget *SaveButton;
GtkListStore *list;
GtkTreeModel *filteredModel;
GtkTreeViewColumn *OldValueColumn;
GtkCellRenderer *OldValueCell;
GtkTreeViewColumn *NewValueColumn;
GtkCellRenderer *NewValueCell;
YON_CONFIG_TYPE type;
} template_saving_window;

Loading…
Cancel
Save