X-Git-Url: http://cgit.sxemacs.org/?p=harmattan%2Fcameraplus;a=blobdiff_plain;f=declarative%2Fvideoresolutionmodel.cpp;h=1cd09816954da261242bea4074ee618843585ce8;hp=784e1666995854c8879d7dabe0bfde61c925853b;hb=8b446fd852f3427efd37c5104207dafea1089934;hpb=3423bd2565dc32f1a8910a99e1d26a6e977a3f63 diff --git a/declarative/videoresolutionmodel.cpp b/declarative/videoresolutionmodel.cpp index 784e166..1cd0981 100644 --- a/declarative/videoresolutionmodel.cpp +++ b/declarative/videoresolutionmodel.cpp @@ -98,12 +98,27 @@ void VideoResolutionModel::setAspectRatio(const QString& aspectRatio) { m_aspectRatio = aspectRatio; - emit aspectRatioChanged(); - beginResetModel(); m_resolutions = m_settings->resolutions(m_aspectRatio); endResetModel(); + + emit aspectRatioChanged(); + emit countChanged(); } } + +int VideoResolutionModel::count() const { + return rowCount(); +} + +#if defined(QT5) +QHash VideoResolutionModel::roleNames() const { + return m_roles; +} + +void VideoResolutionModel::setRoleNames(const QHash& roles) { + m_roles = roles; +} +#endif