[nvda] Re: revision 258-259 - revert to saved configuration and key echo bug fix

Hi Mick,
Michael Curran wrote:
Also all parts of NVDA import all of config rather than just conf, for the reason that when it is reloaded, all the references to conf will be wrong. The only way to get around this would be to have a way to reload the config file in to the configObj itself.
Ack. That's a bit annoying - I didn't think of that. We could define a class which holds the ConfigObj and just passes all methods through to that. That way, we'd just have to change the reference to the ConfigObj in that class. However, I really don't think it's worth it and it's a bit hackish.

*Fixed a bug in isTypingProtected where it would cause an exception if NVDA has just started and the focus hasn't been set yet.
Ah. I was going to report that bug if I couldn't track it down myself. Thanks for fixing.

Jamie, I Spent like an hour trying to work out why the configuration was being completely bruitalised after a reload with applyConfiguration. Everything turned in to strings, and all the comments and blank lines went missing from nvda.ini. It would be nice if configObj supported the confspec as a normal string... well, all solved with a seek to 0 on confspec. :)
Damn! Oops. :) I guess I didn't consider the possibility of the config being reloaded when I wrote that code, so didn't think of seeking to 0. Nasty. That would have frustrated the hell out of me for ages too, I suspect. It's so easy to miss the really obvious (or at least, really easy) things.

Jamie

--
James Teh
Email: jamie@xxxxxxxxxxx
WWW: http://www.jantrid.net/
MSN Messenger: jamie@xxxxxxxxxxx
Jabber: jteh@xxxxxxxxxx
Yahoo: jcs_teh
To post messages to the list send email to
nvda@xxxxxxxxxxxxx
To unsubscribe from the list send a blank message to:
nvda-request@xxxxxxxxxxxxx
with 'unsubscribe' in the Subject field.
Thank you for your continued support of Nonvisual Desktop Access, an open 
source free screen reader for Microsoft Windows:
http://www.kulgan.net/nvda/

Other related posts: