Skip to content

Commit

Permalink
Use the expected names for icon files, list them
Browse files Browse the repository at this point in the history
Rename the icon files so that their name matches the expected
name (solving a cmake warning during the build process).
Also, use the list of files directly in ecm_install_icons:
cmake documentation for file(GLOB do not recommend the usage
of GLOB to build the list of source files:
https://cmake.org/cmake/help/v3.4/command/file.html
  • Loading branch information
tosky committed Sep 30, 2018
1 parent 1cb4102 commit 1010775
Show file tree
Hide file tree
Showing 32 changed files with 109 additions and 85 deletions.
50 changes: 25 additions & 25 deletions basket.qrc
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,30 @@
<file>images/tag_export_help.png</file>
<file>images/tag_export_on_every_lines_help.png</file>
<file>images/insertion_help.png</file>
<file>images/hi16-actions-likeback_bug.png</file>
<file>images/hi16-actions-likeback_dislike.png</file>
<file>images/hi16-actions-likeback_like.png</file>
<file>images/hi16-actions-likeback_feature.png</file>
<file>images/hi16-apps-basket.png</file>
<file>images/hi22-apps-basket.png</file>
<file>images/hi32-apps-basket.png</file>
<file>images/hi48-apps-basket.png</file>
<file>images/hi64-apps-basket.png</file>
<file>images/hi128-apps-basket.png</file>
<file>tags/hi16-actions-tag_checkbox.png</file>
<file>tags/hi16-actions-tag_checkbox_checked.png</file>
<file>tags/hi16-actions-tag_for_later.png</file>
<file>tags/hi16-actions-tag_fun.png</file>
<file>tags/hi16-actions-tag_important.png</file>
<file>tags/hi16-actions-tag_preference_bad.png</file>
<file>tags/hi16-actions-tag_preference_excellent.png</file>
<file>tags/hi16-actions-tag_preference_good.png</file>
<file>tags/hi16-actions-tag_priority_high.png</file>
<file>tags/hi16-actions-tag_priority_low.png</file>
<file>tags/hi16-actions-tag_priority_medium.png</file>
<file>tags/hi16-actions-tag_progress_000.png</file>
<file>tags/hi16-actions-tag_progress_025.png</file>
<file>tags/hi16-actions-tag_progress_075.png</file>
<file>tags/hi16-actions-tag_progress_100.png</file>
<file>images/16-actions-likeback_bug.png</file>
<file>images/16-actions-likeback_dislike.png</file>
<file>images/16-actions-likeback_like.png</file>
<file>images/16-actions-likeback_feature.png</file>
<file>images/16-apps-basket.png</file>
<file>images/22-apps-basket.png</file>
<file>images/32-apps-basket.png</file>
<file>images/48-apps-basket.png</file>
<file>images/64-apps-basket.png</file>
<file>images/128-apps-basket.png</file>
<file>tags/16-actions-tag_checkbox.png</file>
<file>tags/16-actions-tag_checkbox_checked.png</file>
<file>tags/16-actions-tag_for_later.png</file>
<file>tags/16-actions-tag_fun.png</file>
<file>tags/16-actions-tag_important.png</file>
<file>tags/16-actions-tag_preference_bad.png</file>
<file>tags/16-actions-tag_preference_excellent.png</file>
<file>tags/16-actions-tag_preference_good.png</file>
<file>tags/16-actions-tag_priority_high.png</file>
<file>tags/16-actions-tag_priority_low.png</file>
<file>tags/16-actions-tag_priority_medium.png</file>
<file>tags/16-actions-tag_progress_000.png</file>
<file>tags/16-actions-tag_progress_025.png</file>
<file>tags/16-actions-tag_progress_075.png</file>
<file>tags/16-actions-tag_progress_100.png</file>
</qresource>
</RCC>
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
19 changes: 14 additions & 5 deletions images/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
FILE(GLOB PNG_FILES
RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}"
"${CMAKE_CURRENT_SOURCE_DIR}/hi*.png")

