summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoreschneider <eschneider@88473608-6f18-0410-8b6c-91216bd3049c>2008-02-05 21:14:02 +0000
committereschneider <eschneider@88473608-6f18-0410-8b6c-91216bd3049c>2008-02-05 21:14:02 +0000
commit1fe83fa1a572d636825a9a0ec149e820ed2e2dd8 (patch)
treeffc8e87783d85df7ff1ee4180d186cbd2f800f7a
parent8c7bf9fa2711abbb4e5a16cdbe2443809d4d0995 (diff)
replaced ints with short
git-svn-id: svn+ssh://svn-nitpicker.cl.cam.ac.uk/linpicker/trunk@203 88473608-6f18-0410-8b6c-91216bd3049c
-rw-r--r--buffer.c9
-rw-r--r--client.c25
-rw-r--r--client.h6
-rw-r--r--nitpicker-common.c48
-rw-r--r--nitpicker-skelimpl.c64
-rw-r--r--nitpicker-skels.c26
-rw-r--r--nitpicker-stubs.c12
-rw-r--r--nitpicker-test-client.c8
-rw-r--r--nitpicker.h26
-rw-r--r--nitpicker.idl10
-rw-r--r--view.c44
11 files changed, 139 insertions, 139 deletions
diff --git a/buffer.c b/buffer.c
index d86a9b5..544d044 100644
--- a/buffer.c
+++ b/buffer.c
@@ -36,14 +36,13 @@ buffer *lookup_buffer( nitpicker clientid, int buf_id ) {
/*** INTERFACE: IMPORT NEW BUFFER INTO NITPICKER ***/
-int nitpicker_import_buffer( nitpicker clientid, const char *mem_name, int w, int h, CORBA_Environment *env ) {
+int nitpicker_import_buffer( nitpicker clientid, const char *mem_name, unsigned short w, unsigned short h, CORBA_Environment *env ) {
int id;
client *c = find_client(clientid);
- if (!c) return -1;
+ if (!c) TRY( !(c = add_client( clientid, 16, 1 )), "Unable to allocate new buffer" );
- TRY( (id = ALLOC_ID(c->buffers, c->max_buffers)) < 0,
- "Unable to allocate new buffer id");
+ TRY( (id = ALLOC_ID(c->buffers, c->max_buffers)) < 0, "Unable to allocate new buffer id");
/* set initial values for the buffer */
memset(&c->buffers[id], 0, sizeof(buffer));
@@ -77,7 +76,7 @@ void nitpicker_remove_buffer( nitpicker clientid, int buf_id, CORBA_Environment
/*** INTERFACE: REFRESH BUFFER AREA ***/
-void nitpicker_refresh( nitpicker clientid, int buf_id, int x, int y, int w, int h, CORBA_Environment *env ){
+void nitpicker_refresh( nitpicker clientid, int buf_id, unsigned short x, unsigned short y, unsigned short w, unsigned short h, CORBA_Environment *env ){
int x1, y1, x2, y2;
view *v;
buffer *b = lookup_buffer(clientid, buf_id);
diff --git a/client.c b/client.c
index 447a88b..19d5e57 100644
--- a/client.c
+++ b/client.c
@@ -27,8 +27,15 @@ static client *first_client = NULL; /* head of client list */
*************************************************/
/*** INIT CLIENT STRUCTURE AND ADD CLIENT TO CLIENT LIST ***/
-void add_client( nitpicker clientid, char *addr, int max_views, int max_buffers) {
+client *add_client( nitpicker clientid, unsigned short max_views, unsigned short max_buffers ) {
+ char *addr;
client *new_client = (client *)&addr[0];
+
+ /* get memory for the client header */
+ addr = malloc( sizeof(buffer)*max_buffers + sizeof(view)*max_views + sizeof(client) );
+ if (!addr) return NULL;
+
+ new_client = (client *)&addr[0];
bzero(new_client, sizeof(client));
new_client->views = (view *)&addr[sizeof(client)];
@@ -46,6 +53,8 @@ void add_client( nitpicker clientid, char *addr, int max_views, int max_buffers)
/* insert client struct into client list */
CHAIN_LISTELEMENT( client, &first_client, next, first_client, new_client );
+
+ return new_client;
}
@@ -86,18 +95,14 @@ client *find_client( nitpicker clientid ) {
***************************/
/*** INTERFACE: IMPORT AND INITIALIZE MEMORY FROM CLIENT ***/
-int nitpicker_add_client( nitpicker clientid, int max_views, int max_buffers, CORBA_Environment *ev ) {
+int nitpicker_initialize_client( nitpicker clientid, unsigned short max_views, unsigned short max_buffers, CORBA_Environment *ev ) {
char *addr;
- if (max_views<=0 || max_buffers<=0) return -2;
+ if (!max_views || !max_buffers) return -2;
- /* no not allow double donations */
+ /* do not allow double donations */
remove_client(clientid);
- /* get memory for the client header */
- addr = malloc( sizeof(buffer)*max_buffers + sizeof(view)*max_views + sizeof(client) );
- if (!addr) return -1;
-
- add_client( clientid, addr, max_views, max_buffers );
- return 0;
+ if (!add_client( clientid, max_views, max_buffers )) return -1;
+ return 0;
}
diff --git a/client.h b/client.h
index 383749b..da1cc24 100644
--- a/client.h
+++ b/client.h
@@ -34,8 +34,8 @@ typedef struct client {
struct client *next; /* next client in list */
view *views; /* array of views */
buffer *buffers; /* array of buffers */
- int max_views; /* size of view array */
- int max_buffers; /* size of buffer array */
+ unsigned short max_views; /* size of view array */
+ unsigned short max_buffers; /* size of buffer array */
nitpicker tid; /* associated client id */
view *bg; /* background view */
char label[CLIENT_LABEL_LEN];
@@ -43,7 +43,7 @@ typedef struct client {
/*** INIT CLIENT STRUCTURE AND ADD CLIENT TO CLIENT LIST ***/
-extern void add_client(nitpicker tid, char *addr, int max_views, int max_buffers);
+extern client *add_client( nitpicker tid, unsigned short max_views, unsigned short max_buffers );
/*** REGISTER AND INITIALIZE NEW CLIENT ***
diff --git a/nitpicker-common.c b/nitpicker-common.c
index 66587db..10a307d 100644
--- a/nitpicker-common.c
+++ b/nitpicker-common.c
@@ -19,25 +19,25 @@ void _ORBIT_skel_small_nitpicker_kill_graphics(POA_nitpicker *_o_ser
CORBA_long (*_impl_kill_graphics)(PortableServer_Servant _servant, CORBA_Environment *ev)) {
*(CORBA_long *)_o_retval = _impl_kill_graphics (_o_servant, _o_ev);
}
-void _ORBIT_skel_small_nitpicker_add_client(POA_nitpicker *_o_servant, gpointer _o_retval,gpointer *_o_args,CORBA_Context _o_ctx,CORBA_Environment *_o_ev,
-CORBA_long (*_impl_add_client)(PortableServer_Servant _servant, const CORBA_long max_views, const CORBA_long max_buffers, CORBA_Environment *ev)) {
-*(CORBA_long *)_o_retval = _impl_add_client (_o_servant, *(const CORBA_long *)_o_args[0], *(const CORBA_long *)_o_args[1], _o_ev);
+void _ORBIT_skel_small_nitpicker_initialize_client(POA_nitpicker *_o_servant, gpointer _o_retval,gpointer *_o_args,CORBA_Context _o_ctx,CORBA_Environment *_o_ev,
+CORBA_long (*_impl_initialize_client)(PortableServer_Servant _servant, const CORBA_unsigned_short max_views, const CORBA_unsigned_short max_buffers, CORBA_Environment *ev)) {
+*(CORBA_long *)_o_retval = _impl_initialize_client (_o_servant, *(const CORBA_unsigned_short *)_o_args[0], *(const CORBA_unsigned_short *)_o_args[1], _o_ev);
}
void _ORBIT_skel_small_nitpicker_get_screen_info(POA_nitpicker *_o_servant, gpointer _o_retval,gpointer *_o_args,CORBA_Context _o_ctx,CORBA_Environment *_o_ev,
-CORBA_long (*_impl_get_screen_info)(PortableServer_Servant _servant, CORBA_long* w, CORBA_long* h, CORBA_long* depth, CORBA_long* mode, CORBA_Environment *ev)) {
-*(CORBA_long *)_o_retval = _impl_get_screen_info (_o_servant, *(CORBA_long* *)_o_args[0], *(CORBA_long* *)_o_args[1], *(CORBA_long* *)_o_args[2], *(CORBA_long* *)_o_args[3], _o_ev);
+CORBA_long (*_impl_get_screen_info)(PortableServer_Servant _servant, CORBA_unsigned_short* w, CORBA_unsigned_short* h, CORBA_unsigned_short* depth, CORBA_unsigned_short* mode, CORBA_Environment *ev)) {
+*(CORBA_long *)_o_retval = _impl_get_screen_info (_o_servant, *(CORBA_unsigned_short* *)_o_args[0], *(CORBA_unsigned_short* *)_o_args[1], *(CORBA_unsigned_short* *)_o_args[2], *(CORBA_unsigned_short* *)_o_args[3], _o_ev);
}
void _ORBIT_skel_small_nitpicker_import_buffer(POA_nitpicker *_o_servant, gpointer _o_retval,gpointer *_o_args,CORBA_Context _o_ctx,CORBA_Environment *_o_ev,
-CORBA_long (*_impl_import_buffer)(PortableServer_Servant _servant, const CORBA_char * ds, const CORBA_long w, const CORBA_long h, CORBA_Environment *ev)) {
-*(CORBA_long *)_o_retval = _impl_import_buffer (_o_servant, *(const CORBA_char * *)_o_args[0], *(const CORBA_long *)_o_args[1], *(const CORBA_long *)_o_args[2], _o_ev);
+CORBA_long (*_impl_import_buffer)(PortableServer_Servant _servant, const CORBA_char * ds, const CORBA_unsigned_short w, const CORBA_unsigned_short h, CORBA_Environment *ev)) {
+*(CORBA_long *)_o_retval = _impl_import_buffer (_o_servant, *(const CORBA_char * *)_o_args[0], *(const CORBA_unsigned_short *)_o_args[1], *(const CORBA_unsigned_short *)_o_args[2], _o_ev);
}
void _ORBIT_skel_small_nitpicker_remove_buffer(POA_nitpicker *_o_servant, gpointer _o_retval,gpointer *_o_args,CORBA_Context _o_ctx,CORBA_Environment *_o_ev,
void (*_impl_remove_buffer)(PortableServer_Servant _servant, const CORBA_long buf_id, CORBA_Environment *ev)) {
_impl_remove_buffer (_o_servant, *(const CORBA_long *)_o_args[0], _o_ev);
}
void _ORBIT_skel_small_nitpicker_refresh(POA_nitpicker *_o_servant, gpointer _o_retval,gpointer *_o_args,CORBA_Context _o_ctx,CORBA_Environment *_o_ev,
-void (*_impl_refresh)(PortableServer_Servant _servant, const CORBA_long buf_id, const CORBA_long x, const CORBA_long y, const CORBA_long w, const CORBA_long h, CORBA_Environment *ev)) {
-_impl_refresh (_o_servant, *(const CORBA_long *)_o_args[0], *(const CORBA_long *)_o_args[1], *(const CORBA_long *)_o_args[2], *(const CORBA_long *)_o_args[3], *(const CORBA_long *)_o_args[4], _o_ev);
+void (*_impl_refresh)(PortableServer_Servant _servant, const CORBA_long buf_id, const CORBA_unsigned_short x, const CORBA_unsigned_short y, const CORBA_unsigned_short w, const CORBA_unsigned_short h, CORBA_Environment *ev)) {
+_impl_refresh (_o_servant, *(const CORBA_long *)_o_args[0], *(const CORBA_unsigned_short *)_o_args[1], *(const CORBA_unsigned_short *)_o_args[2], *(const CORBA_unsigned_short *)_o_args[3], *(const CORBA_unsigned_short *)_o_args[4], _o_ev);
}
void _ORBIT_skel_small_nitpicker_new_view(POA_nitpicker *_o_servant, gpointer _o_retval,gpointer *_o_args,CORBA_Context _o_ctx,CORBA_Environment *_o_ev,
CORBA_long (*_impl_new_view)(PortableServer_Servant _servant, const CORBA_long buf_id, CORBA_Environment *ev)) {
@@ -195,30 +195,30 @@ TC_Nitevent,{0, 0, Nitevent__imethods, FALSE},
{1, 1, Nitevent__base_itypes, FALSE}
};
-static ORBit_IArg nitpicker_add_client__arginfo [] = {
- { TC_CORBA_long, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"max_views" },
- { TC_CORBA_long, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"max_buffers" }
+static ORBit_IArg nitpicker_initialize_client__arginfo [] = {
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"max_views" },
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"max_buffers" }
};
static ORBit_IArg nitpicker_get_screen_info__arginfo [] = {
- { TC_CORBA_long, ORBit_I_ARG_OUT | ORBit_I_COMMON_FIXED_SIZE, (char *)"w" },
- { TC_CORBA_long, ORBit_I_ARG_OUT | ORBit_I_COMMON_FIXED_SIZE, (char *)"h" },
- { TC_CORBA_long, ORBit_I_ARG_OUT | ORBit_I_COMMON_FIXED_SIZE, (char *)"depth" },
- { TC_CORBA_long, ORBit_I_ARG_OUT | ORBit_I_COMMON_FIXED_SIZE, (char *)"mode" }
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_OUT | ORBit_I_COMMON_FIXED_SIZE, (char *)"w" },
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_OUT | ORBit_I_COMMON_FIXED_SIZE, (char *)"h" },
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_OUT | ORBit_I_COMMON_FIXED_SIZE, (char *)"depth" },
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_OUT | ORBit_I_COMMON_FIXED_SIZE, (char *)"mode" }
};
static ORBit_IArg nitpicker_import_buffer__arginfo [] = {
{ TC_CORBA_string, ORBit_I_ARG_IN , (char *)"ds" },
- { TC_CORBA_long, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"w" },
- { TC_CORBA_long, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"h" }
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"w" },
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"h" }
};
static ORBit_IArg nitpicker_remove_buffer__arginfo [] = {
{ TC_CORBA_long, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"buf_id" }
};
static ORBit_IArg nitpicker_refresh__arginfo [] = {
{ TC_CORBA_long, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"buf_id" },
- { TC_CORBA_long, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"x" },
- { TC_CORBA_long, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"y" },
- { TC_CORBA_long, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"w" },
- { TC_CORBA_long, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"h" }
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"x" },
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"y" },
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"w" },
+ { TC_CORBA_unsigned_short, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"h" }
};
static ORBit_IArg nitpicker_new_view__arginfo [] = {
{ TC_CORBA_long, ORBit_I_ARG_IN | ORBit_I_COMMON_FIXED_SIZE, (char *)"buf_id" }
@@ -273,10 +273,10 @@ ORBit_IMethod nitpicker__imethods [] = {
0| ORBit_I_COMMON_FIXED_SIZE
}
, {
- { 2, 2, nitpicker_add_client__arginfo, FALSE },
+ { 2, 2, nitpicker_initialize_client__arginfo, FALSE },
{ 0, 0, NULL, FALSE },
{ 0, 0, NULL, FALSE },
- TC_CORBA_long, (char *)"add_client", 10,
+ TC_CORBA_long, (char *)"initialize_client", 17,
0| ORBit_I_COMMON_FIXED_SIZE
}
, {
diff --git a/nitpicker-skelimpl.c b/nitpicker-skelimpl.c
index 62b70c1..cf82391 100644
--- a/nitpicker-skelimpl.c
+++ b/nitpicker-skelimpl.c
@@ -56,12 +56,12 @@ impl_nitpicker_kill_graphics(impl_POA_nitpicker *servant,
CORBA_Environment *ev);
#endif
-#if !defined(_decl_impl_nitpicker_add_client_)
-#define _decl_impl_nitpicker_add_client_ 1
+#if !defined(_decl_impl_nitpicker_initialize_client_)
+#define _decl_impl_nitpicker_initialize_client_ 1
static CORBA_long
-impl_nitpicker_add_client(impl_POA_nitpicker *servant,
-const CORBA_long max_views,
-const CORBA_long max_buffers,
+impl_nitpicker_initialize_client(impl_POA_nitpicker *servant,
+const CORBA_unsigned_short max_views,
+const CORBA_unsigned_short max_buffers,
CORBA_Environment *ev);
#endif
@@ -69,10 +69,10 @@ CORBA_Environment *ev);
#define _decl_impl_nitpicker_get_screen_info_ 1
static CORBA_long
impl_nitpicker_get_screen_info(impl_POA_nitpicker *servant,
-CORBA_long* w,
-CORBA_long* h,
-CORBA_long* depth,
-CORBA_long* mode,
+CORBA_unsigned_short* w,
+CORBA_unsigned_short* h,
+CORBA_unsigned_short* depth,
+CORBA_unsigned_short* mode,
CORBA_Environment *ev);
#endif
@@ -81,8 +81,8 @@ CORBA_Environment *ev);
static CORBA_long
impl_nitpicker_import_buffer(impl_POA_nitpicker *servant,
const CORBA_char * ds,
-const CORBA_long w,
-const CORBA_long h,
+const CORBA_unsigned_short w,
+const CORBA_unsigned_short h,
CORBA_Environment *ev);
#endif
@@ -99,10 +99,10 @@ CORBA_Environment *ev);
static void
impl_nitpicker_refresh(impl_POA_nitpicker *servant,
const CORBA_long buf_id,
-const CORBA_long x,
-const CORBA_long y,
-const CORBA_long w,
-const CORBA_long h,
+const CORBA_unsigned_short x,
+const CORBA_unsigned_short y,
+const CORBA_unsigned_short w,
+const CORBA_unsigned_short h,
CORBA_Environment *ev);
#endif
@@ -208,7 +208,7 @@ static POA_nitpicker__epv impl_nitpicker_epv = {
NULL, /* _private */
(gpointer)&impl_nitpicker_alive,
(gpointer)&impl_nitpicker_kill_graphics,
-(gpointer)&impl_nitpicker_add_client,
+(gpointer)&impl_nitpicker_initialize_client,
(gpointer)&impl_nitpicker_get_screen_info,
(gpointer)&impl_nitpicker_import_buffer,
(gpointer)&impl_nitpicker_remove_buffer,
@@ -380,16 +380,16 @@ return retval;
}
#endif
-#if !defined(_impl_nitpicker_add_client_)
-#define _impl_nitpicker_add_client_ 1
+#if !defined(_impl_nitpicker_initialize_client_)
+#define _impl_nitpicker_initialize_client_ 1
static CORBA_long
-impl_nitpicker_add_client(impl_POA_nitpicker *servant,
-const CORBA_long max_views,
-const CORBA_long max_buffers,
+impl_nitpicker_initialize_client(impl_POA_nitpicker *servant,
+const CORBA_unsigned_short max_views,
+const CORBA_unsigned_short max_buffers,
CORBA_Environment *ev)
{
/* ------ insert method code here ------ */
- return nitpicker_add_client( CONVERT_SERVANT(servant), max_views, max_buffers, ev );
+ return nitpicker_initialize_client( CONVERT_SERVANT(servant), max_views, max_buffers, ev );
/* ------ ---------- end ------------ ------ */
}
#endif
@@ -398,10 +398,10 @@ CORBA_Environment *ev)
#define _impl_nitpicker_get_screen_info_ 1
static CORBA_long
impl_nitpicker_get_screen_info(impl_POA_nitpicker *servant,
-CORBA_long* w,
-CORBA_long* h,
-CORBA_long* depth,
-CORBA_long* mode,
+CORBA_unsigned_short* w,
+CORBA_unsigned_short* h,
+CORBA_unsigned_short* depth,
+CORBA_unsigned_short* mode,
CORBA_Environment *ev)
{
/* ------ insert method code here ------ */
@@ -417,8 +417,8 @@ return 0;
static CORBA_long
impl_nitpicker_import_buffer(impl_POA_nitpicker *servant,
const CORBA_char * ds,
-const CORBA_long w,
-const CORBA_long h,
+const CORBA_unsigned_short w,
+const CORBA_unsigned_short h,
CORBA_Environment *ev)
{
/* ------ insert method code here ------ */
@@ -445,10 +445,10 @@ CORBA_Environment *ev)
static void
impl_nitpicker_refresh(impl_POA_nitpicker *servant,
const CORBA_long buf_id,
-const CORBA_long x,
-const CORBA_long y,
-const CORBA_long w,
-const CORBA_long h,
+const CORBA_unsigned_short x,
+const CORBA_unsigned_short y,
+const CORBA_unsigned_short w,
+const CORBA_unsigned_short h,
CORBA_Environment *ev)
{
/* ------ insert method code here ------ */
diff --git a/nitpicker-skels.c b/nitpicker-skels.c
index e9b6348..f203ebb 100644
--- a/nitpicker-skels.c
+++ b/nitpicker-skels.c
@@ -36,22 +36,11 @@ const char *opname,gpointer *m_data, gpointer *impl)
{
switch(opname[0]) {
case 'a':
-switch(opname[1]) {
-case 'd':
-if(strcmp((opname + 2), "d_client")) break;
-*impl = (gpointer)servant->vepv->nitpicker_epv->add_client;
-{ORBit_IInterface *volatile _t_=&nitpicker__iinterface;*m_data = (gpointer)&_t_->methods._buffer [2];}
-return (ORBitSmallSkeleton)_ORBIT_skel_small_nitpicker_add_client;
-break;
-case 'l':
-if(strcmp((opname + 2), "ive")) break;
+if(strcmp((opname + 1), "live")) break;
*impl = (gpointer)servant->vepv->nitpicker_epv->alive;
{ORBit_IInterface *volatile _t_=&nitpicker__iinterface;*m_data = (gpointer)&_t_->methods._buffer [0];}
return (ORBitSmallSkeleton)_ORBIT_skel_small_nitpicker_alive;
break;
-default: break;
-}
-break;
case 'd':
if(strcmp((opname + 1), "estroy_view")) break;
*impl = (gpointer)servant->vepv->nitpicker_epv->destroy_view;
@@ -65,11 +54,22 @@ if(strcmp((opname + 1), "et_screen_info")) break;
return (ORBitSmallSkeleton)_ORBIT_skel_small_nitpicker_get_screen_info;
break;
case 'i':
-if(strcmp((opname + 1), "mport_buffer")) break;
+switch(opname[1]) {
+case 'm':
+if(strcmp((opname + 2), "port_buffer")) break;
*impl = (gpointer)servant->vepv->nitpicker_epv->import_buffer;
{ORBit_IInterface *volatile _t_=&nitpicker__iinterface;*m_data = (gpointer)&_t_->methods._buffer [4];}
return (ORBitSmallSkeleton)_ORBIT_skel_small_nitpicker_import_buffer;
break;
+case 'n':
+if(strcmp((opname + 2), "itialize_client")) break;
+*impl = (gpointer)servant->vepv->nitpicker_epv->initialize_client;
+{ORBit_IInterface *volatile _t_=&nitpicker__iinterface;*m_data = (gpointer)&_t_->methods._buffer [2];}
+return (ORBitSmallSkeleton)_ORBIT_skel_small_nitpicker_initialize_client;
+break;
+default: break;
+}
+break;
case 'k':
if(strcmp((opname + 1), "ill_graphics")) break;
*impl = (gpointer)servant->vepv->nitpicker_epv->kill_graphics;
diff --git a/nitpicker-stubs.c b/nitpicker-stubs.c
index 5df6161..9a71689 100644
--- a/nitpicker-stubs.c
+++ b/nitpicker-stubs.c
@@ -20,17 +20,17 @@ ORBit_c_stub_invoke (_obj, &nitpicker__iinterface.methods, 1, &_ORBIT_retval, NU
return _ORBIT_retval;
}
-CORBA_long nitpicker_add_client(nitpicker _obj, const CORBA_long max_views, const CORBA_long max_buffers, CORBA_Environment *ev){
+CORBA_long nitpicker_initialize_client(nitpicker _obj, const CORBA_unsigned_short max_views, const CORBA_unsigned_short max_buffers, CORBA_Environment *ev){
CORBA_long _ORBIT_retval;
gpointer _args[2];
_args[0] = (gpointer)&max_views;
_args[1] = (gpointer)&max_buffers;
-ORBit_c_stub_invoke (_obj, &nitpicker__iinterface.methods, 2, &_ORBIT_retval, _args, NULL, ev, nitpicker__classid, G_STRUCT_OFFSET (POA_nitpicker__epv, add_client),
-(ORBitSmallSkeleton) _ORBIT_skel_small_nitpicker_add_client);
+ORBit_c_stub_invoke (_obj, &nitpicker__iinterface.methods, 2, &_ORBIT_retval, _args, NULL, ev, nitpicker__classid, G_STRUCT_OFFSET (POA_nitpicker__epv, initialize_client),
+(ORBitSmallSkeleton) _ORBIT_skel_small_nitpicker_initialize_client);
return _ORBIT_retval;
}
-CORBA_long nitpicker_get_screen_info(nitpicker _obj, CORBA_long* w, CORBA_long* h, CORBA_long* depth, CORBA_long* mode, CORBA_Environment *ev){
+CORBA_long nitpicker_get_screen_info(nitpicker _obj, CORBA_unsigned_short* w, CORBA_unsigned_short* h, CORBA_unsigned_short* depth, CORBA_unsigned_short* mode, CORBA_Environment *ev){
CORBA_long _ORBIT_retval;
gpointer _args[4];
_args[0] = &w;
@@ -42,7 +42,7 @@ ORBit_c_stub_invoke (_obj, &nitpicker__iinterface.methods, 3, &_ORBIT_retval, _a
return _ORBIT_retval;
}
-CORBA_long nitpicker_import_buffer(nitpicker _obj, const CORBA_char * ds, const CORBA_long w, const CORBA_long h, CORBA_Environment *ev){
+CORBA_long nitpicker_import_buffer(nitpicker _obj, const CORBA_char * ds, const CORBA_unsigned_short w, const CORBA_unsigned_short h, CORBA_Environment *ev){
CORBA_long _ORBIT_retval;
gpointer _args[3];
_args[0] = (gpointer)&ds;
@@ -60,7 +60,7 @@ ORBit_c_stub_invoke (_obj, &nitpicker__iinterface.methods, 5, NULL, _args, NULL,
(ORBitSmallSkeleton) _ORBIT_skel_small_nitpicker_remove_buffer);
}
-void nitpicker_refresh(nitpicker _obj, const CORBA_long buf_id, const CORBA_long x, const CORBA_long y, const CORBA_long w, const CORBA_long h, CORBA_Environment *ev){
+void nitpicker_refresh(nitpicker _obj, const CORBA_long buf_id, const CORBA_unsigned_short x, const CORBA_unsigned_short y, const CORBA_unsigned_short w, const CORBA_unsigned_short h, CORBA_Environment *ev){
gpointer _args[5];
_args[0] = (gpointer)&buf_id;
_args[1] = (gpointer)&x;
diff --git a/nitpicker-test-client.c b/nitpicker-test-client.c
index f4d8d29..9788661 100644
--- a/nitpicker-test-client.c
+++ b/nitpicker-test-client.c
@@ -125,15 +125,11 @@ client_run (nitpicker service,
CORBA_Environment *ev)
{
int ret=0;
-// const char donation_ds_name_template[] = "/testnit-%d-donation";
- const int max_getpid_len = 21; // Enough for a 64-bit pid.
-// const int max_donation_name_len = strlen(donation_ds_name_template) + max_getpid_len;
char buffer_ds[SHARED_BUFFER_INFO_NAME_LENGTH];
int buffer_fd; // File descriptor
int buffer_size;
int buf_id;
unsigned char *addr;
-// CORBA_Object myself;
int j; // Used in for loop
/*
@@ -145,8 +141,8 @@ client_run (nitpicker service,
g_print( "nitpicker_alive returned %d\n", ret );
if (etk_raised_exception (ev)) return;
- ret = nitpicker_add_client( service, 10, 10, ev );
- printf( "nitpicker_add_client returned %d\n", ret );
+ ret = nitpicker_initialize_client( service, 10, 10, ev );
+ printf( "nitpicker_initialize_client returned %d\n", ret );
nitpicker_get_screen_info( service, &scr_width, &scr_height,
&scr_depth, &scr_mode, ev );
diff --git a/nitpicker.h b/nitpicker.h
index 8e49510..a44bfcb 100644
--- a/nitpicker.h
+++ b/nitpicker.h
@@ -120,11 +120,11 @@ typedef struct {
void *_private;
CORBA_long (*alive)(PortableServer_Servant _servant, CORBA_Environment *ev);
CORBA_long (*kill_graphics)(PortableServer_Servant _servant, CORBA_Environment *ev);
-CORBA_long (*add_client)(PortableServer_Servant _servant, const CORBA_long max_views, const CORBA_long max_buffers, CORBA_Environment *ev);
-CORBA_long (*get_screen_info)(PortableServer_Servant _servant, CORBA_long* w, CORBA_long* h, CORBA_long* depth, CORBA_long* mode, CORBA_Environment *ev);
-CORBA_long (*import_buffer)(PortableServer_Servant _servant, const CORBA_char * ds, const CORBA_long w, const CORBA_long h, CORBA_Environment *ev);
+CORBA_long (*initialize_client)(PortableServer_Servant _servant, const CORBA_unsigned_short max_views, const CORBA_unsigned_short max_buffers, CORBA_Environment *ev);
+CORBA_long (*get_screen_info)(PortableServer_Servant _servant, CORBA_unsigned_short* w, CORBA_unsigned_short* h, CORBA_unsigned_short* depth, CORBA_unsigned_short* mode, CORBA_Environment *ev);
+CORBA_long (*import_buffer)(PortableServer_Servant _servant, const CORBA_char * ds, const CORBA_unsigned_short w, const CORBA_unsigned_short h, CORBA_Environment *ev);
void (*remove_buffer)(PortableServer_Servant _servant, const CORBA_long buf_id, CORBA_Environment *ev);
-void (*refresh)(PortableServer_Servant _servant, const CORBA_long buf_id, const CORBA_long x, const CORBA_long y, const CORBA_long w, const CORBA_long h, CORBA_Environment *ev);
+void (*refresh)(PortableServer_Servant _servant, const CORBA_long buf_id, const CORBA_unsigned_short x, const CORBA_unsigned_short y, const CORBA_unsigned_short w, const CORBA_unsigned_short h, CORBA_Environment *ev);
CORBA_long (*new_view)(PortableServer_Servant _servant, const CORBA_long buf_id, CORBA_Environment *ev);
void (*destroy_view)(PortableServer_Servant _servant, const CORBA_long view_id, CORBA_Environment *ev);
CORBA_long (*set_view_port)(PortableServer_Servant _servant, const CORBA_long view_id, const CORBA_long buf_x, const CORBA_long buf_y, const CORBA_long x, const CORBA_long y, const CORBA_long w, const CORBA_long h, const CORBA_long do_redraw, CORBA_Environment *ev);
@@ -148,11 +148,11 @@ extern void POA_nitpicker__fini(PortableServer_Servant servant, CORBA_Environmen
/** skel prototypes **/
void _ORBIT_skel_small_nitpicker_alive(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, CORBA_long (*_impl_alive)(PortableServer_Servant _servant, CORBA_Environment *ev));
void _ORBIT_skel_small_nitpicker_kill_graphics(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, CORBA_long (*_impl_kill_graphics)(PortableServer_Servant _servant, CORBA_Environment *ev));
-void _ORBIT_skel_small_nitpicker_add_client(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, CORBA_long (*_impl_add_client)(PortableServer_Servant _servant, const CORBA_long max_views, const CORBA_long max_buffers, CORBA_Environment *ev));
-void _ORBIT_skel_small_nitpicker_get_screen_info(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, CORBA_long (*_impl_get_screen_info)(PortableServer_Servant _servant, CORBA_long* w, CORBA_long* h, CORBA_long* depth, CORBA_long* mode, CORBA_Environment *ev));
-void _ORBIT_skel_small_nitpicker_import_buffer(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, CORBA_long (*_impl_import_buffer)(PortableServer_Servant _servant, const CORBA_char * ds, const CORBA_long w, const CORBA_long h, CORBA_Environment *ev));
+void _ORBIT_skel_small_nitpicker_initialize_client(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, CORBA_long (*_impl_initialize_client)(PortableServer_Servant _servant, const CORBA_unsigned_short max_views, const CORBA_unsigned_short max_buffers, CORBA_Environment *ev));
+void _ORBIT_skel_small_nitpicker_get_screen_info(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, CORBA_long (*_impl_get_screen_info)(PortableServer_Servant _servant, CORBA_unsigned_short* w, CORBA_unsigned_short* h, CORBA_unsigned_short* depth, CORBA_unsigned_short* mode, CORBA_Environment *ev));
+void _ORBIT_skel_small_nitpicker_import_buffer(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, CORBA_long (*_impl_import_buffer)(PortableServer_Servant _servant, const CORBA_char * ds, const CORBA_unsigned_short w, const CORBA_unsigned_short h, CORBA_Environment *ev));
void _ORBIT_skel_small_nitpicker_remove_buffer(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, void (*_impl_remove_buffer)(PortableServer_Servant _servant, const CORBA_long buf_id, CORBA_Environment *ev));
-void _ORBIT_skel_small_nitpicker_refresh(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, void (*_impl_refresh)(PortableServer_Servant _servant, const CORBA_long buf_id, const CORBA_long x, const CORBA_long y, const CORBA_long w, const CORBA_long h, CORBA_Environment *ev));
+void _ORBIT_skel_small_nitpicker_refresh(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, void (*_impl_refresh)(PortableServer_Servant _servant, const CORBA_long buf_id, const CORBA_unsigned_short x, const CORBA_unsigned_short y, const CORBA_unsigned_short w, const CORBA_unsigned_short h, CORBA_Environment *ev));
void _ORBIT_skel_small_nitpicker_new_view(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, CORBA_long (*_impl_new_view)(PortableServer_Servant _servant, const CORBA_long buf_id, CORBA_Environment *ev));
void _ORBIT_skel_small_nitpicker_destroy_view(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, void (*_impl_destroy_view)(PortableServer_Servant _servant, const CORBA_long view_id, CORBA_Environment *ev));
void _ORBIT_skel_small_nitpicker_set_view_port(POA_nitpicker *_ORBIT_servant, gpointer _ORBIT_retval, gpointer *_ORBIT_args, CORBA_Context ctx,CORBA_Environment *ev, CORBA_long (*_impl_set_view_port)(PortableServer_Servant _servant, const CORBA_long view_id, const CORBA_long buf_x, const CORBA_long buf_y, const CORBA_long x, const CORBA_long y, const CORBA_long w, const CORBA_long h, const CORBA_long do_redraw, CORBA_Environment *ev));
@@ -164,11 +164,11 @@ void _ORBIT_skel_small_nitpicker_set_mousemode(POA_nitpicker *_ORBIT_servant, gp
/** stub prototypes **/
CORBA_long nitpicker_alive(nitpicker _obj, CORBA_Environment *ev);
CORBA_long nitpicker_kill_graphics(nitpicker _obj, CORBA_Environment *ev);
-CORBA_long nitpicker_add_client(nitpicker _obj, const CORBA_long max_views, const CORBA_long max_buffers, CORBA_Environment *ev);
-CORBA_long nitpicker_get_screen_info(nitpicker _obj, CORBA_long* w, CORBA_long* h, CORBA_long* depth, CORBA_long* mode, CORBA_Environment *ev);
-CORBA_long nitpicker_import_buffer(nitpicker _obj, const CORBA_char * ds, const CORBA_long w, const CORBA_long h, CORBA_Environment *ev);
+CORBA_long nitpicker_initialize_client(nitpicker _obj, const CORBA_unsigned_short max_views, const CORBA_unsigned_short max_buffers, CORBA_Environment *ev);
+CORBA_long nitpicker_get_screen_info(nitpicker _obj, CORBA_unsigned_short* w, CORBA_unsigned_short* h, CORBA_unsigned_short* depth, CORBA_unsigned_short* mode, CORBA_Environment *ev);
+CORBA_long nitpicker_import_buffer(nitpicker _obj, const CORBA_char * ds, const CORBA_unsigned_short w, const CORBA_unsigned_short h, CORBA_Environment *ev);
void nitpicker_remove_buffer(nitpicker _obj, const CORBA_long buf_id, CORBA_Environment *ev);
-void nitpicker_refresh(nitpicker _obj, const CORBA_long buf_id, const CORBA_long x, const CORBA_long y, const CORBA_long w, const CORBA_long h, CORBA_Environment *ev);
+void nitpicker_refresh(nitpicker _obj, const CORBA_long buf_id, const CORBA_unsigned_short x, const CORBA_unsigned_short y, const CORBA_unsigned_short w, const CORBA_unsigned_short h, CORBA_Environment *ev);
CORBA_long nitpicker_new_view(nitpicker _obj, const CORBA_long buf_id, CORBA_Environment *ev);
void nitpicker_destroy_view(nitpicker _obj, const CORBA_long view_id, CORBA_Environment *ev);
CORBA_long nitpicker_set_view_port(nitpicker _obj, const CORBA_long view_id, const CORBA_long buf_x, const CORBA_long buf_y, const CORBA_long x, const CORBA_long y, const CORBA_long w, const CORBA_long h, const CORBA_long do_redraw, CORBA_Environment *ev);
@@ -207,7 +207,7 @@ ORBit_IMethod nitpicker__imethods[nitpicker_IMETHODS_LEN];
typedef enum {
nitpicker_alive__imethods_index,
nitpicker_kill_graphics__imethods_index,
- nitpicker_add_client__imethods_index,
+ nitpicker_initialize_client__imethods_index,
nitpicker_get_screen_info__imethods_index,
nitpicker_import_buffer__imethods_index,
nitpicker_remove_buffer__imethods_index,
diff --git a/nitpicker.idl b/nitpicker.idl
index cd95727..4e259da 100644
--- a/nitpicker.idl
+++ b/nitpicker.idl
@@ -50,16 +50,16 @@ interface nitpicker {
* requested number of views and buffers, or
* -2 dataspace is invalid
*/
- long add_client(in long max_views, in long max_buffers);
+ long initialize_client(in unsigned short max_views, in unsigned short max_buffers);
/*** REQUEST INFORMATION ABOUT PHYSICAL SCREEN ***/
// WARNING: Note that in CORBA IDL, "out" doesn't include the *.
- long get_screen_info(out long w, out long h,
- out long depth, out long mode);
+ long get_screen_info(out unsigned short w, out unsigned short h,
+ out unsigned short depth, out unsigned short mode);
/*** INJECT NEW BUFFER ***/
- long import_buffer(in string ds, in long w, in long h);
+ long import_buffer(in string ds, in unsigned short w, in unsigned short h);
/*** REMOVE BUFFER ***/
@@ -67,7 +67,7 @@ interface nitpicker {
/*** REFRESH GRAPHICAL REPRESENTATION OF THE NEW BUFFER ***/
- void refresh(in long buf_id, in long x, in long y, in long w, in long h);
+ void refresh(in long buf_id, in unsigned short x, in unsigned short y, in unsigned short w, in unsigned short h);
/*** CREATE A NEW VIEW AT A BUFFER ***
diff --git a/view.c b/view.c
index 734add9..4377174 100644
--- a/view.c
+++ b/view.c
@@ -753,9 +753,9 @@ void activate_view(view *nv) {
***************************/
/*** INTERFACE: CREATE NEW VIEW ***/
-// long nitpicker_new_view( nitpicker _obj, int buf_id, const Nitevent listener, CORBA_Environment *ev){
-// int nitpicker_new_view( nitpicker _obj, const long buf_id, CORBA_Environment *ev){
-int nitpicker_new_view( nitpicker _obj, const CORBA_long buf_id, CORBA_Environment *ev ){
+// long nitpicker_new_view( nitpicker clientid, int buf_id, const Nitevent listener, CORBA_Environment *ev){
+// int nitpicker_new_view( nitpicker clientid, const long buf_id, CORBA_Environment *ev){
+int nitpicker_new_view( nitpicker clientid, const CORBA_long buf_id, CORBA_Environment *ev ){
int id;
client *c;
@@ -763,7 +763,7 @@ int nitpicker_new_view( nitpicker _obj, const CORBA_long buf_id, CORBA_Environme
Nitevent listener = (void *) 0; // TODO: Remove listener
/* look up client data structure */
- if (!(c = find_client(_obj))) return -1;
+ if (!(c = find_client(clientid))) return -1;
TRY((id = ALLOC_ID(c->views, c->max_views)) < 0, "Unable to allocate new view id");
@@ -771,7 +771,7 @@ int nitpicker_new_view( nitpicker _obj, const CORBA_long buf_id, CORBA_Environme
c->views[id].state = STATE_ALLOCATED;
c->views[id].flags = VIEW_FLAGS_BORDER | VIEW_FLAGS_LABEL;
//need to fix assignment
- c->views[id].owner = _obj;
+ c->views[id].owner = clientid;
c->views[id].token = id;
c->views[id].lw = 32;
c->views[id].lh = 16;
@@ -784,7 +784,7 @@ int nitpicker_new_view( nitpicker _obj, const CORBA_long buf_id, CORBA_Environme
if (listener) c->views[id].listener = (int) listener;
printf("nitpicker_internal_buffer returned buf_id=%d\n", buf_id);
- if ((b = lookup_buffer(_obj, buf_id))) {
+ if ((b = lookup_buffer(clientid, buf_id))) {
printf("internal_buffer returned buf_id=%d\n", b);
/* assign buffer to view */
c->views[id].buf = b;
@@ -804,13 +804,13 @@ int nitpicker_new_view( nitpicker _obj, const CORBA_long buf_id, CORBA_Environme
/*** INTERFACE: DESTROY VIEW ***/
-void nitpicker_destroy_view( nitpicker _obj, int view_id, CORBA_Environment *ev) {
+void nitpicker_destroy_view( nitpicker clientid, int view_id, CORBA_Environment *ev) {
int x1, y1, x2, y2;
view *v;
- client *c = find_client(_obj);
+ client *c = find_client(clientid);
- if (!(v = lookup_view(_obj, view_id))) return;
+ if (!(v = lookup_view(clientid, view_id))) return;
/* remember original view location */
x1 = v->x - BORDER; x2 = v->x + v->w - 1 + BORDER;
@@ -840,12 +840,12 @@ void nitpicker_destroy_view( nitpicker _obj, int view_id, CORBA_Environment *ev)
/*** INTERFACE: SET VIEW POSITION, SIZE, AND BUFFER OFFSET ***/
-int nitpicker_set_view_port( nitpicker _obj, int view_id, int buf_x, int buf_y, int x, int y, int w, int h, int do_redraw, CORBA_Environment *ev ) {
+int nitpicker_set_view_port( nitpicker clientid, int view_id, int buf_x, int buf_y, int x, int y, int w, int h, int do_redraw, CORBA_Environment *ev ) {
int x1, y1, x2, y2;
view *v;
- if (!(v = lookup_view(_obj, view_id))) return NITPICKER_ERR_ILLEGAL_ID;
+ if (!(v = lookup_view(clientid, view_id))) return NITPICKER_ERR_ILLEGAL_ID;
/* remember old position */
x1 = v->x; x2 = v->x + v->w - 1;
@@ -902,13 +902,13 @@ int nitpicker_set_view_port( nitpicker _obj, int view_id, int buf_x, int buf_y,
/*** INTERFACE: POSITION VIEW IN VIEW STACK ***/
-int nitpicker_stack_view( nitpicker _obj, int view_id,int neighbor_id, int behind, int do_redraw, CORBA_Environment *ev) {
+int nitpicker_stack_view( nitpicker clientid, int view_id,int neighbor_id, int behind, int do_redraw, CORBA_Environment *ev) {
view *v, *nv, *lv;
int done = 0;
- if (!(v = lookup_view(_obj, view_id))) return NITPICKER_ERR_ILLEGAL_ID;
+ if (!(v = lookup_view(clientid, view_id))) return NITPICKER_ERR_ILLEGAL_ID;
- nv = (neighbor_id == -1) ? NULL : lookup_view(_obj, neighbor_id);
+ nv = (neighbor_id == -1) ? NULL : lookup_view(clientid, neighbor_id);
/* remove view from original view stack position */
UNCHAIN_LISTELEMENT(view, &first_view, next, v);
@@ -961,8 +961,8 @@ view *v, *nv, *lv;
}
/*** INTERFACE: GET SCRREN INFO ***/
-int nitpicker_get_screen_info(nitpicker _obj, CORBA_long* w,
-CORBA_long* h, CORBA_long *depth, CORBA_long* mode, CORBA_Environment *ev) {
+int nitpicker_get_screen_info( nitpicker clientid, unsigned short *w, unsigned short *h,
+ unsigned short *depth, unsigned short *mode, CORBA_Environment *ev) {
*w = screen_width;
*h = screen_height;
*depth = scr_depth; /* TODO: Calculate mode and depth */
@@ -971,11 +971,11 @@ CORBA_long* h, CORBA_long *depth, CORBA_long* mode, CORBA_Environment *ev) {
/*** LONGERFACE: REDEFINE VIEW TITLE ***/
-int nitpicker_set_view_title( nitpicker _obj, int view_id, const char * title, CORBA_Environment *ev) {
+int nitpicker_set_view_title( nitpicker clientid, int view_id, const char * title, CORBA_Environment *ev) {
view *v;
- if (!(v = lookup_view(_obj, view_id))) return NITPICKER_ERR_ILLEGAL_ID;
+ if (!(v = lookup_view(clientid, view_id))) return NITPICKER_ERR_ILLEGAL_ID;
/* set new title */
char *blank = " ";
@@ -992,14 +992,14 @@ int nitpicker_set_view_title( nitpicker _obj, int view_id, const char * title, C
/*** LONGERFACE: SET MOUSE OPERATING MODE ***/
-int nitpicker_set_background( nitpicker _obj, int view_id, CORBA_Environment *ev ){
+int nitpicker_set_background( nitpicker clientid, int view_id, CORBA_Environment *ev ){
- client *c = find_client(_obj);
+ client *c = find_client(clientid);
if (!c) return NITPICKER_ERR_ILLEGAL_ID;
/* define new background for the client (invalid view_id -> no background) */
- if ((c->bg = lookup_view(_obj, view_id))) {
+ if ((c->bg = lookup_view(clientid, view_id))) {
view *cv;
@@ -1020,7 +1020,7 @@ int nitpicker_set_background( nitpicker _obj, int view_id, CORBA_Environment *ev
/*** LONGERFACE: SET MOUSE OPERATING MODE ***/
-int nitpicker_set_mousemode( nitpicker _obj, int view_id, int mode, CORBA_Environment *ev) {
+int nitpicker_set_mousemode( nitpicker clientid, int view_id, int mode, CORBA_Environment *ev) {
return NITPICKER_OK;