aboutsummaryrefslogtreecommitdiff
path: root/src/aobutton.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/aobutton.cpp')
-rw-r--r--src/aobutton.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/aobutton.cpp b/src/aobutton.cpp
index 6d25a05f..5ef2a066 100644
--- a/src/aobutton.cpp
+++ b/src/aobutton.cpp
@@ -2,6 +2,7 @@
#include "debug_functions.h"
#include "file_functions.h"
+#include "options.h"
AOButton::AOButton(QWidget *parent, AOApplication *p_ao_app)
: QPushButton(parent)
@@ -20,8 +21,8 @@ void AOButton::set_image(QString p_path, QString p_misc)
{
movie->stop();
QString 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());
+ p_image = ao_app->get_image(p_path, Options::getInstance().theme(), Options::getInstance().subTheme(),
+ ao_app->default_theme, p_misc, "", "", !Options::getInstance().animatedThemeEnabled());
if (p_image.isEmpty()) {
this->setIcon(QIcon());
this->setIconSize(this->size());
@@ -33,7 +34,7 @@ void AOButton::set_image(QString p_path, QString p_misc)
movie->setFileName(p_image);
// We double-check if the user wants animated themes, so even if an animated image slipped through,
// we still set it static
- if (ao_app->get_animated_theme() && movie->frameCount() > 1) {
+ if (Options::getInstance().animatedThemeEnabled() && movie->frameCount() > 1) {
movie->start();
}
else {