From 486597f6247748a6aa6c30129b2156922b869a8c Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Mon, 23 Nov 2015 17:00:39 -0500 Subject: Adjust the start menu to show the "genericName" instead of the comment underneath an app name, and use the comment as the tooltip. Also adjust the panel re-focus routine a bit to make it smarter about which window gets activation after leaving the panel if the previously active window was closed/minimized. --- lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'lumina-desktop/panel-plugins') diff --git a/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp b/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp index 8c0fae09..bdd13b18 100644 --- a/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp +++ b/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp @@ -22,8 +22,9 @@ ItemWidget::ItemWidget(QWidget *parent, QString itemPath, QString type, bool gob icon->setPixmap( LXDG::findIcon(item.icon, "preferences-system-windows-actions").pixmap(32,32) ); iconPath = item.icon; text = item.name; - if(!item.comment.isEmpty()){ text.append("
-- "+item.comment+""); } + if(!item.genericName.isEmpty() && item.name!=item.genericName){ text.append("
-- "+item.genericName+""); } name->setText(text); + name->setToolTip(item.comment); setupActions(item); }else{ gooditem = false; @@ -79,7 +80,7 @@ ItemWidget::ItemWidget(QWidget *parent, QString itemPath, QString type, bool gob }else{ isShortcut = false; } - if(isShortcut){ + if(isShortcut && name->toolTip().isEmpty()){ name->setToolTip(icon->whatsThis()); //also allow the user to see the full shortcut path } //Now setup the button appropriately @@ -104,8 +105,9 @@ ItemWidget::ItemWidget(QWidget *parent, XDGDesktop item) : QFrame(parent){ //Now fill it appropriately icon->setPixmap( LXDG::findIcon(item.icon,"preferences-system-windows-actions").pixmap(64,64) ); text = item.name; - if(!item.comment.isEmpty()){ text.append("
-- "+item.comment+""); } + if(!item.genericName.isEmpty() && item.name!=item.genericName){ text.append("
-- "+item.genericName+""); } name->setText(text); + name->setToolTip(item.comment); this->setWhatsThis(item.name); icon->setWhatsThis(item.filePath); iconPath = item.icon; -- cgit