~ubuntu-branches/ubuntu/hardy/kde4libs/hardy-backports

« back to all changes in this revision

Viewing changes to kdecore/services/kservice.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Jonathan Riddell
  • Date: 2008-03-28 11:59:55 UTC
  • mfrom: (1.1.12 upstream)
  • Revision ID: james.westby@ubuntu.com-20080328115955-xgzd1adltz2xnosa
Tags: 4:4.0.3-0ubuntu1
New upstream release

Show diffs side-by-side

added added

removed removed

Lines of Context:
148
148
    {
149
149
        kWarning(7012) << "The desktop entry file " << entryPath
150
150
                       << " has Type=" << m_strType << " but is located under \"" << resource
151
 
                       << "\" instead of \"services\"" << endl;
 
151
                       << "\" instead of \"services\"";
152
152
        m_bValid = false;
153
153
        return;
154
154
    }
206
206
    QListIterator<QString> st_it(lstServiceTypes);
207
207
    while ( st_it.hasNext() ) {
208
208
        const QString st = st_it.next();
 
209
        if (st.isEmpty()) {
 
210
            kWarning(7012) << "The desktop entry file" << entryPath
 
211
                           << "has an empty mimetype!";
 
212
            continue;
 
213
        }
209
214
        int initialPreference = m_initialPreference;
210
215
        if ( st_it.hasNext() ) {
211
216
            // TODO better syntax - separate group with mimetype=number entries?
216
221
                st_it.next();
217
222
            }
218
223
        }
219
 
        Q_ASSERT(!st.isEmpty());
220
224
        m_serviceTypes.push_back(KService::ServiceTypeAndPreference(initialPreference, st));
221
225
    }
222
226