73 Commits

Author SHA1 Message Date
alfrix
08a3d8a798 split printer init for faster response 2024-01-02 23:34:30 -03:00
alfrix
105813490b splash: add confirmation for host reboot 2024-01-02 17:01:55 -03:00
alfrix
6cf639c083 refactor widget creation
improves performance and makes the code cleaner

* add parameters instead of calling methods afterwards
* remove a a lot of size requests
* remove parameters that are being set to the default value
* simplify dialogs containers
2024-01-02 08:14:51 -03:00
alfrix
6f32cdacbe layout: fix issues 2023-10-13 23:24:03 -03:00
alfrix
35007af482 system and splash: add ignore inhibitors to reboot and shutdown 2023-08-18 11:48:37 -03:00
alfrix
bd98e758ec base_panel improvements
* generalize macro shortcut to allow changing it in the future
* action_bar functionality is now handled in one place for better maintainability
2023-08-18 11:48:37 -03:00
alfrix
8d9236a2df screen: simplify panel loading
this removes create_panel function from panels and mandates a class name Panel

remove panel_type param and only use a panel_name that is it's filename

remove load_panel dict

always reinit panel, (simpler and safer but slower)
2023-07-30 12:22:58 -03:00
alfrix
74338a7f3e splash: fix power_device appearing if configured in ks.conf but not available in the server 2022-12-11 09:20:06 -03:00
alfrix
70d7564a78 shorten _screen.printer to _printer 2022-12-11 09:17:18 -03:00
alfrix
7120c424d4 gtk: resizability
doesn't rescale the fonts or images
2022-12-11 09:17:18 -03:00
alfrix
06bf269862 feat: turn on_off power devices with the screensaver close #518 2022-12-05 12:31:44 -03:00
alfrix
d161c3f1e4 splash_screen: use initialized for klipper restart buttons 2022-11-30 11:00:10 -03:00
alfrix
20346a90dc splash_screen: tweak layout sizes and remove get_allocation that can cause isssues
fixes #813

gtk: fix content_width while vertical returning 0
2022-11-26 15:57:50 -03:00
alfrix
593d8c678b gtk: merge buttonimage and button 2022-11-22 14:55:42 -03:00
alfrix
0233327554 fix splash_screen reloading and limit klipper reconnects fixes #803 2022-11-22 14:55:42 -03:00
alfrix
d0d79a64df base_panel: simplify action bar buttons enable-disable 2022-11-21 09:20:05 -03:00
alfrix
818f1ab465 splash_screen: show detailed error when moonraker connection fails 2022-11-21 07:15:02 -03:00
alfrix
dbd1474d63 screen_panel: share ks_printer_cfg between panels 2022-11-20 14:17:48 -03:00
alfrix
fc0f153023 reorder imports 2022-11-20 07:28:05 -03:00
alfrix
7ca37c56b6 websocket: refactor how the connection is handled 2022-11-18 12:56:05 -03:00
alfrix
45ab86204b panels: remove initialize from the panels that do not have a menu 2022-11-18 00:53:53 -03:00
alfrix
b68cfa40fd refactor ws reconnect/retry 2022-11-18 00:53:53 -03:00
alfrix
fdf13102fe screen: remove shutdown variable and change on_close to disconnect 2022-11-18 00:53:53 -03:00
alfrix
8b55d2f2b1 splash_screen: limit reconnections, clear log, add reconnect button 2022-11-11 10:25:55 -03:00
alfrix
38d006c8a7 job_status and splash: fixup image size on ultrawide 2022-11-02 11:13:16 -03:00
alfrix
371968b458 base_panel: hide estop 2022-11-01 15:36:52 -03:00
alfrix
c3128ef508 base_panel: always hide macro shortcut on splash_screen 2022-11-01 15:36:49 -03:00
alfrix
d3281379ee gtk: change scaling of images
This reduces the amount of magic numbers used, some images will scale to bigger sizes, most of the icons and images in vertical mode will be bigger, thumbnails should be bigger in both modes.
2022-10-26 22:36:52 -03:00
alfrix
4f959696bd gtk: remove newlines to properly wrap lines if needed
this fixes the issue caused by labels with a newlines detected as 1 line even if it has more than one
2022-09-02 19:58:35 -03:00
alfrix
6510b2ec6b Refactor
Use f-strings
Avoid unnecessary casts to str()bool()int()
Ensure file closure
Merge nested ifs
Simplify for-assigns-appends with comprehensions and internal functions
Avoid shadowing internal function names
Initialize variables
Return value directly instead of assign then return
Make some methods static
2022-08-01 12:23:40 -03:00
alfrix
5ad82a64d4 Translations: install _() 2022-07-03 12:03:50 -03:00
alfrix
da26bf3143 base_panel: layout simplification 2022-07-03 12:03:50 -03:00
alfrix
5a36729b76 PEP8, typos and warnings fixes 2022-05-31 11:14:42 -03:00
alfrix
ea3e7ad3d1 splash_screen: use moonraker for actions if connected, hide system panel if it isn't connected
use systemctl if moonraker isn't available close #615
2022-05-31 11:14:42 -03:00
alfrix
c33659c6f7 gtk: cleanup andoptimize image handling, incomplete themes should now work 2022-04-02 09:59:12 -03:00
alfrix
76b7ad54eb splash: do not show power_on if moonraker is not connected 2022-03-31 13:47:42 -03:00
alfrix
5eac3bef6b Update Translations 2022-03-31 11:26:25 -03:00
alfrix
6f86448405 Fix issues while Moonraker is connected but klipper is disconnected
fixes #548
2022-03-28 16:47:52 -03:00
alfrix
4c8bb4ff6f splash_screen: change klipper restart and firmware restart if klipper is not connected 2022-03-25 14:07:37 -03:00
alfrix
b83f12265d Splash_screen: fix return and duplicated power devices
fix forcefully returning the user from menu to splash when there is no connection to moonraker/klipper
fix a case where the power device was added multiple times to the list
2022-03-24 10:34:27 -03:00
alfrix
1dee914564 splash_screen: fix bug that prevented Power On from showing up 2022-03-21 05:46:14 -03:00
Alfredo Monclus
046e03b883
Improve error messages (#549)
Shows if the issue is with moonraker or klipper
if the issue is with klipper and there is info about it then show it
Reconnect now has a counter and it's visible to the user
2022-03-18 20:18:53 -03:00
alfrix
5899c8feab Optimize imports 2022-03-15 12:41:21 -03:00
alfrix
490dc929bd splash_screen: make power_devices mandatory for the power on button 2022-03-10 11:26:43 -03:00
alfrix
088a6deabd splash_screen: allow power_devices to be configured 2022-03-05 11:33:24 -03:00
alfrix
49ab84e8d5 splash_screen: implement Power On Printer but make it more specific 2022-03-01 17:21:17 -03:00
alfrix
7e9fc97b4b splash_screen: fix #521 2022-03-01 09:10:05 -03:00
Jordan
4b0b937c41 Change scrolling behavior to enable touch scroll. Fix #466 2022-01-22 15:30:02 -05:00
Alfredo Monclus
9449f24b5f
Splash_screen: show full error message (#389)
* Splash_screen: show full error messge

* Fix splash not changing from connecting to error
2022-01-03 01:29:49 -05:00
d8ahazard
6c3c579e6e
Support multiple power devices. (#350)
Enable multiple devices to power on when turning on printer. Devices starting with "Printer" will turn on
2021-12-24 09:31:01 -05:00