1) Are you sure the property is being changed? Compare the values of
the property before and after.

Ah, I was apparently getting an information only property by mistake, thus it 
would never be set.
It seems to be working how I want it to be now.

Thanks,
Brian Panneton



Utkarsh Ayachit wrote:
1) Are you sure the property is being changed? Compare the values of
the property berfore and after.
2) Are the VTK methods that should be called on the underlying filter
being called? Add breakpoints/couts and verify?
3) Are you calling this->Modified() in those VTK methods? VTK does not
reexecute a filter unless it is modified.

Utkarsh

On Tue, Apr 19, 2011 at 11:54 AM, Brian C. Panneton (CONTR)
<[email protected]> wrote:
That acts the same as it did. It will accept and run RequestData on the
first accept. But anything changes after will not change it.

Utkarsh Ayachit wrote:
Try
this->proxy->UpdateVTKObjects()

does that help?

Utkarsh

On Tue, Apr 19, 2011 at 11:33 AM, Brian C. Panneton (CONTR)
<[email protected]> wrote:

My slot to catch when the user checks or unchecks looks like this:

[code]
void
MyPanel::updateSelection()
{
 printf("updateSelection: Start\n");
 vtkSMStringVectorProperty* lb =
dynamic_cast<vtkSMStringVectorProperty*>(
     this->proxy()->GetProperty("SelectionList"));
 printf("updateSelection: Elements = %i\n", lb->GetNumberOfElements());
 for(int i = 0; i < lb->GetNumberOfElements(); i=i+2)
 {
     if(this->widgets.lbSelection->item(i/2)->checkState() ==
Qt::Checked)
     {
         printf("updateSelection: SetElement(%i) == Checked\n", i+1);
         lb->SetElement(i+1, "1");
     }
     else
     {
         printf("updateSelection: SetElement(%i) == Unchecked\n", i+1);
         lb->SetElement(i+1, "0");
     }
 }

 this->proxy()->UpdatePropertyInformation(lb);
 this->setModified();
 printf("updateSelection: End\n");
}
[/code]

So the SelectionList property is being changed. Should I not be calling
this->proxy()->UpdatePropertyInformation(lb)?

Either way I still experience the same issue.

Thanks,
Brian Panneton

Utkarsh Ayachit wrote:

If RequestData() is not being called, it implies that no property on
the filter/source proxy is being modified at all. Is that the case?

Utkarsh

On Tue, Apr 19, 2011 at 11:05 AM, Brian C. Panneton (CONTR)
<[email protected]> wrote:


I have a custom panel which has a QListWidget. The panel updates the

widget when another panel widget gets changed. I have a SLOT which
catches
this change, modifies the QListWidget. I have another SLOT catch when
the
QListWidgetItems are checked/unchecked and calls this->setModified().
Thus
the accept button is highlighted. However, when you click accept,
RequestData does not get called. Is there a way to catch the accept
signal
and force a RequestData?

Thanks,
Brian Panneton


_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the ParaView Wiki at:
http://paraview.org/Wiki/ParaView

Follow this link to subscribe/unsubscribe:
http://www.paraview.org/mailman/listinfo/paraview




_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the ParaView Wiki at: 
http://paraview.org/Wiki/ParaView

Follow this link to subscribe/unsubscribe:
http://www.paraview.org/mailman/listinfo/paraview

Reply via email to