hi, i programming a j2me game, and i using compile directives...


//#define usesound


//#ifdef usesound




this are in the main MIDlet class, i defined the directive "usesound", and i write instructions on this condition, if usesound is declared. in other classe, i want to use the same define, only asking if this is defined:



//#ifdef usesound



But is no run correctaly, if the "usesound" is defined in midlet.java, it appear only in midlet.java. in myobject.java it is no defined... i must define on each class!, but i working with a lot of class, more or minus 20 classes, how can i put and erase 20 directives for each simple multiplataform test?

if you know how to define a global directive, tell me please



Obs: i using NetBeans IDE 5.0 and programming for nokia UI with midp 1.0.. and my english is a trash hehe, sorry