aboutsummaryrefslogtreecommitdiff
path: root/include/aoscene.h
diff options
context:
space:
mode:
authorCrystalwarrior <varsash@gmail.com>2020-03-26 14:41:56 +0300
committerCrystalwarrior <varsash@gmail.com>2020-03-26 14:41:56 +0300
commit1634db78641526ddb88f844a46b1bdc615a89e59 (patch)
tree58767eeff7b6a58bc257bf3db0f4b9f6f9e5a92c /include/aoscene.h
parentf668d70ac5e5ed7dff8ddb4508e2b8adfcba7d66 (diff)
Make backgrounds preserve aspect ratio when used with different aspect ratio themes
(e.g. a 16:9 theme would not stretch a 4:3 bg and instead have a letterboxing effect. A 4:3 theme using a 16:9 BG will not stretch the BG but instead center it, making it look like the BG is 4:3 all along.)
Diffstat (limited to 'include/aoscene.h')
-rw-r--r--include/aoscene.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/aoscene.h b/include/aoscene.h
index ddbefe08..46d8c3b8 100644
--- a/include/aoscene.h
+++ b/include/aoscene.h
@@ -17,12 +17,23 @@ public:
void set_image(QString p_image);
void set_legacy_desk(QString p_image);
+ //Move the label itself around
+ void move(int ax, int ay);
+
+ //This is somewhat pointless now as there's no "QMovie" object to resize, aka no "combo" to speak of
+ void combo_resize(int w, int h);
private:
QWidget *m_parent;
QMovie *m_movie;
AOApplication *ao_app;
QString last_image;
+ // These are the X and Y values before they are fixed based on the sprite's width.
+ int x = 0;
+ int y = 0;
+ // These are the width and height values before they are fixed based on the sprite's width.
+ int f_w = 0;
+ int f_h = 0;
};
#endif // AOSCENE_H