hi all,

i have a global enum defined as:

Qt Code:
  1. enum EditType {Currency, Percent, LabeledNumber, Text};
To copy to clipboard, switch view to plain text mode 
then i have a class with an enum defined identically:

Qt Code:
  1. class A : public QWidget
  2. {
  3. public:
  4. A();
  5. ~A();
  6.  
  7. enum EditTypeBase {Currency, Percent, LabeledNumber, Text};
  8. EditTypeBase LineType;
  9. ...
  10. }
To copy to clipboard, switch view to plain text mode 

in the function definitions i need to map from EditTypeBase to EditType. i HAVE to do it this way because of the meta-object compiler.

how do i compare the two enums?

Qt Code:
  1. EditType A::GetType()
  2. {
  3. if (LineType == Currency)
  4. return EditType::Currency;
  5. ...
  6. }
To copy to clipboard, switch view to plain text mode 

this gives a syntax error. the first 'Currency' is from EditTypeBase defined inside the class, but the 2nd 'Currency' is of type EditType defined outside. how do i properly refer to EditType enumerators within class A since they have the same names as the ones defined inside the class?
thanks

lou