From: Tilman Sauerbeck Date: Thu, 25 May 2006 09:20:31 +0000 (+0000) Subject: Code cleanup. X-Git-Url: http://git.code-monkey.de/?p=ruby-evas.git;a=commitdiff_plain;h=9ee77c744d2cb8d6d215aab112ff2d77eb8464fd Code cleanup. --- diff --git a/src/rb_evas.c b/src/rb_evas.c index f1b433f..ff76dba 100644 --- a/src/rb_evas.c +++ b/src/rb_evas.c @@ -1,5 +1,5 @@ /* - * $Id: rb_evas.c 354 2006-02-10 18:14:08Z tilman $ + * $Id: rb_evas.c 382 2006-05-25 09:20:31Z tilman $ * * Copyright (C) 2004 Tilman Sauerbeck (tilman at code-monkey de) * @@ -98,8 +98,6 @@ static VALUE c_font_path_append (VALUE self, VALUE path) { GET_OBJ (self, RbEvas, e); - Check_Type (path, T_STRING); - evas_font_path_append (e->real, StringValuePtr (path)); return Qnil; @@ -115,8 +113,6 @@ static VALUE c_font_path_prepend (VALUE self, VALUE path) { GET_OBJ (self, RbEvas, e); - Check_Type (path, T_STRING); - evas_font_path_append (e->real, StringValuePtr (path)); return Qnil; @@ -298,8 +294,6 @@ static VALUE c_find_object (VALUE self, VALUE name) GET_OBJ (self, RbEvas, e); - Check_Type (name, T_STRING); - if (!(o = evas_object_name_find (e->real, StringValuePtr (name)))) return Qnil; diff --git a/src/rb_evas_object.c b/src/rb_evas_object.c index a054a08..b37d66d 100644 --- a/src/rb_evas_object.c +++ b/src/rb_evas_object.c @@ -1,5 +1,5 @@ /* - * $Id: rb_evas_object.c 369 2006-02-15 18:09:44Z tilman $ + * $Id: rb_evas_object.c 382 2006-05-25 09:20:31Z tilman $ * * Copyright (C) 2004 Tilman Sauerbeck (tilman at code-monkey de) * @@ -306,8 +306,6 @@ static VALUE c_name_set (VALUE self, VALUE val) { GET_OBJ (self, RbEvasObject, e); - Check_Type (val, T_STRING); - evas_object_name_set (e->real, StringValuePtr (val)); return Qnil; diff --git a/src/rb_image.c b/src/rb_image.c index a3b96b8..3cfe273 100644 --- a/src/rb_image.c +++ b/src/rb_image.c @@ -1,5 +1,5 @@ /* - * $Id: rb_image.c 376 2006-02-25 10:10:31Z tilman $ + * $Id: rb_image.c 382 2006-05-25 09:20:31Z tilman $ * * Copyright (C) 2004 Tilman Sauerbeck (tilman at code-monkey de) * @@ -84,12 +84,8 @@ static VALUE c_set_file (int argc, VALUE *argv, VALUE self) rb_scan_args (argc, argv, "11", &file, &key); - Check_Type (file, T_STRING); - - if (!NIL_P (key)) { - Check_Type (key, T_STRING); + if (!NIL_P (key)) k = StringValuePtr (key); - } evas_object_image_file_set (e->real, StringValuePtr (file), k); diff --git a/src/rb_text.c b/src/rb_text.c index 7488367..a06a1dd 100644 --- a/src/rb_text.c +++ b/src/rb_text.c @@ -1,5 +1,5 @@ /* - * $Id: rb_text.c 368 2006-02-15 18:07:49Z tilman $ + * $Id: rb_text.c 382 2006-05-25 09:20:31Z tilman $ * * Copyright (C) 2004 Tilman Sauerbeck (tilman at code-monkey de) * @@ -101,8 +101,6 @@ static VALUE c_font_source_set (VALUE self, VALUE val) { GET_OBJ (self, RbEvasObject, e); - Check_Type (val, T_STRING); - evas_object_text_font_source_set (e->real, StringValuePtr (val)); return Qnil; @@ -142,7 +140,6 @@ static VALUE c_set_font (VALUE self, VALUE font, VALUE size) { GET_OBJ (self, RbEvasObject, e); - Check_Type (font, T_STRING); Check_Type (size, T_FIXNUM); evas_object_text_font_set (e->real, StringValuePtr (font), @@ -179,8 +176,6 @@ static VALUE c_text_set (VALUE self, VALUE val) { GET_OBJ (self, RbEvasObject, e); - Check_Type (val, T_STRING); - evas_object_text_text_set (e->real, StringValuePtr (val)); return Qnil;