ecm_install_icons(ICONS ${PNG_FILES} DESTINATION ${ICON_INSTALL_DIR})
ecm_install_icons(ICONS
128-apps-basket.png
16-actions-likeback_bug.png
16-actions-likeback_dislike.png
16-actions-likeback_feature.png
16-actions-likeback_like.png
16-apps-basket.png
22-apps-basket.png
32-apps-basket.png
48-apps-basket.png
64-apps-basket.png
DESTINATION ${ICON_INSTALL_DIR}
THEME hicolor
)
82 changes: 41 additions & 41 deletions links.sh
Original file line number Diff line number Diff line change
Expand Up @@ -131,22 +131,22 @@ source_files=(
"$TARGET/images/tag_export_help.png"
"$TARGET/src/basket_part.rc"
"$TARGET/src/basketui.rc"
"$TARGET/tags/hi16-action-tag_priority_high.png"
"$TARGET/tags/hi16-action-tag_important.png"
"$TARGET/tags/hi16-action-tag_for_later.png"
"$TARGET/tags/hi16-action-tag_preference_excellent.png"
"$TARGET/tags/hi16-action-tag_priority_medium.png"
"$TARGET/tags/hi16-action-tag_progress_000.png"
"$TARGET/tags/hi16-action-tag_progress_100.png"
"$TARGET/tags/hi16-action-tag_preference_bad.png"
"$TARGET/tags/hi16-action-tag_preference_good.png"
"$TARGET/tags/hi16-action-tag_checkbox.png"
"$TARGET/tags/hi16-action-tag_progress_050.png"
"$TARGET/tags/hi16-action-tag_fun.png"
"$TARGET/tags/hi16-action-tag_progress_025.png"
"$TARGET/tags/hi16-action-tag_checkbox_checked.png"
"$TARGET/tags/hi16-action-tag_progress_075.png"
"$TARGET/tags/hi16-action-tag_priority_low.png"
"$TARGET/tags/16-action-tag_priority_high.png"
"$TARGET/tags/16-action-tag_important.png"
"$TARGET/tags/16-action-tag_for_later.png"
"$TARGET/tags/16-action-tag_preference_excellent.png"
"$TARGET/tags/16-action-tag_priority_medium.png"
"$TARGET/tags/16-action-tag_progress_000.png"
"$TARGET/tags/16-action-tag_progress_100.png"
"$TARGET/tags/16-action-tag_preference_bad.png"
"$TARGET/tags/16-action-tag_preference_good.png"
"$TARGET/tags/16-action-tag_checkbox.png"
"$TARGET/tags/16-action-tag_progress_050.png"
"$TARGET/tags/16-action-tag_fun.png"
"$TARGET/tags/16-action-tag_progress_025.png"
"$TARGET/tags/16-action-tag_checkbox_checked.png"
"$TARGET/tags/16-action-tag_progress_075.png"
"$TARGET/tags/16-action-tag_priority_low.png"
"$TARGET/kontact_plugin/kontact_basketplugin.setdlg"
"$TARGET/kontact_plugin/basket.desktop"
"$TARGET/src/basket_config_general.desktop"
Expand All @@ -165,31 +165,31 @@ source_files=(
"$BUILD/src/.libs/libbasketcommon.so"
"$BUILD/src/.libs/libbasketcommon.la"
"$BUILD/src/.libs/basket"
"$TARGET/src/hi16-action-likeback_dislike.png"
"$TARGET/src/hi16-action-likeback_like.png"
"$TARGET/src/hi16-action-likeback_configure.png"
"$TARGET/tags/hi16-action-tag_priority_high.png"
"$TARGET/tags/hi16-action-tag_important.png"
"$TARGET/tags/hi16-action-tag_for_later.png"
"$TARGET/tags/hi16-action-tag_preference_excellent.png"
"$TARGET/tags/hi16-action-tag_priority_medium.png"
"$TARGET/tags/hi16-action-tag_progress_000.png"
"$TARGET/tags/hi16-action-tag_progress_100.png"
"$TARGET/tags/hi16-action-tag_preference_bad.png"
"$TARGET/tags/hi16-action-tag_preference_good.png"
"$TARGET/tags/hi16-action-tag_checkbox.png"
"$TARGET/tags/hi16-action-tag_progress_050.png"
"$TARGET/tags/hi16-action-tag_fun.png"
"$TARGET/tags/hi16-action-tag_progress_025.png"
"$TARGET/tags/hi16-action-tag_checkbox_checked.png"
"$TARGET/tags/hi16-action-tag_progress_075.png"
"$TARGET/tags/hi16-action-tag_priority_low.png"
"$TARGET/src/hi16-app-basket.png"
"$TARGET/src/hi128-app-basket.png"
"$TARGET/src/hi64-app-basket.png"
"$TARGET/src/hi48-app-basket.png"
"$TARGET/src/hi22-app-/basket.png"
"$TARGET/src/hi32-app-/basket.png"
"$TARGET/src/16-action-likeback_dislike.png"
"$TARGET/src/16-action-likeback_like.png"
"$TARGET/src/16-action-likeback_configure.png"
"$TARGET/tags/16-action-tag_priority_high.png"
"$TARGET/tags/16-action-tag_important.png"
"$TARGET/tags/16-action-tag_for_later.png"
"$TARGET/tags/16-action-tag_preference_excellent.png"
"$TARGET/tags/16-action-tag_priority_medium.png"
"$TARGET/tags/16-action-tag_progress_000.png"
"$TARGET/tags/16-action-tag_progress_100.png"
"$TARGET/tags/16-action-tag_preference_bad.png"
"$TARGET/tags/16-action-tag_preference_good.png"
"$TARGET/tags/16-action-tag_checkbox.png"
"$TARGET/tags/16-action-tag_progress_050.png"
"$TARGET/tags/16-action-tag_fun.png"
"$TARGET/tags/16-action-tag_progress_025.png"
"$TARGET/tags/16-action-tag_checkbox_checked.png"
"$TARGET/tags/16-action-tag_progress_075.png"
"$TARGET/tags/16-action-tag_priority_low.png"
"$TARGET/src/16-app-basket.png"
"$TARGET/src/128-app-basket.png"
"$TARGET/src/64-app-basket.png"
"$TARGET/src/48-app-basket.png"
"$TARGET/src/22-app-/basket.png"
"$TARGET/src/32-app-/basket.png"
"$TARGET/src/hisc-app-basket.svg"
)

Expand Down
2 changes: 1 addition & 1 deletion src/bnpview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ void BNPView::lateInit()

/* System tray icon */
Global::systemTray = new SystemTray(Global::activeMainWindow());
Global::systemTray->setIconByName(":/images/hi22-apps-basket");
Global::systemTray->setIconByName(":/images/22-apps-basket");
connect(Global::systemTray, SIGNAL(showPart()), this, SIGNAL(showPart()));
/*if (Settings::useSystray())
Global::systemTray->show();*/
Expand Down
16 changes: 8 additions & 8 deletions src/likeback.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -462,19 +462,19 @@ void LikeBack::showInformationMessage()
: "") +
"<p>" + i18np("Example:", "Examples:", nbButtons) + "</p>" +
(buttons & LikeBack::Like ?
"<p><img source=\":images/hi16-actions-likeback_like.png\"> &nbsp;" +
"<p><img source=\":images/16-actions-likeback_like.png\"> &nbsp;" +
i18n("<b>I like</b> the new artwork. Very refreshing.") + "</p>"
: "") +
(buttons & LikeBack::Dislike ?
"<p><img source=\":images/hi16-actions-likeback_dislike.png\"> &nbsp;" +
"<p><img source=\":images/16-actions-likeback_dislike.png\"> &nbsp;" +
i18n("<b>I dislike</b> the welcome page of that assistant. Too time consuming.") + "</p>"
: "") +
(buttons & LikeBack::Bug ?
"<p><img source=\":images/hi16-actions-likeback_bug.png\"> &nbsp;" +
"<p><img source=\":images/16-actions-likeback_bug.png\"> &nbsp;" +
i18n("<b>The application has an improper behaviour</b> when clicking the Add button. Nothing happens.") + "</p>"
: "") +
(buttons & LikeBack::Feature ?
"<p><img source=\":images/hi16-actions-likeback_feature.png\"> &nbsp;" +
"<p><img source=\":images/16-actions-likeback_feature.png\"> &nbsp;" +
i18n("<b>I desire a new feature</b> allowing me to send my work by email.") + "</p>"
: "") +
"</tr></table>",
Expand Down Expand Up @@ -664,7 +664,7 @@ LikeBackDialog::LikeBackDialog(LikeBack::Button reason, const QString &initialCo
QGridLayout *buttonsGrid = new QGridLayout(buttons);
if (m_likeBack->buttons() & LikeBack::Like) {
QPixmap likePixmap = KIconLoader::global()->loadIcon(
":images/hi16-actions-likeback_like.png", KIconLoader::NoGroup, 16,
":images/16-actions-likeback_like.png", KIconLoader::NoGroup, 16,
KIconLoader::DefaultState, QStringList(), 0L, true
);
QLabel *likeIcon = new QLabel(buttons);
Expand All @@ -676,7 +676,7 @@ LikeBackDialog::LikeBackDialog(LikeBack::Button reason, const QString &initialCo
}
if (m_likeBack->buttons() & LikeBack::Dislike) {
QPixmap dislikePixmap = KIconLoader::global()->loadIcon(
":images/hi16-actions-likeback_dislike.png", KIconLoader::NoGroup, 16,
":images/16-actions-likeback_dislike.png", KIconLoader::NoGroup, 16,
KIconLoader::DefaultState, QStringList(), 0L, true
);
QLabel *dislikeIcon = new QLabel(buttons);
Expand All @@ -688,7 +688,7 @@ LikeBackDialog::LikeBackDialog(LikeBack::Button reason, const QString &initialCo
}
if (m_likeBack->buttons() & LikeBack::Bug) {
QPixmap bugPixmap = KIconLoader::global()->loadIcon(
":images/hi16-actions-likeback_bug.png", KIconLoader::NoGroup, 16, KIconLoader::DefaultState,
":images/16-actions-likeback_bug.png", KIconLoader::NoGroup, 16, KIconLoader::DefaultState,
QStringList(), 0L, true
);
QLabel *bugIcon = new QLabel(buttons);
Expand All @@ -700,7 +700,7 @@ LikeBackDialog::LikeBackDialog(LikeBack::Button reason, const QString &initialCo
}
if (m_likeBack->buttons() & LikeBack::Feature) {
QPixmap featurePixmap = KIconLoader::global()->loadIcon(
":images/hi16-actions-likeback_feature.png", KIconLoader::NoGroup, 16,
":images/16-actions-likeback_feature.png", KIconLoader::NoGroup, 16,
KIconLoader::DefaultState, QStringList(), 0L, true);
QLabel *featureIcon = new QLabel(buttons);
featureIcon->setPixmap(featurePixmap);
Expand Down
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
25 changes: 20 additions & 5 deletions tags/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,20 @@
FILE(GLOB PNG_FILES
RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}"
"${CMAKE_CURRENT_SOURCE_DIR}/*.png")

ecm_install_icons(ICONS ${PNG_FILES} DESTINATION ${ICON_INSTALL_DIR})
ecm_install_icons(ICONS
16-actions-tag_checkbox.png
16-actions-tag_checkbox_checked.png
16-actions-tag_for_later.png
16-actions-tag_fun.png
16-actions-tag_important.png
16-actions-tag_preference_bad.png
16-actions-tag_preference_excellent.png
16-actions-tag_preference_good.png
16-actions-tag_priority_high.png
16-actions-tag_priority_low.png
16-actions-tag_priority_medium.png
16-actions-tag_progress_000.png
16-actions-tag_progress_025.png
16-actions-tag_progress_050.png
16-actions-tag_progress_075.png
16-actions-tag_progress_100.png
DESTINATION ${ICON_INSTALL_DIR}
THEME hicolor
)

0 comments on commit 1010775

Please sign in to comment.