Re: [Tails-dev] feature/liveusb_ui_improvement followups

Nachricht löschen

Nachricht beantworten
Autor: Alan
Datum:  
To: tails-dev
Alte Treads: Re: [Tails-dev] Please review and merge feature/liveusb_ui_improvement
Betreff: Re: [Tails-dev] feature/liveusb_ui_improvement followups
Hi,

On Thu, 17 Oct 2013 14:18:36 +0000 Alan <alan@???> wrote:
>
> On Sat, 12 Oct 2013 09:36:52 +0200 intrigeri <intrigeri@???>
> wrote:
> > Alan wrote (11 Oct 2013 17:52:19 GMT) :
> > >> Just curious: any specific reason that I've missed to display the
> > >> device size in the confirmation dialog on initial install, but
> > >> not at upgrade time?
> > >>
> > > No.
> >
> > Do you intend to fix this (say, in time for 0.22), or should I?
> >
> I'll do it in time for 0.22.
>

Actually, there was a reason: at the time the dialog is shown, the
installer switched (`switch_drive_to_system_partition`) its device from
the disk (/dev/sdb) to the partition (/dev/sdb1) with the method
`switch_drive_to_system_partition` and `drive['size']` contains the
size of the partition, which doesn't contain relevant information.

Fixed, but it required quite some code.

> > >> > +def _format_bytes(value):
> > >> > +    return '%0.1f GB' % (value / 10.0**9)

> > >>
> > >> I appreciate the minor refactoring, but then I'd rather:
> > >>
> > >> * either use some library to display human-readable units in
> > >> all cases (think: 2TB external drive) to improve UX
> > >> * or simply rename the function to _format_bytes_in_GB, so that
> > >> at least the name expresses its current limitations.
> > >>
> > > I would choose the 2nd for now.
> >
> > Do you intend to fix this (say, in time for 0.22), or should I?
>
> I'll.


Done

> > >> However, the No/Yes buttons ordering seems unusual to me. I
> > >> didn't dare patching it, as I thought you might have followed
> > >> the GNOME HIG or something, and I may be missing something. Any
> > >> reason to order it this way?
> > >>
> > > No. I'm used to GTK+, which chooses the right order automatically.
> > > Qt might not do that.
> >
> > Do you intend to fix this (say, in time for 0.22), or should I?
> >
> I'll too.
>

I just tested and got the same button ordering than (GTK) `zenity
--question`, so I belive there is no problem to be solved.

Everything is in liveusb's feature/ui_improvement_followups branch.
Expect a tails branch including it soon.

Cheers