mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2024-12-30 10:26:58 +01:00
Don't typedef array; make array field of struct.
This commit is contained in:
parent
100598a35f
commit
7cf02f322e
1 changed files with 6 additions and 6 deletions
|
@ -81,7 +81,7 @@ ctlsFromState( PalmAppGlobals* globals, ConnsDlgState* state )
|
||||||
if ( '\0' == addr->u.bt.hostName[0] ) {
|
if ( '\0' == addr->u.bt.hostName[0] ) {
|
||||||
XP_BtAddrStr tmp;
|
XP_BtAddrStr tmp;
|
||||||
palm_bt_addrString( globals, &addr->u.bt.btAddr, &tmp );
|
palm_bt_addrString( globals, &addr->u.bt.btAddr, &tmp );
|
||||||
setFieldStr( XW_CONNS_BT_HOSTFIELD_ID, tmp );
|
setFieldStr( XW_CONNS_BT_HOSTFIELD_ID, tmp.chars );
|
||||||
} else {
|
} else {
|
||||||
setFieldStr( XW_CONNS_BT_HOSTFIELD_ID, addr->u.bt.hostName );
|
setFieldStr( XW_CONNS_BT_HOSTFIELD_ID, addr->u.bt.hostName );
|
||||||
}
|
}
|
||||||
|
@ -111,9 +111,9 @@ stateFromCtls( ConnsDlgState* state )
|
||||||
strFromField( XW_CONNS_BT_HOSTFIELD_ID, addr->u.bt.hostName,
|
strFromField( XW_CONNS_BT_HOSTFIELD_ID, addr->u.bt.hostName,
|
||||||
sizeof(addr->u.bt.hostName) );
|
sizeof(addr->u.bt.hostName) );
|
||||||
/* Not exactly from a control... */
|
/* Not exactly from a control... */
|
||||||
XP_MEMCPY( &addr->u.bt.btAddr, state->btAddr,
|
XP_MEMCPY( &addr->u.bt.btAddr, &state->btAddr,
|
||||||
sizeof(addr->u.bt.btAddr) );
|
sizeof(addr->u.bt.btAddr) );
|
||||||
LOG_HEX( addr->u.bt.btAddr, sizeof(addr->u.bt.btAddr), __FUNCTION__ );
|
LOG_HEX( &addr->u.bt.btAddr, sizeof(addr->u.bt.btAddr), __FUNCTION__ );
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -222,8 +222,8 @@ browseForDeviceName( PalmAppGlobals* globals, ConnsDlgState* state )
|
||||||
XP_BtAddr btAddr;
|
XP_BtAddr btAddr;
|
||||||
if ( palm_bt_browse_device( globals, &btAddr, buf, sizeof( buf ) ) ) {
|
if ( palm_bt_browse_device( globals, &btAddr, buf, sizeof( buf ) ) ) {
|
||||||
setFieldStr( XW_CONNS_BT_HOSTFIELD_ID, buf );
|
setFieldStr( XW_CONNS_BT_HOSTFIELD_ID, buf );
|
||||||
XP_MEMCPY( state->btAddr, &btAddr, sizeof(state->btAddr) );
|
XP_MEMCPY( &state->btAddr, &btAddr, sizeof(state->btAddr) );
|
||||||
LOG_HEX( state->btAddr, sizeof(state->btAddr), __FUNCTION__ );
|
LOG_HEX( &state->btAddr, sizeof(state->btAddr), __FUNCTION__ );
|
||||||
}
|
}
|
||||||
} /* browseForDeviceName */
|
} /* browseForDeviceName */
|
||||||
#endif
|
#endif
|
||||||
|
@ -256,7 +256,7 @@ ConnsFormHandleEvent( EventPtr event )
|
||||||
state->addr =
|
state->addr =
|
||||||
(CommsAddrRec*)globals->dlgParams[CONNS_PARAM_ADDR_INDEX];
|
(CommsAddrRec*)globals->dlgParams[CONNS_PARAM_ADDR_INDEX];
|
||||||
state->isNewGame = globals->isNewGame;
|
state->isNewGame = globals->isNewGame;
|
||||||
XP_MEMCPY( state->btAddr, &state->addr->u.bt.btAddr,
|
XP_MEMCPY( &state->btAddr, &state->addr->u.bt.btAddr,
|
||||||
sizeof(state->btAddr) );
|
sizeof(state->btAddr) );
|
||||||
|
|
||||||
/* setup connection popup */
|
/* setup connection popup */
|
||||||
|
|
Loading…
Reference in a new issue