Skip to content

Commit ab56644

Browse files
committed
Merge remote-tracking branch 'origin/pr/231'
* origin/pr/231: Show progress bar after loading CSS theme Pull request description: If the progress bar is shown before loading the application CSS theme, it looks like a graphical glitch for around 744ms on my HP Elitebook 820 system. Until the next call to `update_progress` and `Gtk.main_iteration_do` loop (picture below). But if the progress bar is shown and updated right after loading the CSS theme, it is much prettier. ![progress_bar2](https://github.com/user-attachments/assets/bd240f5e-39a5-453e-b5d4-24a6d3374622) ![progress_bar1](https://github.com/user-attachments/assets/e39539c7-37e2-4f22-af99-eacfc2416ce9)
2 parents 2b308a5 + 9a85256 commit ab56644

File tree

3 files changed

+4
-7
lines changed

3 files changed

+4
-7
lines changed

qubes_config/global_config/global_config.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -324,9 +324,6 @@ def perform_setup(self):
324324
"""
325325
The function that performs actual widget realization and setup.
326326
"""
327-
self.progress_bar_dialog.show()
328-
self.progress_bar_dialog.update_progress(0)
329-
330327
self.builder = Gtk.Builder()
331328
glade_ref = (importlib.resources.files('qubes_config') /
332329
'global_config.glade')
@@ -342,6 +339,9 @@ def perform_setup(self):
342339
light_file_name='qubes-global-config-light.css',
343340
dark_file_name='qubes-global-config-dark.css')
344341

342+
self.progress_bar_dialog.show_all()
343+
self.progress_bar_dialog.update_progress(0)
344+
345345
self.apply_button: Gtk.Button = self.builder.get_object('apply_button')
346346
self.cancel_button: Gtk.Button = \
347347
self.builder.get_object('cancel_button')

qubes_config/new_qube/new_qube_app.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -103,9 +103,6 @@ def perform_setup(self):
103103
The function that performs actual widget realization and setup. Should
104104
be only called once, in the main instance of this application.
105105
"""
106-
self.progress_bar_dialog.show()
107-
self.progress_bar_dialog.update_progress(0.1)
108-
109106
self.builder = Gtk.Builder()
110107
glade_ref = (importlib.resources.files('qubes_config') /
111108
'new_qube.glade')
@@ -122,6 +119,7 @@ def perform_setup(self):
122119
light_file_name='qubes-new-qube-light.css',
123120
dark_file_name='qubes-new-qube-dark.css')
124121

122+
self.progress_bar_dialog.show_all()
125123
self.progress_bar_dialog.update_progress(0.1)
126124

127125
self.template_handler = TemplateHandler(self.builder, self.qapp)

qubes_config/widgets/gtk_widgets.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -649,7 +649,6 @@ def __init__(self, parent_application: Gtk.Application, loading_text: str):
649649

650650
self.box.pack_start(self.progress_bar, False, False, 10)
651651

652-
self.show_all()
653652
self.update_progress(0)
654653

655654
self.connect('delete-event', self._quit)

0 commit comments

Comments
 (0)