Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBruno Coudoin <bcoudoin@src.gnome.org>2005-09-18 16:31:23 (GMT)
committer Bruno Coudoin <bcoudoin@src.gnome.org>2005-09-18 16:31:23 (GMT)
commit002af3ddec250f002bb23bd03149d3ff1cacbe16 (patch)
tree5fd76bb645bcf573318d8e6eb09c2d1140ffa63e
parent2df956167bfef6728f84932c35e62f8e97819cdb (diff)
Fixed gcompris2spip to work with spip 1.8.2
Commit of XRANDR patch from debian Bug report logs - #310058
-rw-r--r--ChangeLog19
-rw-r--r--INSTALL2
-rw-r--r--boards/hanoi_real.xml.in2
-rw-r--r--docs/screenshots/memory_tux.jpgbin0 -> 34335 bytes
-rw-r--r--docs/screenshots/memory_tux_small.jpgbin0 -> 14796 bytes
-rw-r--r--docs/screenshots/tuxpaint.jpgbin0 -> 40771 bytes
-rw-r--r--docs/screenshots/tuxpaint_small.jpgbin0 -> 16914 bytes
-rw-r--r--docs/spip_menuboard.xsl7
-rw-r--r--docs/spip_oneboard.xsl2
-rw-r--r--po/Makefile.in.in28
-rw-r--r--src/gcompris/gcompris.c60
-rw-r--r--src/gcompris/properties.c6
12 files changed, 83 insertions, 43 deletions
diff --git a/ChangeLog b/ChangeLog
index 899b552..ae0b65c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,22 @@
+2005-09-18 Bruno coudoin <bruno.coudoin@free.fr>
+
+ Fixed gcompris2spip to work with spip 1.8.2
+
+ Commit of XRANDR patch from debian Bug report logs - #310058
+
+ * INSTALL:
+ * boards/hanoi_real.xml.in:
+ * docs/screenshots/memory_tux.jpg:
+ * docs/screenshots/memory_tux_small.jpg:
+ * docs/screenshots/tuxpaint.jpg:
+ * docs/screenshots/tuxpaint_small.jpg:
+ * docs/spip_menuboard.xsl:
+ * docs/spip_oneboard.xsl:
+ * po/Makefile.in.in:
+ * src/gcompris/gcompris.c: (init_background), (gcompris_exit),
+ (xrandr_init), (xrandr_get_config):
+ * src/gcompris/properties.c: (gcompris_properties_save):
+
2005-09-18 Yves Combe,,, <yves@ycombe.net>
try to fix dependances on gtk 2.4 and not 2.6
diff --git a/INSTALL b/INSTALL
index bd0403a..1051915 100644
--- a/INSTALL
+++ b/INSTALL
@@ -35,7 +35,7 @@ libSDL libSDL-mixer
On a Mandriva, you will need to install their -devel counterpart package in
order to be abble to compile it plus intltool, tetex.
-In order to compile gcompris on a mandrake 10.1 you must install :
+In order to compile gcompris on a mandrake 10.2 you must install :
urpmi pkgconfig
urpmi autoconf2.5
urpmi glib-gettext
diff --git a/boards/hanoi_real.xml.in b/boards/hanoi_real.xml.in
index 8b51efc..1d20d2d 100644
--- a/boards/hanoi_real.xml.in
+++ b/boards/hanoi_real.xml.in
@@ -5,7 +5,7 @@
type="hanoi_real"
section="/boards"
icon="boardicons/hanoi_real.png"
- difficulty="0"
+ difficulty="3"
author="Bruno Coudoin (bruno.coudoin@free.fr)"
boarddir="">
<_title>The Tower of Hanoi</_title>
diff --git a/docs/screenshots/memory_tux.jpg b/docs/screenshots/memory_tux.jpg
new file mode 100644
index 0000000..8ad526c
--- /dev/null
+++ b/docs/screenshots/memory_tux.jpg
Binary files differ
diff --git a/docs/screenshots/memory_tux_small.jpg b/docs/screenshots/memory_tux_small.jpg
new file mode 100644
index 0000000..5eeb342
--- /dev/null
+++ b/docs/screenshots/memory_tux_small.jpg
Binary files differ
diff --git a/docs/screenshots/tuxpaint.jpg b/docs/screenshots/tuxpaint.jpg
new file mode 100644
index 0000000..fcffef6
--- /dev/null
+++ b/docs/screenshots/tuxpaint.jpg
Binary files differ
diff --git a/docs/screenshots/tuxpaint_small.jpg b/docs/screenshots/tuxpaint_small.jpg
new file mode 100644
index 0000000..98c5d9b
--- /dev/null
+++ b/docs/screenshots/tuxpaint_small.jpg
Binary files differ
diff --git a/docs/spip_menuboard.xsl b/docs/spip_menuboard.xsl
index 9da2ea2..50a5b13 100644
--- a/docs/spip_menuboard.xsl
+++ b/docs/spip_menuboard.xsl
@@ -35,9 +35,14 @@
<nom_site>__REMOVEME__</nom_site>
<url_site>__REMOVEME__</url_site>
<extra>__REMOVEME__</extra>
- <idx>oui</idx>
+ <idx>1</idx>
<id_version>0</id_version>
<lien_auteur>1</lien_auteur>
+ <surtitre>__REMOVEME__</surtitre>
+ <soustitre>__REMOVEME__</soustitre>
+ <descriptif>__REMOVEME__</descriptif>
+ <chapo>__REMOVEME__</chapo>
+ <url_propre>__REMOVEME__</url_propre>
<ps>__REMOVEME__</ps>
<xsl:for-each select="GComprisBoards/GCompris/Board[@name=$name]">
diff --git a/docs/spip_oneboard.xsl b/docs/spip_oneboard.xsl
index 398f933..18c1fc9 100644
--- a/docs/spip_oneboard.xsl
+++ b/docs/spip_oneboard.xsl
@@ -36,7 +36,7 @@
<nom_site>__REMOVEME__</nom_site>
<url_site>__REMOVEME__</url_site>
<extra>__REMOVEME__</extra>
- <idx>oui</idx>
+ <idx>1</idx>
<id_version>0</id_version>
<lien_auteur>1</lien_auteur>
<ps>__REMOVEME__</ps>
diff --git a/po/Makefile.in.in b/po/Makefile.in.in
index 1a6961e..b7dfd61 100644
--- a/po/Makefile.in.in
+++ b/po/Makefile.in.in
@@ -45,7 +45,6 @@ INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
CC = @CC@
-GENCAT = @GENCAT@
GMSGFMT = @GMSGFMT@
MSGFMT = @MSGFMT@
XGETTEXT = @XGETTEXT@
@@ -73,7 +72,6 @@ POTFILES = \
CATALOGS = @CATALOGS@
CATOBJEXT = @CATOBJEXT@
-INSTOBJEXT = @INSTOBJEXT@
.SUFFIXES:
.SUFFIXES: .c .o .po .pox .gmo .mo .msg .cat
@@ -94,7 +92,7 @@ INSTOBJEXT = @INSTOBJEXT@
.po.cat:
sed -f ../intl/po2msg.sed < $< > $*.msg \
- && rm -f $@ && $(GENCAT) $@ $*.msg
+ && rm -f $@ && gencat $@ $*.msg
all: all-@USE_NLS@
@@ -130,22 +128,22 @@ install-data-yes: all
$(SHELL) $(top_srcdir)/mkinstalldirs $$dir; \
fi; \
if test -r $$cat; then \
- $(INSTALL_DATA) $$cat $$dir/$(GETTEXT_PACKAGE)$(INSTOBJEXT); \
- echo "installing $$cat as $$dir/$(GETTEXT_PACKAGE)$(INSTOBJEXT)"; \
+ $(INSTALL_DATA) $$cat $$dir/$(GETTEXT_PACKAGE).mo; \
+ echo "installing $$cat as $$dir/$(GETTEXT_PACKAGE).mo"; \
else \
- $(INSTALL_DATA) $(srcdir)/$$cat $$dir/$(GETTEXT_PACKAGE)$(INSTOBJEXT); \
+ $(INSTALL_DATA) $(srcdir)/$$cat $$dir/$(GETTEXT_PACKAGE).mo; \
echo "installing $(srcdir)/$$cat as" \
- "$$dir/$(GETTEXT_PACKAGE)$(INSTOBJEXT)"; \
+ "$$dir/$(GETTEXT_PACKAGE).mo"; \
fi; \
if test -r $$cat.m; then \
- $(INSTALL_DATA) $$cat.m $$dir/$(GETTEXT_PACKAGE)$(INSTOBJEXT).m; \
- echo "installing $$cat.m as $$dir/$(GETTEXT_PACKAGE)$(INSTOBJEXT).m"; \
+ $(INSTALL_DATA) $$cat.m $$dir/$(GETTEXT_PACKAGE).mo.m; \
+ echo "installing $$cat.m as $$dir/$(GETTEXT_PACKAGE).mo.m"; \
else \
if test -r $(srcdir)/$$cat.m ; then \
$(INSTALL_DATA) $(srcdir)/$$cat.m \
- $$dir/$(GETTEXT_PACKAGE)$(INSTOBJEXT).m; \
+ $$dir/$(GETTEXT_PACKAGE).mo.m; \
echo "installing $(srcdir)/$$cat as" \
- "$$dir/$(GETTEXT_PACKAGE)$(INSTOBJEXT).m"; \
+ "$$dir/$(GETTEXT_PACKAGE).mo.m"; \
else \
true; \
fi; \
@@ -171,10 +169,10 @@ uninstall:
for cat in $$catalogs; do \
cat=`basename $$cat`; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
- rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE)$(INSTOBJEXT); \
- rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE)$(INSTOBJEXT).m; \
- rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE)$(INSTOBJEXT); \
- rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE)$(INSTOBJEXT).m; \
+ rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo; \
+ rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo.m; \
+ rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo; \
+ rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo.m; \
done
if test "$(PACKAGE)" = "glib"; then \
rm -f $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
diff --git a/src/gcompris/gcompris.c b/src/gcompris/gcompris.c
index dbf9874..230723b 100644
--- a/src/gcompris/gcompris.c
+++ b/src/gcompris/gcompris.c
@@ -173,6 +173,7 @@ static gboolean changed_xrandr = FALSE;
static SizeID xr_previous_size = -1;
static XRANDRData *xrandr;
+static void xrandr_init ( XRANDRData *data );
static void xrandr_get_config ( XRANDRData *data );
gboolean xrandr_set_config( XRANDRData *grandr );
#endif
@@ -322,36 +323,37 @@ static void init_background()
GtkWidget *vbox;
int i;
+ screen_height = gdk_screen_height();
+ screen_width = gdk_screen_width();
+
#ifdef XRANDR
/* Search the 800x600 Resolution */
if(properties->fullscreen && !properties->noxrandr) {
g_warning("XRANDR Is compiled in. Searching a good resolution");
xrandr = g_new0 (XRANDRData, 1);
- xrandr_get_config ( xrandr );
- xr_previous_size = (SizeID)xrandr->xr_current_size;
-
- for (i = 0; i < xrandr->xr_nsize; i++) {
- if(xrandr->xr_sizes[i].width == BOARDWIDTH, xrandr->xr_sizes[i].height == BOARDHEIGHT+BARHEIGHT) {
- xrandr->xr_current_size = (SizeID)i;
- xrandr_set_config( xrandr );
- changed_xrandr = TRUE;
- break;
+ xrandr_init ( xrandr );
+
+ /* Check if XRANDR is available */
+ if (!properties->noxrandr) {
+ xrandr_get_config ( xrandr );
+ xr_previous_size = (SizeID)xrandr->xr_current_size;
+
+ for (i = 0; i < xrandr->xr_nsize; i++) {
+ if(xrandr->xr_sizes[i].width == BOARDWIDTH, xrandr->xr_sizes[i].height == BOARDHEIGHT+BARHEIGHT) {
+ xrandr->xr_current_size = (SizeID)i;
+ xrandr_set_config( xrandr );
+ break;
+ }
}
+ screen_height = xrandr->xr_sizes[xrandr->xr_current_size].height;
+ screen_width = xrandr->xr_sizes[xrandr->xr_current_size].width;
}
- screen_height = xrandr->xr_sizes[xrandr->xr_current_size].height;
- screen_width = xrandr->xr_sizes[xrandr->xr_current_size].width;
- } else {
- screen_height = gdk_screen_height();
- screen_width = gdk_screen_width();
}
-#else
- screen_height = gdk_screen_height();
- screen_width = gdk_screen_width();
#endif
- yratio=screen_height/(float)(BOARDHEIGHT+BARHEIGHT);
- xratio=screen_width/(float)BOARDWIDTH;
+ yratio=screen_height/(float)(BOARDHEIGHT+BARHEIGHT);
+ xratio=screen_width/(float)BOARDWIDTH;
g_message("The screen_width=%f screen_height=%f\n",
(double)screen_width, (double)screen_height);
g_message("The xratio=%f yratio=%f\n", xratio, yratio);
@@ -717,7 +719,7 @@ void gcompris_exit()
#ifdef XRANDR
/* Set back the original screen size */
- if((properties->fullscreen || changed_xrandr) && properties->noxrandr == 0)
+ if(properties->fullscreen && !properties->noxrandr)
{
/* Need to refresh our config or xrandr api will reject us */
xrandr_get_config ( xrandr );
@@ -871,10 +873,24 @@ void gcompris_log_handler (const gchar *log_domain,
* ------------
*/
static void
-xrandr_get_config ( XRANDRData *data )
+xrandr_init ( XRANDRData *data )
{
data->xr_screen_conf = XRRGetScreenInfo (GDK_DISPLAY(), GDK_ROOT_WINDOW());
-
+
+ if (data->xr_screen_conf == NULL)
+ {
+ g_warning("XRANDR not available");
+ properties->noxrandr = TRUE;
+ }
+ else
+ g_warning("XRANDR support enabled");
+ }
+
+static void
+xrandr_get_config ( XRANDRData *data )
+{
+ xrandr_init (data);
+
data->xr_current_size = XRRConfigCurrentConfiguration (data->xr_screen_conf,
&data->xr_current_rotation);
diff --git a/src/gcompris/properties.c b/src/gcompris/properties.c
index f939631..f7f3102 100644
--- a/src/gcompris/properties.c
+++ b/src/gcompris/properties.c
@@ -1,6 +1,6 @@
/* gcompris - properties.c
*
- * Time-stamp: <2005/08/25 22:58:04 yves>
+ * Time-stamp: <2005/09/18 18:00:12 bruno>
*
* Copyright (C) 2000,2003 Bruno Coudoin
*
@@ -332,7 +332,9 @@ void gcompris_properties_save (GcomprisProperties *props)
fprintf(filefd, "%s=%d\n", "fx", props->fx);
fprintf(filefd, "%s=%d\n", "screensize", props->screensize);
fprintf(filefd, "%s=%d\n", "fullscreen", props->fullscreen);
- fprintf(filefd, "%s=%d\n", "noxrandr", props->noxrandr);
+ /* FIXME: No more persist the noxrandr option until we provide a way to set it back
+ *
+ fprintf(filefd, "%s=%d\n", "noxrandr", props->noxrandr); */
fprintf(filefd, "%s=%d\n", "timer", props->timer);
fprintf(filefd, "%s=%d\n", "difficulty_filter", props->difficulty_filter);
fprintf(filefd, "%s=%d\n", "filter_style", props->filter_style);