aboutsummaryrefslogtreecommitdiff
path: root/externals/grill/flext/source/flatom_pr.cpp
diff options
context:
space:
mode:
authorThomas Grill <xovo@users.sourceforge.net>2003-01-15 04:37:19 +0000
committerThomas Grill <xovo@users.sourceforge.net>2003-01-15 04:37:19 +0000
commitb00be027fe91e9ae5a19f53b6c1fd0245b4d4bae (patch)
tree2dd7ab22251e324b6d0f9167d3d32ed6e911a343 /externals/grill/flext/source/flatom_pr.cpp
parente62722bf0bba2ddb1b8558fa4c851c9e79dddf6c (diff)
""
svn path=/trunk/; revision=339
Diffstat (limited to 'externals/grill/flext/source/flatom_pr.cpp')
-rw-r--r--externals/grill/flext/source/flatom_pr.cpp24
1 files changed, 7 insertions, 17 deletions
diff --git a/externals/grill/flext/source/flatom_pr.cpp b/externals/grill/flext/source/flatom_pr.cpp
index d6f030b5..7eeada93 100644
--- a/externals/grill/flext/source/flatom_pr.cpp
+++ b/externals/grill/flext/source/flatom_pr.cpp
@@ -26,35 +26,25 @@ WARRANTIES, see the file, "license.txt," in this distribution.
void flext::PrintAtom(const t_atom &a,char *buf)
{
- switch(a.a_type) {
- case A_NULL:
- break;
- case A_FLOAT:
+ if(IsFloat(a)) {
#if FLEXT_SYS == FLEXT_SYS_PD
if(a.a_w.w_float == (int)a.a_w.w_float)
STD::sprintf(buf,"%i",(int)GetFloat(a));
else
#endif
STD::sprintf(buf,"%f",GetFloat(a));
- break;
-#if FLEXT_SYS == FLEXT_SYS_MAX
- case A_LONG:
+ }
+ else if(IsInt(a))
STD::sprintf(buf,"%i",GetInt(a));
- break;
-#endif
-#if FLEXT_SYS == FLEXT_SYS_PD
- case A_POINTER:
+ else if(IsPointer(a))
STD::sprintf(buf,"%p",GetPointer(a));
- break;
-#endif
- case A_SYMBOL:
+ else if(IsSymbol(a))
strcpy(buf,GetString(a));
- break;
+ else if(IsNothing(a)) {}
#ifdef FLEXT_DEBUG
- default:
+ else
ERRINTERNAL();
#endif
- }
}
bool flext::ScanAtom(t_atom &a,const char *buf)