[gcompris] shapegame engine, now the tooltip of SHAPE_BACKGROUND type shape is displayed.



commit 9a6c230c0e5bf10c718d62752e13dcfcade19565
Author: Bruno Coudoin <bruno coudoin free fr>
Date:   Sun Aug 12 13:18:20 2012 +0200

    shapegame engine, now the tooltip of SHAPE_BACKGROUND type shape is displayed.
    
    removed useless tooltip=background in many generated levels.

 src/babymatch-activity/shapegame.c                 |    6 ++++++
 .../resources/babyshapes/board8_0.xml.in           |    2 +-
 .../resources/babyshapes/board8_1.xml.in           |    2 +-
 .../resources/babyshapes/board8_2.xml.in           |    2 +-
 .../resources/babyshapes/board8_3.xml.in           |    2 +-
 .../resources/babyshapes/board8_4.xml.in           |    2 +-
 .../resources/geo_country/board10_0.xml.in         |    2 +-
 .../resources/geo_country/board10_1.xml.in         |    2 +-
 .../resources/geo_country/board11_0.xml.in         |    2 +-
 .../resources/geo_country/board11_1.xml.in         |    2 +-
 .../resources/geo_country/board11_2.xml.in         |    2 +-
 .../resources/geo_country/board11_3.xml.in         |    2 +-
 .../resources/geo_country/board12_0.xml.in         |    2 +-
 .../resources/geo_country/board13_0.xml.in         |    2 +-
 .../resources/geo_country/board14_0.xml.in         |    2 +-
 .../resources/geo_country/board7_0.xml.in          |    2 +-
 .../resources/geo_country/board8_0.xml.in          |    2 +-
 .../resources/geo_country/board9_0.xml.in          |    2 +-
 18 files changed, 23 insertions(+), 17 deletions(-)
---
diff --git a/src/babymatch-activity/shapegame.c b/src/babymatch-activity/shapegame.c
index a19d62f..99d669a 100644
--- a/src/babymatch-activity/shapegame.c
+++ b/src/babymatch-activity/shapegame.c
@@ -1527,6 +1527,12 @@ add_shape_to_canvas(Shape *shape)
     }
   else if(shape->type==SHAPE_BACKGROUND)
     {
+      g_signal_connect(item, "enter_notify_event",
+		       (GCallback) item_event,
+		       shape);
+      g_signal_connect(item, "leave_notify_event",
+		       (GCallback) item_event,
+		       shape);
       goo_canvas_item_lower(item, NULL);
     }
 
diff --git a/src/babyshapes-activity/resources/babyshapes/board8_0.xml.in b/src/babyshapes-activity/resources/babyshapes/board8_0.xml.in
index 37ade93..dfab387 100644
--- a/src/babyshapes-activity/resources/babyshapes/board8_0.xml.in
+++ b/src/babyshapes-activity/resources/babyshapes/board8_0.xml.in
@@ -11,5 +11,5 @@
 <shape name="Statue" pixmapfile="babyshapes/Paul_Gauguin_006_statue.png" position="0"  x="204.0" y="76.5">
 </shape>
 <shape name="background" pixmapfile="babyshapes/Paul_Gauguin_006_background.png" position="0" type="SHAPE_BACKGROUND" x="399.5" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/babyshapes-activity/resources/babyshapes/board8_1.xml.in b/src/babyshapes-activity/resources/babyshapes/board8_1.xml.in
index 5b5bed3..800c6df 100644
--- a/src/babyshapes-activity/resources/babyshapes/board8_1.xml.in
+++ b/src/babyshapes-activity/resources/babyshapes/board8_1.xml.in
@@ -14,5 +14,5 @@
 <shape name="Fillette" pixmapfile="babyshapes/Pieter_Bruegel_fillette.png" position="0" x="293.5" y="445.0">
 </shape>
 <shape name="background" pixmapfile="babyshapes/Pieter_Bruegel_background.png" position="0" type="SHAPE_BACKGROUND" x="399.5" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/babyshapes-activity/resources/babyshapes/board8_2.xml.in b/src/babyshapes-activity/resources/babyshapes/board8_2.xml.in
index 4ccd045..08c26bb 100644
--- a/src/babyshapes-activity/resources/babyshapes/board8_2.xml.in
+++ b/src/babyshapes-activity/resources/babyshapes/board8_2.xml.in
@@ -16,5 +16,5 @@
 <shape name="1" pixmapfile="babyshapes/lady_unicorn_1.png" position="0"  x="637.5" y="43.5">
 </shape>
 <shape name="background" pixmapfile="babyshapes/lady_unicorn_background.png" position="0" type="SHAPE_BACKGROUND" x="400.0" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/babyshapes-activity/resources/babyshapes/board8_3.xml.in b/src/babyshapes-activity/resources/babyshapes/board8_3.xml.in
