From 88ad16b413990279cc1c64f0940cdb2d5f5d93be Mon Sep 17 00:00:00 2001 From: Anna Udovichenko Date: Thu, 10 May 2012 18:25:47 +0300 Subject: [PATCH] Fixed signal-slot connecting bug --- src/gui/UBFeaturesActionBar.cpp | 1 + src/gui/UBFeaturesWidget.cpp | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gui/UBFeaturesActionBar.cpp b/src/gui/UBFeaturesActionBar.cpp index 60900c84..a151406d 100644 --- a/src/gui/UBFeaturesActionBar.cpp +++ b/src/gui/UBFeaturesActionBar.cpp @@ -75,6 +75,7 @@ UBFeaturesActionBar::UBFeaturesActionBar( UBFeaturesController *controller, QWid connect(mSearchBar, SIGNAL(textChanged(QString)), this, SLOT(onSearchTextChanged(QString))); connect(mpNewFolderAction, SIGNAL(triggered()), this, SLOT(onActionNewFolder()));*/ + connect(mpFavoriteAction,SIGNAL(triggered()), this, SLOT(onActionFavorite())); connect(mSearchBar, SIGNAL(textChanged(QString)), this, SLOT(onSearchTextChanged(QString))); connect(mpNewFolderAction, SIGNAL(triggered()), this, SLOT(onActionNewFolder())); connect(mpRemoveFavorite, SIGNAL(triggered()), this, SLOT(onActionRemoveFavorite())); diff --git a/src/gui/UBFeaturesWidget.cpp b/src/gui/UBFeaturesWidget.cpp index 8ee5e904..526fc23d 100644 --- a/src/gui/UBFeaturesWidget.cpp +++ b/src/gui/UBFeaturesWidget.cpp @@ -286,7 +286,8 @@ void UBFeaturesWidget::deleteSelectedElements() foreach ( QModelIndex sel, selected ) { UBFeature feature = sel.data( Qt::UserRole + 1 ).value(); - urls.append( feature.getFullPath() ); + if ( feature.isDeletable() ) + urls.append( feature.getFullPath() ); } foreach (QUrl url, urls)