Codebase list lightdm-gtk-greeter-settings / 03bde4d
Multihead setup: "empty" page can have unresponsible "available" button at first run, error when open dialog with no monitors Andrew P. 9 years ago
2 changed file(s) with 40 addition(s) and 36 deletion(s). Raw diff Collapse all Expand all
11 <!-- Generated with glade 3.18.3 -->
22 <interface>
33 <requires lib="gtk+" version="3.8"/>
4 <requires lib="*MultiheadSetupDialog (copy 2).ui" version="0.0"/>
5 <requires lib="gtk_greeter_settings" version="1.0"/>
4 <!-- interface-requires gtk_greeter_settings 1.0 -->
65 <object class="GtkMenu" id="available_menu">
76 <property name="visible">True</property>
87 <property name="can_focus">False</property>
4544 <property name="margin_bottom">8</property>
4645 <property name="orientation">vertical</property>
4746 <property name="spacing">8</property>
48 <child internal-child="action_area">
49 <object class="GtkButtonBox" id="dialog-action_area">
50 <property name="can_focus">False</property>
51 <property name="layout_style">end</property>
52 <child>
53 <object class="GtkButton" id="ok_button">
54 <property name="label" translatable="yes" context="button">_OK</property>
55 <property name="visible">True</property>
56 <property name="can_focus">True</property>
57 <property name="can_default">True</property>
58 <property name="has_default">True</property>
59 <property name="receives_default">True</property>
60 <property name="image">image3</property>
61 <property name="use_underline">True</property>
62 </object>
63 <packing>
64 <property name="expand">False</property>
65 <property name="fill">True</property>
66 <property name="position">1</property>
67 </packing>
68 </child>
69 </object>
70 <packing>
71 <property name="expand">False</property>
72 <property name="fill">True</property>
73 <property name="pack_type">end</property>
74 <property name="position">0</property>
75 </packing>
76 </child>
7747 <child>
7848 <object class="GtkNotebook" id="monitors_notebook">
7949 <property name="visible">True</property>
8454 <signal name="switch-page" handler="on_switch_page" swapped="no"/>
8555 <child>
8656 <object class="GtkBox" id="empty_page">
87 <property name="visible">True</property>
8857 <property name="can_focus">False</property>
8958 <property name="orientation">vertical</property>
9059 <child>
329298 <packing>
330299 <property name="left_attach">0</property>
331300 <property name="top_attach">0</property>
301 <property name="width">1</property>
302 <property name="height">1</property>
332303 </packing>
333304 </child>
334305 <child>
345316 <packing>
346317 <property name="left_attach">0</property>
347318 <property name="top_attach">1</property>
319 <property name="width">1</property>
320 <property name="height">1</property>
348321 </packing>
349322 </child>
350323 <child>
359332 <packing>
360333 <property name="left_attach">1</property>
361334 <property name="top_attach">0</property>
335 <property name="width">1</property>
336 <property name="height">1</property>
362337 </packing>
363338 </child>
364339 <child>
372347 <packing>
373348 <property name="left_attach">1</property>
374349 <property name="top_attach">1</property>
350 <property name="width">1</property>
351 <property name="height">1</property>
375352 </packing>
376353 </child>
377354 </object>
516493 <packing>
517494 <property name="expand">False</property>
518495 <property name="fill">True</property>
496 <property name="position">0</property>
497 </packing>
498 </child>
499 <child internal-child="action_area">
500 <object class="GtkButtonBox" id="dialog-action_area">
501 <property name="can_focus">False</property>
502 <property name="layout_style">end</property>
503 <child>
504 <object class="GtkButton" id="ok_button">
505 <property name="label" translatable="yes" context="button">_OK</property>
506 <property name="visible">True</property>
507 <property name="can_focus">True</property>
508 <property name="can_default">True</property>
509 <property name="has_default">True</property>
510 <property name="receives_default">True</property>
511 <property name="image">image3</property>
512 <property name="use_underline">True</property>
513 </object>
514 <packing>
515 <property name="expand">False</property>
516 <property name="fill">True</property>
517 <property name="position">1</property>
518 </packing>
519 </child>
520 </object>
521 <packing>
522 <property name="expand">False</property>
523 <property name="fill">True</property>
524 <property name="pack_type">end</property>
519525 <property name="position">0</property>
520526 </packing>
521527 </child>
3939 super().__init__(widgets)
4040 self._widgets = helpers.WidgetsWrapper(widgets)
4141 self._groups = []
42 self._adapters = None
42 self._adapters = {key: OptionGroup.OneToManyEntryAdapter()
43 for key, __ in self.EntriesSetup}
4344 self._dialog = None
4445
4546 self._groups_wrapper = helpers.SimpleDictWrapper(
5758 for groupname in config:
5859 if not groupname.startswith(MonitorsGroup.GroupPrefix):
5960 continue
60 if not self._adapters:
61 self._adapters = {key: OptionGroup.OneToManyEntryAdapter()
62 for key, __ in self.EntriesSetup}
6361
6462 monitor = groupname[len(MonitorsGroup.GroupPrefix):].strip()
6563 self._add_group(monitor, groupname, config)