diff options
author | Ken Moore <moorekou@gmail.com> | 2016-06-15 12:26:12 -0400 |
---|---|---|
committer | Ken Moore <moorekou@gmail.com> | 2016-06-15 12:26:12 -0400 |
commit | 3965e355e0def0a851fe112ce60cab61f802db4a (patch) | |
tree | ee352b8747561c9e096d25e826b12361cc6b0858 /src-qt5/core/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp | |
parent | Another significant update: (diff) | |
download | lumina-3965e355e0def0a851fe112ce60cab61f802db4a.tar.gz lumina-3965e355e0def0a851fe112ce60cab61f802db4a.tar.bz2 lumina-3965e355e0def0a851fe112ce60cab61f802db4a.zip |
Add the ability to search for apps/utilities directly within the start menu.
Diffstat (limited to 'src-qt5/core/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp')
-rw-r--r-- | src-qt5/core/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp index a742384d..3a0493a3 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp +++ b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp @@ -64,7 +64,8 @@ ItemWidget::ItemWidget(QWidget *parent, QString itemPath, QString type, bool gob }else if(LUtils::imageExtensions().contains(itemPath.section("/",-1).section(".",-1).toLower()) ){ icon->setPixmap( QIcon(itemPath).pixmap(64,64) ); }else{ - icon->setPixmap( LXDG::findMimeIcon(itemPath.section("/",-1)).pixmap(64,64) ); + if( LUtils::isValidBinary(itemPath) ){ icon->setPixmap( LXDG::findIcon(type, "application-x-executable").pixmap(64,64) ); } + else{ icon->setPixmap( LXDG::findMimeIcon(itemPath.section("/",-1)).pixmap(64,64) ); } } name->setText( itemPath.section("/",-1) ); //this->fontMetrics().elidedText(itemPath.section("/",-1), Qt::ElideRight, TEXTCUTOFF) ); text = itemPath.section("/",-1) ; @@ -119,6 +120,10 @@ ItemWidget::ItemWidget(QWidget *parent, XDGDesktop item) : QFrame(parent){ ItemWidget::~ItemWidget(){ } +void ItemWidget::triggerItem(){ + ItemClicked(); +} + void ItemWidget::createWidget(){ //Initialize the widgets gooditem = true; |