index 80bbc8d..b4a6c6b 100644
--- a/src/babyshapes-activity/resources/babyshapes/board8_3.xml.in
+++ b/src/babyshapes-activity/resources/babyshapes/board8_3.xml.in
@@ -16,5 +16,5 @@
 <shape name="2" pixmapfile="babyshapes/Van_Gogh_0011_2.png" position="0"  x="133.0" y="315.0">
 </shape>
 <shape name="background" pixmapfile="babyshapes/Van_Gogh_0011_background.png" position="0"  type="SHAPE_BACKGROUND" x="399.5" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/babyshapes-activity/resources/babyshapes/board8_4.xml.in b/src/babyshapes-activity/resources/babyshapes/board8_4.xml.in
index a24f2d0..d39f382 100644
--- a/src/babyshapes-activity/resources/babyshapes/board8_4.xml.in
+++ b/src/babyshapes-activity/resources/babyshapes/board8_4.xml.in
@@ -18,5 +18,5 @@
 <shape name="1" pixmapfile="babyshapes/Bosschaert_04_1.png" position="0"  x="498.0" y="384.5">
 </shape>
 <shape name="background" pixmapfile="babyshapes/Bosschaert_04_background.png" position="0" type="SHAPE_BACKGROUND" x="400.0" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board10_0.xml.in b/src/geo_country-activity/resources/geo_country/board10_0.xml.in
index 6c74bfc..b80134b 100644
--- a/src/geo_country-activity/resources/geo_country/board10_0.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board10_0.xml.in
@@ -105,5 +105,5 @@
 <shape name="Washington" pixmapfile="geo_country/usa/washington.png" position="0" sound="geo_country/usa/Washington.ogg" x="141.0" y="79.0">
 <tooltip>Washington</tooltip></shape>
 <shape name="background" pixmapfile="geo_country/usa/background.png" position="0" type="SHAPE_BACKGROUND" x="400.0" y="259.5">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board10_1.xml.in b/src/geo_country-activity/resources/geo_country/board10_1.xml.in
index a1fefce..b54b10a 100644
--- a/src/geo_country-activity/resources/geo_country/board10_1.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board10_1.xml.in
@@ -105,5 +105,5 @@
 <shape name="Washington" pixmapfile="geo_country/usa/washington.png" position="0" sound="geo_country/usa/Washington.ogg" x="141.0" y="79.0">
 <tooltip>Washington</tooltip></shape>
 <shape name="background" pixmapfile="geo_country/usa/background1.png" position="0" sound="geo_country/usa/background1.ogg" type="SHAPE_BACKGROUND" x="400.0" y="259.5">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board11_0.xml.in b/src/geo_country-activity/resources/geo_country/board11_0.xml.in
index 9bc34a4..779bf97 100644
--- a/src/geo_country-activity/resources/geo_country/board11_0.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board11_0.xml.in
@@ -43,5 +43,5 @@
 <shape name="Liguria" pixmapfile="geo_country/italy/liguria.png" position="0" sound="sounds/$LOCALE/geo_country/italy/Liguria.ogg" x="277.5" y="143.0">
 <tooltip>Liguria</tooltip></shape>
 <shape name="background" pixmapfile="geo_country/italy/background.png" position="0" type="SHAPE_BACKGROUND" x="400.0" y="259.5">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board11_1.xml.in b/src/geo_country-activity/resources/geo_country/board11_1.xml.in
index 967273e..ac4c7b6 100644
--- a/src/geo_country-activity/resources/geo_country/board11_1.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board11_1.xml.in
@@ -95,5 +95,5 @@
 <shape name="Aosta" pixmapfile="geo_country/italy/north/aosta.png" position="0" sound="sounds/$LOCALE/geography/Aosta.ogg" x="134.5" y="224.0">
 <tooltip>Aosta</tooltip></shape>
 <shape name="background" pixmapfile="geo_country/italy/north/background.png" position="0" type="SHAPE_BACKGROUND" x="400.0" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board11_2.xml.in b/src/geo_country-activity/resources/geo_country/board11_2.xml.in
index 9735369..a2ee3c5 100644
--- a/src/geo_country-activity/resources/geo_country/board11_2.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board11_2.xml.in
@@ -55,5 +55,5 @@
 <shape name="Massa-Carrara" pixmapfile="geo_country/italy/central/massa-carrara.png" position="0" sound="sounds/$LOCALE/geography/Massa-Carrara.ogg" x="191.0" y="93.5">
 <tooltip>Massa-Carrara</tooltip></shape>
 <shape name="background" pixmapfile="geo_country/italy/central/background.png" position="0" type="SHAPE_BACKGROUND" x="400.0" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board11_3.xml.in b/src/geo_country-activity/resources/geo_country/board11_3.xml.in
