aboutsummaryrefslogtreecommitdiff
path: root/src/emotes.cpp
diff options
context:
space:
mode:
authorAlex Noir <Varsash@gmail.com>2022-02-18 22:02:18 +0300
committerAlex Noir <Varsash@gmail.com>2022-02-18 22:02:18 +0300
commit0e2bd0b110fe44f485871d20b5e614a214470f12 (patch)
tree0d7502d10080634aca25c43a3f72470410630473 /src/emotes.cpp
parente6f06d8959ff65be11b20dcba27977f8935bb044 (diff)
Add icons for iniswaps and emotes in the dropdown
Fix iniswap list not recognizing a name that's different from a character folder when switching to that character
Diffstat (limited to 'src/emotes.cpp')
-rw-r--r--src/emotes.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/emotes.cpp b/src/emotes.cpp
index 53f2b065..547dc0ea 100644
--- a/src/emotes.cpp
+++ b/src/emotes.cpp
@@ -141,14 +141,14 @@ void Courtroom::set_emote_dropdown()
ui_emote_dropdown->clear();
int total_emotes = ao_app->get_emote_number(current_char);
- QStringList emote_list;
for (int n = 0; n < total_emotes; ++n) {
- emote_list.append(QString::number(n + 1) + ": " +
- ao_app->get_emote_comment(current_char, n));
+ ui_emote_dropdown->addItem(QString::number(n + 1) + ": " +
+ ao_app->get_emote_comment(current_char, n));
+ QString icon_path = ao_app->get_image_suffix(ao_app->get_character_path(
+ current_char, "emotions/button" + QString::number(n + 1) + "_off"));
+ ui_emote_dropdown->setItemIcon(n, QIcon(icon_path));
}
-
- ui_emote_dropdown->addItems(emote_list);
}
void Courtroom::select_emote(int p_id)