Skip to content

Commit

Permalink
Merge branch 'jb36842' into 'master'
Browse files Browse the repository at this point in the history
[lipstick] Expose mime-type from LauncherItem. Contributes to JB#36842

See merge request !79
  • Loading branch information
rainemak committed Jan 30, 2018
2 parents 6a37b5b + b53a9ed commit 690a693
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/components/launcheritem.cpp
Expand Up @@ -160,6 +160,11 @@ QStringList LauncherItem::desktopCategories() const
return !m_desktopEntry.isNull() ? m_desktopEntry->categories() : QStringList();
}

QStringList LauncherItem::mimeType() const
{
return !m_desktopEntry.isNull() ? m_desktopEntry->mimeType() : QStringList();
}

QString LauncherItem::titleUnlocalized() const
{
if (m_isTemporary) {
Expand Down
2 changes: 2 additions & 0 deletions src/components/launcheritem.h
Expand Up @@ -51,6 +51,7 @@ class LIPSTICK_EXPORT LauncherItem : public QObject
Q_PROPERTY(QString entryType READ entryType NOTIFY itemChanged)
Q_PROPERTY(QString iconId READ iconId NOTIFY itemChanged)
Q_PROPERTY(QStringList desktopCategories READ desktopCategories NOTIFY itemChanged)
Q_PROPERTY(QStringList mimeType READ mimeType NOTIFY itemChanged)
Q_PROPERTY(QString titleUnlocalized READ titleUnlocalized NOTIFY itemChanged)
Q_PROPERTY(bool shouldDisplay READ shouldDisplay NOTIFY itemChanged)
Q_PROPERTY(bool isValid READ isValid NOTIFY itemChanged)
Expand Down Expand Up @@ -81,6 +82,7 @@ public slots:
QString entryType() const;
QString iconId() const;
QStringList desktopCategories() const;
QStringList mimeType() const;
QString titleUnlocalized() const;
bool shouldDisplay() const;
bool isValid() const;
Expand Down

0 comments on commit 690a693

Please sign in to comment.