[master] [PATCH] Do not remove the layout if it was added back (#865830)
Vratislav Podzimek
vpodzime at redhat.com
Tue Oct 16 07:29:48 UTC 2012
On Mon, 2012-10-15 at 16:32 -0400, Chris Lumens wrote:
> > diff --git a/pyanaconda/ui/gui/spokes/keyboard.py b/pyanaconda/ui/gui/spokes/keyboard.py
> > index 3dce1d7..fd9e6ab 100644
> > --- a/pyanaconda/ui/gui/spokes/keyboard.py
> > +++ b/pyanaconda/ui/gui/spokes/keyboard.py
> > @@ -280,7 +280,8 @@ class KeyboardSpoke(NormalSpoke):
> >
> > if self._remove_last_attempt:
> > itr = self._store.get_iter_first()
> > - self._removeLayout(self._store, itr)
> > + if not self._store[itr][0] in dialog.chosen_layouts:
> > + self._removeLayout(self._store, itr)
> > self._remove_last_attempt = False
> >
> > def _run_add_from_removed(self, button):
>
> Looks fine, provided there's no way to get to this point where itr is
> None.
Yeah, I was thinking about it too. But that would mean we have no X
layout set which should never happen.
--
Vratislav Podzimek
Anaconda Rider | Red Hat, Inc. | Brno - Czech Republic
More information about the anaconda-patches
mailing list