diff options
Diffstat (limited to 'src/aobutton.cpp')
| -rw-r--r-- | src/aobutton.cpp | 11 |
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(""); |
