[litwindow-users] NotifyChanged not causing update?
Status: Alpha
Brought to you by:
hajokirchhoff
From: yrs90 <yr...@ya...> - 2005-04-19 06:02:31
|
I used RapidUI with wxWizard as suggested. It worked great, even interfacing to the class data through member functions. Since the UI and data are updated without regard to whether the user cancels the action, I passed a new instance of the data structure to RapidUI. If the user "Finish"es the wizard, the data is copied into the real data structure. I presume that this is the expected usage pattern? After copying the wizard changes, I called NotifyChanged(g_data). Nothing happened. Not until I did an insert operation (which also triggers a NotifyChanged) did the UI update and show the changes introduced by the wizard. At first I thought that the NotifyChanged might be interacting with my local instance of RapidUI, wiz_mediator, instead of m_rapidUI, but none of the variations I've tried has yielded any updates. I even tried creating an accessor and using m_rapidUI->ValueChanged(..). (I used recursion=false, but I even tried naming the particular attribute that changed.) How do I convince RapidUI to reevaluate the rules? I also found myself asking these questions: Can NotifyChanged be called on any sub-element of the data structure? If I call NotifyChanged on some leaf of data will RapidUI know that a Rule referencing a branch containing the changed data needs to be reevaluated? By the way, the rule that I am expecting to update is of the form: RULE("ID_FRAME.Title", make_const<wxString>("MyProg: ") + make_expr<wxString>("Name")) where Name resolves to GetName(). Regards, Joel --- [This E-mail scanned for viruses by Declude Virus] |