cvs: pecl /newt newt.c

From: Date: Fri, 13 Aug 2004 20:35:55 +0000
Subject: cvs: pecl /newt newt.c
Groups: php.pecl.cvs 
Request: Send a blank email to pecl-cvs+get-1648@lists.php.net to get a copy of this message
michael Fri Aug 13 16:35:55 2004 EDT Modified files: /pecl/newt newt.c Log: added functions http://cvs.php.net/diff.php/pecl/newt/newt.c?r1=1.5&r2=1.6&ty=u Index: pecl/newt/newt.c diff -u pecl/newt/newt.c:1.5 pecl/newt/newt.c:1.6 --- pecl/newt/newt.c:1.5 Fri Aug 13 16:19:59 2004 +++ pecl/newt/newt.c Fri Aug 13 16:35:54 2004 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: newt.c,v 1.5 2004/08/13 20:19:59 michael Exp $ */ +/* $Id: newt.c,v 1.6 2004/08/13 20:35:54 michael Exp $ */ #include <newt.h> @@ -3063,6 +3063,7 @@ /* }}} */ /* {{{ + * proto newt_grid_get_size (resouce grid, int &width, int &height) */ PHP_FUNCTION(newt_grid_get_size) { @@ -3092,6 +3093,7 @@ /* }}} */ /* {{{ + * proto newt_grid_wrapped_window (resource grid, string title) */ PHP_FUNCTION(newt_grid_wrapped_window) { @@ -3112,16 +3114,47 @@ /* }}} */ /* {{{ + * proto newt_grid_wrapped_window_at (resource grid, string title, int left, int top) */ PHP_FUNCTION(newt_grid_wrapped_window_at) { + zval * z_grid; + newtGrid grid; + char *title = NULL; + int title_len; + int left, top; + + int argc = ZEND_NUM_ARGS(); + if (argc != 4) { WRONG_PARAM_COUNT; } + if (zend_parse_parameters (argc, "zsll", &z_grid, &title, &title_len, &left, &top) == FAILURE) { + return; + } + + ZEND_FETCH_RESOURCE(grid, newtGrid, &z_grid, -1, le_newt_grid_name, le_newt_grid); + newtGridWrappedWindowAt (grid, title, left, top); } /* }}} */ /* {{{ + * proto newt_grid_add_components_to_form (resource grid, resource form, bool recurse) */ PHP_FUNCTION(newt_grid_add_components_to_form) { + zval * z_grid, * z_form; + newtGrid grid; + newtComponent form; + int recurse; + + int argc = ZEND_NUM_ARGS(); + if (argc != 3) { WRONG_PARAM_COUNT; } + if (zend_parse_parameters (argc, "zzb", &z_grid, &z_form, &recurse) == FAILURE) { + return; + } + + ZEND_FETCH_RESOURCE(grid, newtGrid, &z_grid, -1, le_newt_grid_name, le_newt_grid); + ZEND_FETCH_RESOURCE(form, newtComponent, &z_form, -1, le_newt_comp_name, le_newt_comp); + + newtGridAddComponentsToForm (grid, form, recurse); } /* }}} */

« previous php.pecl.cvs (#1648) next »