From: Ira W. Snyder Date: Fri, 18 Jan 2008 06:40:37 +0000 (-0800) Subject: Remove old main() functions X-Git-Url: https://www.irasnyder.com/gitweb/?p=tilda-gobject.git;a=commitdiff_plain;h=3e2d4445566d732617d584a2cb4a2aef5573ecba Remove old main() functions Previously, there were main() functions in both tilda-terminal.c and tilda-window.c. They were used for testing when originally implementing the TildaTerminal and TildaWindow types, respectively. Since they are no longer useful, and probably wouldn't run anyway, they can be removed. --- diff --git a/tilda-terminal.c b/tilda-terminal.c index 38a353f..57f14b0 100644 --- a/tilda-terminal.c +++ b/tilda-terminal.c @@ -1091,43 +1091,4 @@ tilda_terminal_get_type (void) return type; } -#if 0 - -int main (int argc, char *argv[]) -{ - GObject *tt; - gint test_number = INT_MIN; - gchar *test_string = NULL; - - /* Initialize the GObject type system */ - g_type_init (); - gtk_init (&argc, &argv); - - tt = g_object_new (TILDA_TYPE_TERMINAL, "number", 10, NULL); - g_object_get (G_OBJECT (tt), "number", &test_number, NULL); - g_assert (test_number == 10); - - g_object_unref (G_OBJECT (tt)); - - tt = g_object_new (TILDA_TYPE_TERMINAL, "number", 22, NULL); - g_object_get (G_OBJECT (tt), "number", &test_number, NULL); - g_assert (test_number == 22); - - g_object_set (G_OBJECT (tt), "font", "hello I'm a font"); - g_object_set (G_OBJECT (tt), "font", "Bitstream Vera Sans Mono 13"); - - g_object_get (G_OBJECT (tt), "font", &test_string, NULL); - g_print ("Read Font: %s\n", test_string); - // NOTE: you MUST free the string!!!! - g_free (test_string); - - g_object_set (G_OBJECT (tt), "transparency-percent", 50); - - g_object_unref (G_OBJECT (tt)); - - return 0; -} - -#endif - /* vim: set ts=4 sts=4 sw=4 noet tw=112: */ diff --git a/tilda-terminal.h b/tilda-terminal.h index e9d8f28..6b07128 100644 --- a/tilda-terminal.h +++ b/tilda-terminal.h @@ -85,4 +85,3 @@ GType tilda_terminal_get_type (void); #endif /* TILDA_TERMINAL_H */ /* vim: set ts=4 sts=4 sw=4 noet tw=112: */ - diff --git a/tilda-window.c b/tilda-window.c index e7a4f24..85fa02b 100644 --- a/tilda-window.c +++ b/tilda-window.c @@ -899,34 +899,4 @@ tilda_window_get_type (void) return type; } -#if 0 - -int main (int argc, char *argv[]) -{ - GObject *tw; - gint test_number = INT_MIN; - - /* Initialize the GObject type system */ - g_type_init (); - gtk_init (&argc, &argv); - - tw = g_object_new (TILDA_TYPE_WINDOW, "number", 10, NULL); - g_object_get (G_OBJECT (tw), "number", &test_number, NULL); - g_assert (test_number == 10); - - g_object_unref (G_OBJECT (tw)); - - tw = g_object_new (TILDA_TYPE_WINDOW, "number", 22, NULL); - g_object_get (G_OBJECT (tw), "number", &test_number, NULL); - g_assert (test_number == 22); - - gtk_main (); - - g_object_unref (G_OBJECT (tw)); - - return 0; -} - -#endif - /* vim: set ts=4 sts=4 sw=4 noet tw=112: */ diff --git a/tilda-window.h b/tilda-window.h index c904c6d..bc05800 100644 --- a/tilda-window.h +++ b/tilda-window.h @@ -81,4 +81,3 @@ gboolean tilda_window_remove_term (TildaWindow *tw, gint terminal_number); #endif /* TILDA_WINDOW_H */ /* vim: set ts=4 sts=4 sw=4 noet tw=112: */ -