I've done both and IMHO think one .c file per form makes it easier to follow
and manage the code.  But in practice, the Metrowerks IDE makes it easier
for me to just dump most of a Palm project's form routines into the same .c
file.
However, I almost always use separate handler functions for each dialog.
Even it there is tons of common code.  Which, in that case, I attempt to
break the code into as many common sub-routines as possible (while retaining
separate handlers).
When Palm migrates towards a C++ common framework, I plan on one class
instance per form (as I do when writing code for that other OS).
Smaller Palm executable is just not the priority as it once was.

----- Original Message -----
From: "Steven Fisher" <[EMAIL PROTECTED]>
Newsgroups: palm-dev-forum
To: "Palm Developer Forum" <[EMAIL PROTECTED]>
Sent: Wednesday, June 25, 2003 2:07 PM
Subject: Multiple forms handled by one .c


> A coworker and I are having a bit of an argument over whether or not
> multiple forms should be handled by a single source file. I'm a big fan
> of considering .c files to be objects, and trying to use an
> object-oriented approach to developing forms. However, he's right that
> handling related forms with a single .c file takes a lot less source
> code (though I'm not really convinced it's that much less object code).
>
> So, I thought I'd ask here: What are the advantages/disadvantages to
> each approach? Have you regretted one extreme or the other? Is some
> comfortable middle ground (like related forms in a single .c) a better
> approach than either extreme?
>
> I'm willing to be convinced either way. Please let me know what you
> think. :)
>
> --
> For information on using the Palm Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/support/forums/
>


-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/

Reply via email to