There are eventually corner cases where there's no user other than root in the system and control-center can be launched by the root user (not recommended). In this cases, the panel crashes without any user to show (since accountsservice would just list normal users). This patch introduces an empty state[0] "No Users Page". [0] https://wiki.gnome.org/Design/OS/EmptyStates https://bugzilla.gnome.org/show_bug.cgi?id=773673
522 lines
23 KiB
XML
522 lines
23 KiB
XML
<interface>
|
|
<!-- interface-requires gtk+ 3.8 -->
|
|
<!-- interface-naming-policy toplevel-contextual -->
|
|
<object class="GtkStack" id="headerbar-buttons">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<child>
|
|
<object class="GtkLockButton" id="lock-button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
</object>
|
|
<packing>
|
|
<property name="name">_lock</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="add-user-toolbutton">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="label" translatable="yes">_Add User…</property>
|
|
<property name="use_underline">True</property>
|
|
<style>
|
|
<class name="suggested-action"/>
|
|
</style>
|
|
</object>
|
|
<packing>
|
|
<property name="name">_adduser</property>
|
|
</packing>
|
|
</child>
|
|
</object>
|
|
<object class="GtkListStore" id="shortname-model">
|
|
<columns>
|
|
<!-- column-name gchararray -->
|
|
<column type="gchararray"/>
|
|
</columns>
|
|
</object>
|
|
<object class="GtkListStore" id="language-model">
|
|
<columns>
|
|
<!-- column-name gchararray -->
|
|
<column type="gchararray"/>
|
|
<!-- column-name gchararray1 -->
|
|
<column type="gchararray"/>
|
|
</columns>
|
|
</object>
|
|
|
|
<object class="GtkStack" id="stack">
|
|
<property name="visible">True</property>
|
|
<property name="visible-child">empty-state</property>
|
|
<child>
|
|
<object class="GtkOverlay" id="overlay">
|
|
<property name="visible">True</property>
|
|
<child type="overlay">
|
|
<object class="GtkRevealer" id="notification">
|
|
<property name="visible">True</property>
|
|
<property name="halign">GTK_ALIGN_CENTER</property>
|
|
<property name="valign">GTK_ALIGN_START</property>
|
|
<child>
|
|
<object class="GtkBox">
|
|
<property name="visible">True</property>
|
|
<property name="spacing">6</property>
|
|
<style>
|
|
<class name="app-notification"/>
|
|
</style>
|
|
<child>
|
|
<object class="GtkLabel">
|
|
<property name="visible">True</property>
|
|
<property name="wrap">True</property>
|
|
<property name="max_width_chars">30</property>
|
|
<property name="label" translatable="yes">Your session needs to be restarted for changes to take effect</property>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="restart-button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="valign">GTK_ALIGN_CENTER</property>
|
|
<property name="label" translatable="yes">Restart Now</property>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="dismiss-button">
|
|
<property name="visible">True</property>
|
|
<property name="valign">GTK_ALIGN_CENTER</property>
|
|
<style>
|
|
<class name="flat"/>
|
|
</style>
|
|
<child>
|
|
<object class="GtkImage">
|
|
<property name="visible">True</property>
|
|
<property name="icon_name">window-close-symbolic</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkVBox" id="accounts-vbox">
|
|
<property name="visible">True</property>
|
|
<property name="orientation">vertical</property>
|
|
<property name="border_width">0</property>
|
|
<child>
|
|
<object class="UmCarousel" id="carousel">
|
|
<property name="visible">True</property>
|
|
</object>
|
|
<packing>
|
|
<property name="fill">False</property>
|
|
<property name="expand">False</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkGrid" id="user-options">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<property name="column_spacing">10</property>
|
|
<property name="row_spacing">10</property>
|
|
<property name="margin_top">40</property>
|
|
<property name="halign">GTK_ALIGN_CENTER</property>
|
|
<property name="height_request">300</property>
|
|
<child>
|
|
<object class="GtkButton" id="account-fingerprint-button">
|
|
<property name="visible">True</property>
|
|
<property name="hexpand">True</property>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">1</property>
|
|
<property name="top_attach">5</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkBox" id="account-type-box">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<property name="sensitive">False</property>
|
|
<style>
|
|
<class name="linked"/>
|
|
</style>
|
|
<child>
|
|
<object class="GtkRadioButton" id="account-type-standard">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="label" translatable="yes">Standard</property>
|
|
<property name="draw_indicator">False</property>
|
|
<property name="hexpand">True</property>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkRadioButton" id="account-type-admin">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="label" translatable="yes">Administrator</property>
|
|
<property name="draw_indicator">False</property>
|
|
<property name="group">account-type-standard</property>
|
|
<property name="hexpand">True</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">1</property>
|
|
<property name="top_attach">1</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkLabel" id="account-type-label">
|
|
<property name="visible">True</property>
|
|
<property name="xalign">1</property>
|
|
<property name="label" translatable="yes">Account _Type</property>
|
|
<property name="use_underline">True</property>
|
|
<property name="mnemonic_widget">account-type-box</property>
|
|
<style>
|
|
<class name="dim-label"/>
|
|
</style>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">0</property>
|
|
<property name="top_attach">1</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkEntry" id="full-name-entry">
|
|
<property name="visible">True</property>
|
|
<property name="width-chars">30</property>
|
|
<property name="max-width-chars">30</property>
|
|
<property name="valign">GTK_ALIGN_CENTER</property>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">1</property>
|
|
<property name="top_attach">0</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkLabel" id="password-label">
|
|
<property name="visible">True</property>
|
|
<property name="xalign">1</property>
|
|
<property name="label" translatable="yes">_Password</property>
|
|
<property name="use_underline">True</property>
|
|
<property name="mnemonic_widget">account-password-button</property>
|
|
<style>
|
|
<class name="dim-label"/>
|
|
</style>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">0</property>
|
|
<property name="top_attach">3</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="account-password-button">
|
|
<property name="visible">True</property>
|
|
<property name="hexpand">True</property>
|
|
<style>
|
|
<class name="text-button"/>
|
|
</style>
|
|
<child>
|
|
<object class="GtkLabel" id="account-password-button-label">
|
|
<property name="visible">True</property>
|
|
<property name="halign">GTK_ALIGN_START</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">1</property>
|
|
<property name="top_attach">3</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkLabel" id="autologin-label">
|
|
<property name="visible">True</property>
|
|
<property name="xalign">1</property>
|
|
<property name="label" translatable="yes">A_utomatic Login</property>
|
|
<property name="use_underline">True</property>
|
|
<property name="mnemonic_widget">autologin-switch</property>
|
|
<style>
|
|
<class name="dim-label"/>
|
|
</style>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">0</property>
|
|
<property name="top_attach">4</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkBox" id="autologin-box">
|
|
<property name="visible">True</property>
|
|
<property name="orientation">GTK_ORIENTATION_HORIZONTAL</property>
|
|
<child>
|
|
<object class="GtkSwitch" id="autologin-switch">
|
|
<property name="visible">True</property>
|
|
<property name="valign">GTK_ALIGN_CENTER</property>
|
|
</object>
|
|
<packing>
|
|
<property name="expand">False</property>
|
|
<property name="fill">False</property>
|
|
<property name="position">0</property>
|
|
</packing>
|
|
</child>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">1</property>
|
|
<property name="top_attach">4</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkLabel" id="account-fingerprint-label">
|
|
<property name="visible">True</property>
|
|
<property name="xalign">1</property>
|
|
<property name="label" translatable="yes">_Fingerprint Login</property>
|
|
<property name="use_underline">True</property>
|
|
<property name="mnemonic_widget">account-fingerprint-button</property>
|
|
<style>
|
|
<class name="dim-label"/>
|
|
</style>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">0</property>
|
|
<property name="top_attach">5</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkStack" id="user-icon">
|
|
<property name="visible">True</property>
|
|
<property name="halign">GTK_ALIGN_END</property>
|
|
<child>
|
|
<object class="UmUserImage" id="user-icon-image">
|
|
<property name="visible">True</property>
|
|
<property name="icon_name">avatar-default</property>
|
|
<property name="pixel_size">92</property>
|
|
<property name="halign">GTK_ALIGN_END</property>
|
|
<child internal-child="accessible">
|
|
<object class="AtkObject" id="user-icon-image-a11y">
|
|
<property name="accessible-name" translatable="yes">User Icon</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkToggleButton" id="user-icon-button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="receives_default">True</property>
|
|
<property name="relief">GTK_RELIEF_NORMAL</property>
|
|
<child internal-child="accessible">
|
|
<object class="AtkObject" id="user-icon-image2-a11y">
|
|
<property name="accessible-name" translatable="yes">User Icon</property>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="UmUserImage" id="user-icon-image2">
|
|
<property name="visible">True</property>
|
|
<property name="icon_name">avatar-default</property>
|
|
<property name="pixel_size">92</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">0</property>
|
|
<property name="top_attach">0</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkLabel" id="language-label">
|
|
<property name="visible">True</property>
|
|
<property name="xalign">1</property>
|
|
<property name="label" translatable="yes">_Language</property>
|
|
<property name="use_underline">True</property>
|
|
<property name="mnemonic_widget">account-language-button</property>
|
|
<style>
|
|
<class name="dim-label"/>
|
|
</style>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">0</property>
|
|
<property name="top_attach">2</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="account-language-button">
|
|
<property name="visible">True</property>
|
|
<property name="hexpand">True</property>
|
|
<style>
|
|
<class name="text-button"/>
|
|
</style>
|
|
<child>
|
|
<object class="GtkLabel" id="account-language-button-label">
|
|
<property name="visible">True</property>
|
|
<property name="halign">GTK_ALIGN_START</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">1</property>
|
|
<property name="top_attach">2</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkLabel" id="last-login-label">
|
|
<property name="visible">True</property>
|
|
<property name="xalign">1</property>
|
|
<property name="label" translatable="yes">Last Login</property>
|
|
<property name="use_underline">True</property>
|
|
<property name="mnemonic_widget">last-login-button</property>
|
|
<style>
|
|
<class name="dim-label"/>
|
|
</style>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">0</property>
|
|
<property name="top_attach">6</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="last-login-button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="receives_default">True</property>
|
|
<style>
|
|
<class name="text-button"/>
|
|
</style>
|
|
<child>
|
|
<object class="GtkLabel" id="last-login-button-label">
|
|
<property name="visible">True</property>
|
|
<property name="halign">GTK_ALIGN_START</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
<packing>
|
|
<property name="left_attach">1</property>
|
|
<property name="top_attach">6</property>
|
|
<property name="width">1</property>
|
|
<property name="height">1</property>
|
|
</packing>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="remove-user-toolbutton">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<property name="halign">GTK_ALIGN_END</property>
|
|
<property name="valign">GTK_ALIGN_END</property>
|
|
<property name="margin_bottom">20</property>
|
|
<property name="margin_top">20</property>
|
|
<property name="margin_end">20</property>
|
|
<property name="label" translatable="yes">Remove User…</property>
|
|
<style>
|
|
<class name="destructive-action"/>
|
|
</style>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
<packing>
|
|
<property name="name">_users</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkBox" id="empty-state">
|
|
<property name="visible">True</property>
|
|
<property name="orientation">GTK_ORIENTATION_VERTICAL</property>
|
|
<property name="valign">GTK_ALIGN_CENTER</property>
|
|
<property name="spacing">12</property>
|
|
<style>
|
|
<class name="dim-label"/>
|
|
</style>
|
|
<child>
|
|
<object class="GtkImage">
|
|
<property name="visible">True</property>
|
|
<property name="icon_name">avatar-default-symbolic</property>
|
|
<property name="pixel_size">192</property>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkLabel">
|
|
<property name="visible">True</property>
|
|
<property name="label" translatable="yes" comments="Translators: This is the empty state page label which states that there are no users to show in the panel.">No Users Found</property>
|
|
<attributes>
|
|
<attribute name="weight" value="bold"/>
|
|
<attribute name="scale" value="1.6"/>
|
|
</attributes>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkLabel">
|
|
<property name="visible">True</property>
|
|
<property name="label" translatable="yes">Unlock to add a user account.</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
<packing>
|
|
<property name="name">_empty_state</property>
|
|
</packing>
|
|
</child>
|
|
</object>
|
|
|
|
<object class="GtkSizeGroup" id="user-icon-sizegroup">
|
|
<property name="mode">both</property>
|
|
<widgets>
|
|
<widget name="user-icon-button"/>
|
|
<widget name="user-icon-image"/>
|
|
</widgets>
|
|
</object>
|
|
<object class="GtkSizeGroup" id="label-sizegroup">
|
|
<property name="mode">both</property>
|
|
<widgets>
|
|
<widget name="account-fingerprint-label"/>
|
|
<widget name="language-label"/>
|
|
<widget name="password-label"/>
|
|
<widget name="account-type-label"/>
|
|
<widget name="autologin-label"/>
|
|
<widget name="last-login-label"/>
|
|
</widgets>
|
|
</object>
|
|
<object class="GtkSizeGroup" id="option-sizegroup">
|
|
<property name="mode">both</property>
|
|
<widgets>
|
|
<widget name="account-fingerprint-button"/>
|
|
<widget name="account-language-button"/>
|
|
<widget name="account-password-button"/>
|
|
<widget name="account-type-box"/>
|
|
<widget name="autologin-box"/>
|
|
<widget name="last-login-button"/>
|
|
</widgets>
|
|
</object>
|
|
<object class="GtkSizeGroup">
|
|
<property name="mode">both</property>
|
|
<widgets>
|
|
<widget name="account-type-standard"/>
|
|
<widget name="account-type-admin"/>
|
|
</widgets>
|
|
</object>
|
|
</interface>
|