I don’t consider myself to be a Qt Guru. I might have some ideas and some experience of Qt, but there are plenty of more talented people e.g. in Maemo organization and in developer communities. These things that I write here are just my own thoughts and you can disagree them, but in that case, please leave a comment. Because I have also criticized some parts of the design of the Maemo 6 UI Framework, I think that it’s only fair to provide alternatives or at least proposals how things could be done differently. I don’t want to say that something is implemented or designed bad, if I don’t have justification for the criticism.
After chewing the MVC model stuff couple of days, that I was writing in my previous post, I decided to propose an alternative way to do pretty much the same functionality. The MVC model in Maemo 6 UI framework had the following flaws in my opinion:
- It’s too complex. It requires too many classes in order to implement a widget ( yes, I know there is DuiStylableWidget also)
- It extends the qmake. In my opinion this can be done without code generation also.
- It follows too much the MVC ideology. In my opinion there is no need for a model class. These can be ordinary class members.
- Setting a size for a widget is bit weird. I’m not sure should I set the size for a controller or for a view