[libchamplain] Implement champlain_base_marker_set_highlighted() and champlain_base_marker_get_highlighted()



commit e95fa27ca32ccc573a38d6d211eec67e4813b610
Author: Emmanuel Rodriguez <emmanuel rodriguez gmail com>
Date:   Wed Jul 29 20:57:10 2009 +0200

    Implement champlain_base_marker_set_highlighted() and champlain_base_marker_get_highlighted()

 bindings/perl/Champlain/t/ChamplainBaseMarker.t   |    8 +++++++-
 bindings/perl/Champlain/xs/ChamplainBaseMarker.xs |    7 +++++++
 2 files changed, 14 insertions(+), 1 deletions(-)
---
diff --git a/bindings/perl/Champlain/t/ChamplainBaseMarker.t b/bindings/perl/Champlain/t/ChamplainBaseMarker.t
index 80ae725..e540f4c 100644
--- a/bindings/perl/Champlain/t/ChamplainBaseMarker.t
+++ b/bindings/perl/Champlain/t/ChamplainBaseMarker.t
@@ -3,7 +3,7 @@
 use strict;
 use warnings;
 
-use Clutter::TestHelper tests => 5;
+use Clutter::TestHelper tests => 8;
 
 use Champlain;
 
@@ -24,6 +24,12 @@ sub tests {
 	is($latitude, 20.0, "set_position() changed the latitude");
 	is($longitude, 40.0, "set_position() changed the longitude");
 
+	is($marker->get_highlighted(), FALSE, "Initial highlighted is false");
+	$marker->set_highlighted(TRUE);
+	is($marker->get_highlighted(), TRUE, "Changed highlighted to true");
+	$marker->set_highlighted(FALSE);
+	is($marker->get_highlighted(), FALSE, "Changed highlighted to false");
+
 	return 0;
 }
 
diff --git a/bindings/perl/Champlain/xs/ChamplainBaseMarker.xs b/bindings/perl/Champlain/xs/ChamplainBaseMarker.xs
index 655fde7..afb760d 100644
--- a/bindings/perl/Champlain/xs/ChamplainBaseMarker.xs
+++ b/bindings/perl/Champlain/xs/ChamplainBaseMarker.xs
@@ -12,3 +12,10 @@ champlain_base_marker_new (class)
 void
 champlain_base_marker_set_position (ChamplainBaseMarker *marker, gdouble longitude, gdouble latitude)
 
+
+void
+champlain_base_marker_set_highlighted (ChamplainBaseMarker *champlainBaseMarker, gboolean value);
+
+
+gboolean
+champlain_base_marker_get_highlighted (ChamplainBaseMarker *champlainBaseMarker);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]