[referencer] Cosmetic fix for file dialogue hiding
John Spray
jcspray at icculus.org
Tue Mar 20 10:46:14 EDT 2007
On Fri, 2007-03-16 at 09:48 +1000, Kai Willadsen wrote:
> Currently, file dialogues stick around while referencer is doing...
> stuff. This is most noticeable when you add a large directory of PDFs,
> and the file dialogue is still in the background while referencer
> scans the directory, looks up stuff, etc.
Sorry for delayed response, I'm very busy with the day-job at the
moment.
> The white space changes make the attached patch look much more
> invasive than it actually is. Basically, the patch changes instances
> of:
>
> if (chooser.run() == Gtk::RESPONSE_ACCEPT) {
> [do stuff]
> }
>
> to:
>
> if (chooser.run() == Gtk::RESPONSE_ACCEPT) {
> return;
> }
> chooser.hide ()
> [do stuff]
I think this can be accomplished more neatly by just putting the
chooser.hide() inside the if block at the start. Generally I prefer an
if (foo) {bar} to a if(!foo) {return} in terms of readability.
I don't really understand what the problem is with having the dialog
visible in the background, but hey, if it makes you happy it makes me
happy :-)
John
More information about the referencer
mailing list