homescreenapp/serviceproviders/hsmenuserviceprovider/src/hsmenucollectionsitemmodel.cpp
changeset 85 35368b604b28
parent 39 4e8ebe173323
equal deleted inserted replaced
77:4b195f3bea29 85:35368b604b28
    78 
    78 
    79     CaQuery query;
    79     CaQuery query;
    80     query.setParentId(entry->id());
    80     query.setParentId(entry->id());
    81     query.setEntryRoles(ItemEntryRole);
    81     query.setEntryRoles(ItemEntryRole);
    82 
    82 
    83     if (entry->entryTypeName() == collectionDownloadedTypeName()) {
    83     if (entry->entryTypeName() == Hs::collectionDownloadedTypeName) {
    84         query.setFlagsOn(RemovableEntryFlag | VisibleEntryFlag);
    84         query.setFlagsOn(RemovableEntryFlag | VisibleEntryFlag);
    85     } else {
    85     } else {
    86         query.setFlagsOn(VisibleEntryFlag);
    86         query.setFlagsOn(VisibleEntryFlag);
    87     }
    87     }
    88 
    88 
    93     if (!entries.count()) {
    93     if (!entries.count()) {
    94         result = QString(hbTrId("txt_applib_dblist_downloaded_val_empty"));
    94         result = QString(hbTrId("txt_applib_dblist_downloaded_val_empty"));
    95     }//if
    95     }//if
    96     else {
    96     else {
    97         int count(0);
    97         int count(0);
    98         if (entry->entryTypeName() == collectionDownloadedTypeName()) {
    98         if (entry->entryTypeName() == Hs::collectionDownloadedTypeName) {
    99             for (int i = 0; i < entries.count(); ++i) {
    99             for (int i = 0; i < entries.count(); ++i) {
   100                 if ((entries[i]->flags() & UsedEntryFlag) != UsedEntryFlag) {
   100                 if ((entries[i]->flags() & UsedEntryFlag) != UsedEntryFlag) {
   101                     count++;
   101                     count++;
   102                 }
   102                 }
   103             }
   103             }