Consider this snippet:

     app = dabo.dApp()
     app.BasePrefKey = 'myapp'
     app.MainFormClass = mainTest
     app.start()

At start the app warns (four times!) that there wasn't a BasePrefKey  
set and constructs one from the file's path.
That would be fine if I hadn't set BasePrefKey explicitely.

I mostly use my own Application class in this way and don't want to  
inherit it for every small tool just to set BasePrefKey in its  
afterInit.


I found in dApp.py that I should be able to set BasePrefKey in my  
MainForm, but that doesn't seem to work, at least not like this:


class mainTest(dabo.ui.dForm):
     def afterInit(self):
         if not hasattr(self.Application, 'BasePrefKey'):
             self.BasePrefKey = 'myapp'
        ...

If I just set self.BasePrefKey (in mainTest.afterInit), I get the  
warning "only" three times, but the app's BasePrefKey isn't changed  
(i.e. ignored by PreferenceManager).
The same with self.Application.BasePrefKey


Would it be possible to change dabo's handling of BasePrefKey, so that  
it's possible to set it directly on the app object?



Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net
https://www.cacert.org (I'm an assurer)




_______________________________________________
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/53179195-8fa7-4a71-9631-74fbb94c0...@fiee.net

Reply via email to