Adam Davison wrote: > But more concisely, replacing the XML parsing with another dynamic > structure made of Qt containers is actually conceptually worse, not > better. You aren't actually parsing XML anyway, you're traversing the > DOM tree, which is a well defined and sensible format for representing > a dynamic data structure in memory.
I didn't realize it could be used that way. Allright, fine. The only problem is that I need the XML to be processed somewhere other than in dlgprefmidibindings as it is currently, because I need the list of script files (from the XML) for the ScriptEngine, which needs to be created and live in other than the GUI thread. That's why I've just been trying to move XML processing code to its own class and get it out of dlgprefmidibindings. I understand it's not ideal, but I can't really make it so without completely rewriting dlgprefmidibindings to replace its QTableWidget with something that operates directly on the DOM tree. (Doesn't it need that anyway to display a table?) Or are you saying MidiMapping (or whatever we call it) should just open the XML file and just return references to DOM subtrees to objects that ask, then those objects will process the subtrees as needed internally? I.e. it's okay for dlgprefmidibindings to process its needed subtrees internally? > I would strongly recommend not committing any code that does this as I > think it just adds an extra step of complexity for no extra gain and > as we've learnt repeatedly in Mixxx, if you commit something half-way, > you're probably forcing future developers to deal with it for a long > time to come. Indeed. I've only committed midimapping.cpp/.h so you guys can look at them without breaking trunk with the other changes needed to use them. (Except trunk's SConscript might have midimapping.cpp in it.) If things keep going like this though, we'll probably need to branch. Adam: I only started all this to try to solve the crashing problem with MIDI script signals, which we (I think) agree is related to threading issues, since QtScript is not thread-safe. If I'm barking up the wrong tree here then please give me suggestions as to how to fix that problem! (See previous E-mail I sent you.) That's all I want right now! :) Sean <<--------------------------------------------------------------------------------->> This E-Mail message has been scanned for viruses and cleared by >>SmartMail<< from Smarter Technology, Inc. <<--------------------------------------------------------------------------------->> ------------------------------------------------------------------------------ This SF.net email is sponsored by: SourcForge Community SourceForge wants to tell your story. http://p.sf.net/sfu/sf-spreadtheword _______________________________________________ Mixxx-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/mixxx-devel