index 5d42cc6..dd055c5 100644
--- a/src/geo_country-activity/resources/geo_country/board11_3.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board11_3.xml.in
@@ -77,5 +77,5 @@
 <shape name="Sassari" pixmapfile="geo_country/italy/south/sassari.png" position="0" sound="sounds/$LOCALE/geography/Sassari.ogg" x="138.5" y="174.0">
 <tooltip>Sassari</tooltip></shape>
 <shape name="background" pixmapfile="geo_country/italy/south/background.png" position="0" type="SHAPE_BACKGROUND" x="399.5" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board12_0.xml.in b/src/geo_country-activity/resources/geo_country/board12_0.xml.in
index f013792..18fc054 100644
--- a/src/geo_country-activity/resources/geo_country/board12_0.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board12_0.xml.in
@@ -65,5 +65,5 @@
 <shape name="Jammu and Kashmir" pixmapfile="geo_country/india/jammu_and_kashmir.png" position="0" sound="sounds/$LOCALE/geography/india/Jammu and Kashmir.ogg" x="269.0" y="73.5">
 <tooltip>Jammu and Kashmir</tooltip></shape>
 <shape name="background" pixmapfile="geo_country/india/background.png" position="0" type="SHAPE_BACKGROUND" x="400.0" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board13_0.xml.in b/src/geo_country-activity/resources/geo_country/board13_0.xml.in
index 897a553..3a2f5fa 100644
--- a/src/geo_country-activity/resources/geo_country/board13_0.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board13_0.xml.in
@@ -17,5 +17,5 @@
 <shape name="Western Australia" pixmapfile="geo_country/australia/western_australia.png" position="0" sound="sounds/$LOCALE/geography/australia/Western Australia.ogg" x="198.5" y="211.0">
 <tooltip>Western Australia</tooltip></shape>
 <shape name="background" pixmapfile="geo_country/australia/background.png" position="0" type="SHAPE_BACKGROUND" x="399.5" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board14_0.xml.in b/src/geo_country-activity/resources/geo_country/board14_0.xml.in
index 20c7b80..4d144ad 100644
--- a/src/geo_country-activity/resources/geo_country/board14_0.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board14_0.xml.in
@@ -65,5 +65,5 @@
 <shape name="Xinjiang" pixmapfile="geo_country/china/xinjiang.png" position="0" sound="sounds/$LOCALE/geography/china/xinjiang.ogg" x="216.0" y="147.5">
 <tooltip>Xinjiang</tooltip></shape>
 <shape name="background" pixmapfile="geo_country/china/background.png" position="0" type="SHAPE_BACKGROUND" x="399.5" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board7_0.xml.in b/src/geo_country-activity/resources/geo_country/board7_0.xml.in
index f9b15fd..f4401e7 100644
--- a/src/geo_country-activity/resources/geo_country/board7_0.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board7_0.xml.in
@@ -57,5 +57,5 @@
   <shape name="Amazonas" pixmapfile="geo_country/brazil/Amazonas.png" position="0" sound="sounds/$LOCALE/geography/brazil/Amazonas.png" x="282.0" y="143.0">
     <tooltip>Amazonas</tooltip></shape>
   <shape name="background" pixmapfile="geo_country/brazil/background.png" position="0" type="SHAPE_BACKGROUND" x="399.5" y="260.0">
-    <tooltip>background</tooltip></shape>
+    </shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board8_0.xml.in b/src/geo_country-activity/resources/geo_country/board8_0.xml.in
index f5099d3..eff2631 100644
--- a/src/geo_country-activity/resources/geo_country/board8_0.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board8_0.xml.in
@@ -29,5 +29,5 @@
 <shape name="Yukon" pixmapfile="geo_country/canada/yukon.png" position="0" sound="sounds/$LOCALE/geography/canada/Yukon.ogg" x="107.5" y="196.0">
 <tooltip>Yukon</tooltip></shape>
 <shape name="background" pixmapfile="geo_country/canada/background.png" position="0" type="SHAPE_BACKGROUND" x="412" y="260.0">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>
diff --git a/src/geo_country-activity/resources/geo_country/board9_0.xml.in b/src/geo_country-activity/resources/geo_country/board9_0.xml.in
index 99dc5c5..67ef405 100644
--- a/src/geo_country-activity/resources/geo_country/board9_0.xml.in
+++ b/src/geo_country-activity/resources/geo_country/board9_0.xml.in
@@ -67,5 +67,5 @@
 <shape name="Zacatecas" pixmapfile="geo_country/mexico/zacatecas.png" position="0" sound="sounds/$LOCALE/geography/mexico/Zacatecas.ogg" x="379.0" y="286.5">
 <tooltip>Zacatecas</tooltip></shape>
 <shape name="background" pixmapfile="geo_country/mexico/background.png" position="0" type="SHAPE_BACKGROUND" x="413.5" y="259.5">
-<tooltip>background</tooltip></shape>
+</shape>
 </ShapeGame>



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