| 51 | } |
| 52 | |
| 53 | Identifier EffectDefinitionInterface::GetSquashedName(const Identifier &ident) |
| 54 | { |
| 55 | // Get rid of leading and trailing white space |
| 56 | auto name = ident.GET(); |
| 57 | name.Trim(true).Trim(false); |
| 58 | |
| 59 | if (name.empty()) |
| 60 | return {}; |
| 61 | |
| 62 | wxStringTokenizer st(name, wxT(" ")); |
| 63 | wxString id; |
| 64 | |
| 65 | // CamelCase the name |
| 66 | while (st.HasMoreTokens()) { |
| 67 | wxString tok = st.GetNextToken(); |
| 68 | id += tok.Left(1).MakeUpper() + tok.Mid(1).MakeLower(); |
| 69 | } |
| 70 | |
| 71 | return id; |
| 72 | } |
| 73 | |
| 74 | EffectDefinitionInterface::~EffectDefinitionInterface() = default; |
| 75 |
no test coverage detected