commit 8fd50e6bcf1d11e38387affec4eb6881e61cfddb
Author: Utkarsh Ayachit <utkarsh.ayachit@kitware.com>
Date:   Wed May 6 08:53:39 2009 -0400

    BUG: Fixed BUG 8958. Committing a slightly modified version of Robert's patch to
    disable interaction with scalar bar when its visibility is changed.

diff --git a/Qt/Core/pqScalarBarRepresentation.cxx b/Qt/Core/pqScalarBarRepresentation.cxx
index 5511673..9007235 100644
--- a/Qt/Core/pqScalarBarRepresentation.cxx
+++ b/Qt/Core/pqScalarBarRepresentation.cxx
@@ -97,6 +97,14 @@ pqScalarBarRepresentation::pqScalarBarRepresentation(const QString& group,
 }
 
 //-----------------------------------------------------------------------------
+void pqScalarBarRepresentation::setVisible(bool visible)
+{
+	pqSMAdaptor::setElementProperty(this->getProxy()->GetProperty("Enabled"),
+    (visible? 1 : 0));
+  this->Superclass::setVisible(visible);
+}
+
+//-----------------------------------------------------------------------------
 pqScalarBarRepresentation::~pqScalarBarRepresentation()
 {
   if (this->Internal->LookupTable)
diff --git a/Qt/Core/pqScalarBarRepresentation.h b/Qt/Core/pqScalarBarRepresentation.h
index 81b4236..f2627b8 100644
--- a/Qt/Core/pqScalarBarRepresentation.h
+++ b/Qt/Core/pqScalarBarRepresentation.h
@@ -62,8 +62,13 @@ public:
   /// Set the title formed by combining two parts.
   void setTitle(const QString& name, const QString& component);
 
-  /// set by pqPipelineRepresentation when it forces the visiblity of the scalar
-  /// bar to be off.
+  /// Set the visibility. Note that this affects the visibility of the
+  /// display in the view it has been added to, if any. This method does not 
+  /// call a re-render on the view, caller must call that explicitly.
+  virtual void setVisible(bool visible);
+
+  /// set by pqPipelineRepresentation when it forces the visibility of the
+  /// scalar bar to be off.
   void setAutoHidden(bool h)
     { this->AutoHidden = h; }
   bool getAutoHidden() const
