change and add some comments, remove some warning
[mdictionary] / src / plugins / xdxf / DictsModel.h
index cbe3a0e..93757c0 100644 (file)
@@ -42,19 +42,31 @@ class DictsModel : public QAbstractItemModel
     Q_OBJECT
 public:
     /*!
-      Constructor
-      \param dicts list of DownloadDict objects, each such object describes
+        Constructor
+        \param dicts list of DownloadDict objects, each such object describes
         one dictionary
-      */
+    */
     DictsModel(QList<DownloadDict> dicts, QObject *parent);
 
+    //! \return return numner of rows
     int rowCount(const QModelIndex &parent = QModelIndex()) const;
+
+    //! \return return numner of columns
     int columnCount(const QModelIndex &parent = QModelIndex()) const;
 
+    //!  create Index,  createIndex(row,column,row)
     QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const;
+
+    //! return new QModelIndex;
     QModelIndex parent(const QModelIndex &child) const;
 
+    /*!
+        \return return empty QVariant when role is't DisplayRole,
+        else return QVariant (QString with _from,_to,_title)
+    */
     QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const;
+
+    //! \return return a QVariant with header QString.
     QVariant headerData(int section, Qt::Orientation orientation, int role) const;
 
 private: