diff --git a/src/core/controller.py b/src/core/controller.py index 805f07a..652b8a1 100644 --- a/src/core/controller.py +++ b/src/core/controller.py @@ -50,6 +50,8 @@ class Controller(ControllerData): for child in children: grid.remove(child) + row = 0 + col = 0 for item in group_items: title = item["title"] if not item["exec"] in ("", None): @@ -75,7 +77,14 @@ class Controller(ControllerData): button.set_always_show_image(True) button.show_all() - grid.add(button) + grid.attach(button, col, row, 1, 1) + + col += 1 + if col == 4: + col = 0 + row += 1 + + # grid.add(button) def test_exec(self, widget, _command): command = _command.split("%")[0] diff --git a/user_config/bin/utop b/user_config/bin/utop new file mode 100755 index 0000000..4cf5192 --- /dev/null +++ b/user_config/bin/utop @@ -0,0 +1,17 @@ +#!/bin/bash + +# . CONFIG.sh + +# set -o xtrace ## To debug scripts +# set -o errexit ## To exit on error +# set -o errunset ## To exit if a variable is referenced but not set + + +function main() { + call_path=`pwd` + cd "${call_path}" + echo "Working Dir: " $(pwd) + + python /opt/utop.zip "$@" +} +main "$@";