This is an automated email from the git hooks/post-receive script.

omegaphil pushed a commit to branch master
in repository panel-plugins/xfce4-hardware-monitor-plugin.

commit 972f91ef338a12bf262a3004fd0c4dc2bdf40195
Author: OmegaPhil <omegap...@startmail.com>
Date:   Sat Aug 15 21:15:29 2015 +0100

    CurveView text overlay: Erase when disabled
---
 src/curve-view.cpp |   10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/src/curve-view.cpp b/src/curve-view.cpp
index cc3b06b..e48fcba 100644
--- a/src/curve-view.cpp
+++ b/src/curve-view.cpp
@@ -262,6 +262,9 @@ void CurveView::do_draw_loop()
       monitor_data_needed = false, monitor_data_compact_needed = false,
       text_overlay_enabled = applet->get_viewer_text_overlay_enabled();
 
+  // Debug code
+  std::cout << "Curves count: " << curves.size() << std::endl;
+
   // Obtain maximum value of all curves in the view
   for (curve_iterator i = curves.begin(), end = curves.end(); i != end; ++i)
     if ((*i)->get_max_value() > max)
@@ -385,6 +388,13 @@ void CurveView::do_draw_loop()
     if (text_overlay->property_y() != y)
       text_overlay->property_y() = y;
   }
+
+  // Ensure text is erased if the overlay is disabled
+  else
+  {
+    if (text_overlay && text_overlay->property_text() != "")
+      text_overlay->property_text() = "";
+  }
 }
 
 const Glib::ustring CurveView::text_overlay_position_to_string(

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.
_______________________________________________
Xfce4-commits mailing list
Xfce4-commits@xfce.org
https://mail.xfce.org/mailman/listinfo/xfce4-commits

Reply via email to