[libchamplain] Add coverage for the missing methods.
- From: Pierre-Luc Beaudoin <plbeaudoin src gnome org>
- To: svn-commits-list gnome org
- Subject: [libchamplain] Add coverage for the missing methods.
- Date: Sat, 25 Jul 2009 00:26:09 +0000 (UTC)
commit 7841d5c67b2cebcb9a6c76701eaefef4b3e08f8e
Author: Emmanuel Rodriguez <emmanuel rodriguez gmail com>
Date: Sat Jul 11 20:13:38 2009 +0200
Add coverage for the missing methods.
The following methods where not covered:
champlain_tile_get_content
champlain_tile_get_etag
champlain_tile_get_modified_time
champlain_tile_get_modified_time_string
champlain_tile_set_content
champlain_tile_set_etag
champlain_tile_set_modified_time
bindings/perl/Champlain/xs/ChamplainTile.xs | 75 +++++++++++++++++++++++++++
1 files changed, 75 insertions(+), 0 deletions(-)
---
diff --git a/bindings/perl/Champlain/xs/ChamplainTile.xs b/bindings/perl/Champlain/xs/ChamplainTile.xs
index 094f619..1591eaf 100644
--- a/bindings/perl/Champlain/xs/ChamplainTile.xs
+++ b/bindings/perl/Champlain/xs/ChamplainTile.xs
@@ -72,3 +72,78 @@ champlain_tile_set_uri (ChamplainTile *self, const gchar* uri)
void
champlain_tile_set_filename (ChamplainTile *self, const gchar* filename)
+
+
+ClutterActor *
+champlain_tile_get_content (ChamplainTile *self)
+
+
+const gchar*
+champlain_tile_get_etag (ChamplainTile *self)
+
+
+void
+champlain_tile_get_modified_time (ChamplainTile *self)
+ PREINIT:
+ const GTimeVal *modified_time = NULL;
+
+ PPCODE:
+ modified_time = champlain_tile_get_modified_time(self);
+
+ if (modified_time) {
+ EXTEND(SP, 2);
+ PUSHs(sv_2mortal(newSViv(modified_time->tv_sec)));
+ PUSHs(sv_2mortal(newSViv(modified_time->tv_usec)));
+ }
+ else {
+ EXTEND(SP, 2);
+ PUSHs(sv_2mortal(&PL_sv_undef));
+ PUSHs(sv_2mortal(&PL_sv_undef));
+ }
+
+
+SV*
+champlain_tile_get_modified_time_string (ChamplainTile *self)
+ PREINIT:
+ gchar *string = NULL;
+
+ CODE:
+ string = champlain_tile_get_modified_time_string(self);
+ if (string) {
+ RETVAL = newSVpvn(string, 0);
+ g_print("--time : %s\n", string);
+ g_free(string);
+ }
+ else {
+ g_print("--Undef time\n");
+ RETVAL = &PL_sv_undef;
+ }
+
+ OUTPUT:
+ RETVAL
+
+
+
+void
+champlain_tile_set_content (ChamplainTile *self, ClutterActor* actor, gboolean fade_in)
+
+
+void
+champlain_tile_set_etag (ChamplainTile *self, const gchar *etag)
+
+
+void
+champlain_tile_set_modified_time (ChamplainTile *self, guint seconds = 0, guint microseconds = 0)
+ PREINIT:
+ GTimeVal modified_time = {0, };
+
+ CODE:
+ if (microseconds || seconds) {
+ modified_time.tv_sec = seconds;
+ modified_time.tv_usec = microseconds;
+ }
+ else {
+ g_get_current_time(&modified_time);
+ }
+
+ champlain_tile_set_modified_time(self, &modified_time);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]