diff options
author | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-02-21 15:13:30 +0200 |
---|---|---|
committer | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-02-21 15:13:30 +0200 |
commit | f58a551096aa82986d1270c52dd385110ee8c506 (patch) | |
tree | 9fe7d451c44615a039a55d0053d3a3a7b4710887 /src/ui/widget.h | |
parent | f5f3383efa8fa6533936c042aedcc1cddc3985d6 (diff) |
Animated widget offsets; phone sidebars
Diffstat (limited to 'src/ui/widget.h')
-rw-r--r-- | src/ui/widget.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/ui/widget.h b/src/ui/widget.h index 66fe222b..02ee091f 100644 --- a/src/ui/widget.h +++ b/src/ui/widget.h | |||
@@ -25,6 +25,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ | |||
25 | /* Base class for UI widgets. */ | 25 | /* Base class for UI widgets. */ |
26 | 26 | ||
27 | #include "metrics.h" | 27 | #include "metrics.h" |
28 | #include "util.h" | ||
28 | 29 | ||
29 | #include <the_Foundation/object.h> | 30 | #include <the_Foundation/object.h> |
30 | #include <the_Foundation/objectlist.h> | 31 | #include <the_Foundation/objectlist.h> |
@@ -96,6 +97,7 @@ enum iWidgetFlag { | |||
96 | #define noBackground_WidgetFlag iBit64(42) | 97 | #define noBackground_WidgetFlag iBit64(42) |
97 | #define drawBackgroundToHorizontalSafeArea_WidgetFlag iBit64(43) | 98 | #define drawBackgroundToHorizontalSafeArea_WidgetFlag iBit64(43) |
98 | #define drawBackgroundToVerticalSafeArea_WidgetFlag iBit64(44) | 99 | #define drawBackgroundToVerticalSafeArea_WidgetFlag iBit64(44) |
100 | #define visualOffset_WidgetFlag iBit64(45) | ||
99 | 101 | ||
100 | enum iWidgetAddPos { | 102 | enum iWidgetAddPos { |
101 | back_WidgetAddPos, | 103 | back_WidgetAddPos, |
@@ -113,6 +115,7 @@ struct Impl_Widget { | |||
113 | int64_t flags; | 115 | int64_t flags; |
114 | iRect rect; | 116 | iRect rect; |
115 | int padding[4]; /* left, top, right, bottom */ | 117 | int padding[4]; /* left, top, right, bottom */ |
118 | iAnim visualOffset; | ||
116 | int bgColor; | 119 | int bgColor; |
117 | int frameColor; | 120 | int frameColor; |
118 | iObjectList *children; | 121 | iObjectList *children; |
@@ -200,6 +203,7 @@ void setPos_Widget (iWidget *, iInt2 pos); | |||
200 | void setSize_Widget (iWidget *, iInt2 size); | 203 | void setSize_Widget (iWidget *, iInt2 size); |
201 | void setPadding_Widget (iWidget *, int left, int top, int right, int bottom); | 204 | void setPadding_Widget (iWidget *, int left, int top, int right, int bottom); |
202 | iLocalDef void setPadding1_Widget (iWidget *d, int padding) { setPadding_Widget(d, padding, padding, padding, padding); } | 205 | iLocalDef void setPadding1_Widget (iWidget *d, int padding) { setPadding_Widget(d, padding, padding, padding, padding); } |
206 | void setVisualOffset_Widget (iWidget *d, int value, uint32_t span, int animFlags); | ||
203 | void setBackgroundColor_Widget (iWidget *, int bgColor); | 207 | void setBackgroundColor_Widget (iWidget *, int bgColor); |
204 | void setFrameColor_Widget (iWidget *, int frameColor); | 208 | void setFrameColor_Widget (iWidget *, int frameColor); |
205 | void setCommandHandler_Widget (iWidget *, iBool (*handler)(iWidget *, const char *)); | 209 | void setCommandHandler_Widget (iWidget *, iBool (*handler)(iWidget *, const char *)); |