aboutsummaryrefslogtreecommitdiff
path: root/src/aobutton.cpp
diff options
context:
space:
mode:
authoroldmud0 <oldmud0@users.noreply.github.com>2021-06-09 19:41:09 -0500
committerGitHub <noreply@github.com>2021-06-09 19:41:09 -0500
commit9e0a964af814fa941f04ebebbc28bdbb23977651 (patch)
tree2ba4c962b08aed1fee29a8315776605347ee14bf /src/aobutton.cpp
parent2adb32bb61a62bb085d5d62f4115ae21c6bb50cd (diff)
parent2f50cd55281cfa963ea2d6fb566b1eee675c643f (diff)
Merge pull request #554 from AttorneyOnline/feature/mounting
Add support for mounting multiple base folders
Diffstat (limited to 'src/aobutton.cpp')
-rw-r--r--src/aobutton.cpp11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/aobutton.cpp b/src/aobutton.cpp
index 7f8c13fe..242fe79a 100644
--- a/src/aobutton.cpp
+++ b/src/aobutton.cpp
@@ -20,14 +20,9 @@ void AOButton::set_image(QString p_path, QString p_misc)
{
movie->stop();
QString p_image;
- // Check if the user wants animated themes
- if (ao_app->get_animated_theme())
- // We want an animated image
- p_image = ao_app->get_image(p_path, ao_app->current_theme, ao_app->get_subtheme(), ao_app->default_theme, p_misc);
- else
- // Grab a static variant of the image
- p_image = ao_app->get_image_path(ao_app->get_asset_paths(p_path, ao_app->current_theme, ao_app->get_subtheme(), ao_app->default_theme, p_misc), true);
- if (!file_exists(p_image)) {
+ p_image = ao_app->get_image(p_path, ao_app->current_theme, ao_app->get_subtheme(),
+ ao_app->default_theme, p_misc, "", "", !ao_app->get_animated_theme());
+ if (p_image.isEmpty()) {
this->setIcon(QIcon());
this->setIconSize(this->size());
this->setStyleSheet("");