]> git.pld-linux.org Git - packages/cinnamon.git/blob - set_wheel.patch
- updated to 5.8.2 (translations 5.8.1)
[packages/cinnamon.git] / set_wheel.patch
1 --- cinnamon-5.8.1/files/usr/share/cinnamon/cinnamon-settings-users/cinnamon-settings-users.py.orig     2023-06-08 13:57:26.000000000 +0200
2 +++ cinnamon-5.8.1/files/usr/share/cinnamon/cinnamon-settings-users/cinnamon-settings-users.py  2023-06-14 06:23:45.924341829 +0200
3 @@ -182,12 +182,11 @@ class EditableEntry (Gtk.Notebook):
4  
5  class PasswordDialog(Gtk.Dialog):
6  
7 -    def __init__ (self, user, password_mask, group_mask, parent = None):
8 +    def __init__ (self, user, password_mask, parent = None):
9          super(PasswordDialog, self).__init__(None, parent)
10  
11          self.user = user
12          self.password_mask = password_mask
13 -        self.group_mask = group_mask
14  
15          self.set_modal(True)
16          self.set_skip_taskbar_hint(True)
17 @@ -253,14 +252,7 @@ class PasswordDialog(Gtk.Dialog):
18      def change_password(self):
19          newpass = self.new_password.get_text()
20          self.user.set_password(newpass, "")
21 -        mask = self.group_mask.get_text()
22 -        if "nopasswdlogin" in mask:
23 -            subprocess.call(["gpasswd", "-d", self.user.get_user_name(), "nopasswdlogin"])
24 -            mask = mask.split(", ")
25 -            mask.remove("nopasswdlogin")
26 -            mask = ", ".join(mask)
27 -            self.group_mask.set_text(mask)
28 -            self.password_mask.set_text('\u2022\u2022\u2022\u2022\u2022\u2022')
29 +        self.password_mask.set_text(u'\u2022\u2022\u2022\u2022\u2022\u2022')
30          self.destroy()
31  
32      def set_passwords_visibility(self):
33 @@ -613,7 +605,7 @@ class Module:
34          model, treeiter = self.users_treeview.get_selection().get_selected()
35          if treeiter is not None:
36              user = model[treeiter][INDEX_USER_OBJECT]
37 -            dialog = PasswordDialog(user, self.password_mask, self.groups_label, self.window)
38 +            dialog = PasswordDialog(user, self.password_mask, self.window)
39              response = dialog.run()
40  
41      def _on_groups_button_clicked(self, widget):
42 @@ -899,11 +891,11 @@ class Module:
43              pixbuf = GdkPixbuf.Pixbuf.new_from_file_at_size("/usr/share/cinnamon/faces/user-generic.png", 48, 48)
44              description = "<b>%s</b>\n%s" % (fullname, username)
45              piter = self.users.append(None, [new_user, pixbuf, description])
46 -            # Add the user to his/her own group and sudo if Administrator was selected
47 +            # Add the user to his/her own group and wheel if Administrator was selected
48              if dialog.account_type_combo.get_active() == 1:
49 -                subprocess.call(["usermod", username, "-G", "%s,sudo,nopasswdlogin" % username])
50 +                subprocess.call(["usermod", username, "-G", "%s,wheel" % username])
51              else:
52 -                subprocess.call(["usermod", username, "-G", "%s,nopasswdlogin" % username])
53 +                subprocess.call(["usermod", username, "-G", "%s" % username])
54              self.load_groups()
55          dialog.destroy()
56  
This page took 0.162197 seconds and 4 git commands to generate.