Skip to content

Commit 0798b70

Browse files
committed
Release 6.1.11
1 parent b638e8c commit 0798b70

File tree

131 files changed

+113145
-73122
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

131 files changed

+113145
-73122
lines changed

common/inc/gx_api.h

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
/* APPLICATION INTERFACE DEFINITION RELEASE */
2525
/* */
2626
/* gx_api.h PORTABLE C */
27-
/* 6.1.10 */
27+
/* 6.1.11 */
2828
/* AUTHOR */
2929
/* */
3030
/* Kenneth Maxwell, Microsoft Corporation */
@@ -86,6 +86,12 @@
8686
/* vertical and horizontal */
8787
/* list control blocks, */
8888
/* resulting in version 6.1.10 */
89+
/* 04-25-2022 Ting Zhu Modified comment(s), */
90+
/* added new member to struct */
91+
/* GX_DISPLAY_LAYER_SERVICES, */
92+
/* added new animation flag */
93+
/* GX_ANIMATION_BLOCK_MOVE, */
94+
/* resulting in version 6.1.11 */
8995
/* */
9096
/**************************************************************************/
9197

@@ -109,7 +115,7 @@ extern "C" {
109115
#define AZURE_RTOS_GUIX
110116
#define GUIX_MAJOR_VERSION 6
111117
#define GUIX_MINOR_VERSION 1
112-
#define GUIX_PATCH_VERSION 10
118+
#define GUIX_PATCH_VERSION 11
113119

114120
/* The following symbols are defined for backward compatibility reasons.*/
115121
#define __PRODUCT_GUIX__
@@ -882,6 +888,7 @@ typedef struct GX_STRING_STRUCT
882888
#define GX_ANIMATION_NONE 0x0000U
883889
#define GX_ANIMATION_TRANSLATE 0x0001U
884890
#define GX_ANIMATION_SCREEN_DRAG 0x0002U
891+
#define GX_ANIMATION_BLOCK_MOVE 0x0004U
885892

886893
/* flags that can be used in combination with screen drag animation */
887894
#define GX_ANIMATION_WRAP 0x0100U
@@ -1525,6 +1532,7 @@ typedef struct GX_DISPLAY_LAYER_SERVICES_STRUCT
15251532
VOID (*gx_display_layer_hide)(INT layer);
15261533
VOID (*gx_display_layer_alpha_set)(INT layer, GX_UBYTE alpha);
15271534
VOID (*gx_display_layer_offset_set)(INT layer, GX_VALUE xoffset, GX_VALUE yoffset);
1535+
VOID (*gx_display_layer_active_display_area_set)(INT layer, GX_RECTANGLE *size);
15281536
} GX_DISPLAY_LAYER_SERVICES;
15291537

15301538
#if defined(GX_MOUSE_SUPPORT)
@@ -3028,6 +3036,7 @@ typedef struct GX_FIXED_POINT_STRUCT
30283036
#define gx_canvas_rotated_text_draw_ext _gx_canvas_rotated_text_draw_ext
30293037
#define gx_canvas_shift _gx_canvas_shift
30303038
#define gx_canvas_show _gx_canvas_show
3039+
#define gx_canvas_aligned_text_draw _gx_canvas_aligned_text_draw
30313040
#if defined(GX_ENABLE_DEPRECATED_STRING_API)
30323041
#define gx_canvas_text_draw _gx_canvas_text_draw
30333042
#endif
@@ -3694,6 +3703,7 @@ UINT _gx_canvas_rotated_text_draw_ext(GX_CONST GX_STRING *text, GX_VALUE xcenter
36943703
UINT _gx_canvas_shift(GX_CANVAS *canvas, GX_VALUE x, GX_VALUE y);
36953704
UINT _gx_canvas_show(GX_CANVAS *canvas);
36963705

3706+
UINT _gx_canvas_aligned_text_draw(GX_CONST GX_STRING *string, GX_RECTANGLE *rectangle, ULONG alignment);
36973707
#if defined(GX_ENABLE_DEPRECATED_STRING_API)
36983708
UINT _gx_canvas_text_draw(GX_VALUE x_start, GX_VALUE y_start, GX_CONST GX_CHAR *string, INT length);
36993709
#endif
@@ -4508,6 +4518,7 @@ UINT _gx_window_wallpaper_set(GX_WINDOW *window, GX_RESOURCE_ID wallpaper_id, GX
45084518
#define gx_canvas_rotated_text_draw_ext _gxe_canvas_rotated_text_draw_ext
45094519
#define gx_canvas_shift _gxe_canvas_shift
45104520
#define gx_canvas_show _gxe_canvas_show
4521+
#define gx_canvas_aligned_text_draw _gxe_canvas_aligned_text_draw
45114522
#if defined (GX_ENABLE_DEPRECATED_STRING_API)
45124523
#define gx_canvas_text_draw _gxe_canvas_text_draw
45134524
#endif
@@ -5171,6 +5182,7 @@ UINT _gxe_canvas_rotated_text_draw_ext(GX_CONST GX_STRING *text, GX_VALUE xcente
51715182
UINT _gxe_canvas_shift(GX_CANVAS *canvas, GX_VALUE x, GX_VALUE y);
51725183
UINT _gxe_canvas_show(GX_CANVAS *canvas);
51735184

5185+
UINT _gxe_canvas_aligned_text_draw(GX_CONST GX_STRING *string, GX_RECTANGLE *rectangle, ULONG alignment);
51745186
#if defined(GX_ENABLE_DEPRECATED_STRING_API)
51755187
UINT _gxe_canvas_text_draw(GX_VALUE x_start, GX_VALUE y_start, GX_CONST GX_CHAR *string, INT length);
51765188
#endif

common/inc/gx_canvas.h

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
/* COMPONENT DEFINITION RELEASE */
2727
/* */
2828
/* gx_canvas.h PORTABLE C */
29-
/* 6.1 */
29+
/* 6.1.11 */
3030
/* AUTHOR */
3131
/* */
3232
/* Kenneth Maxwell, Microsoft Corporation */
@@ -44,6 +44,9 @@
4444
/* 05-19-2020 Kenneth Maxwell Initial Version 6.0 */
4545
/* 09-30-2020 Kenneth Maxwell Modified comment(s), */
4646
/* resulting in version 6.1 */
47+
/* 04-25-2022 Ting Zhu Modified comment(s), */
48+
/* added new declarations, */
49+
/* resulting in version 6.1.11 */
4750
/* */
4851
/**************************************************************************/
4952

@@ -107,6 +110,7 @@ UINT _gx_canvas_rotated_text_draw_ext(GX_CONST GX_STRING *text, GX_VALUE xcenter
107110
UINT _gx_canvas_shift(GX_CANVAS *canvas, GX_VALUE x, GX_VALUE y);
108111
UINT _gx_canvas_show(GX_CANVAS *canvas);
109112

113+
UINT _gx_canvas_aligned_text_draw(GX_CONST GX_STRING *string, GX_RECTANGLE *rectangle, ULONG alignment);
110114
#if defined(GX_ENABLE_DEPRECATED_STRING_API)
111115
UINT _gx_canvas_text_draw(GX_VALUE x_start, GX_VALUE y_start, GX_CONST GX_CHAR *string, INT length);
112116
#endif
@@ -153,6 +157,7 @@ UINT _gxe_canvas_rotated_text_draw(GX_CONST GX_CHAR *text, GX_VALUE xcenter, GX
153157
UINT _gxe_canvas_rotated_text_draw_ext(GX_CONST GX_STRING *text, GX_VALUE xcenter, GX_VALUE ycenter, INT angle);
154158
UINT _gxe_canvas_shift(GX_CANVAS *canvas, GX_VALUE x, GX_VALUE y);
155159
UINT _gxe_canvas_show(GX_CANVAS *canvas);
160+
UINT _gxe_canvas_aligned_text_draw(GX_CONST GX_STRING *string, GX_RECTANGLE *rectangle, ULONG alignment);
156161
#if defined(GX_ENABLE_DEPRECATED_STRING_API)
157162
UINT _gxe_canvas_text_draw(GX_VALUE x_start, GX_VALUE y_start, GX_CONST GX_CHAR *string, INT length);
158163
#endif

common/inc/gx_system.h

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
/* COMPONENT DEFINITION RELEASE */
2727
/* */
2828
/* gx_system.h PORTABLE C */
29-
/* 6.1.3 */
29+
/* 6.1.11 */
3030
/* AUTHOR */
3131
/* */
3232
/* Kenneth Maxwell, Microsoft Corporation */
@@ -50,6 +50,10 @@
5050
/* added GX_DISABLE_THREADX_ */
5151
/* TIMER_SOURCE configuration, */
5252
/* resulting in version 6.1.3 */
53+
/* 04-25-2022 Ting Zhu Modified comment(s), */
54+
/* added new parameter to */
55+
/* _gx_system_pen_flick_test, */
56+
/* resulting in version 6.1.11 */
5357
/* */
5458
/**************************************************************************/
5559

@@ -116,7 +120,7 @@ VOID _gx_system_input_unlock(VOID);
116120

117121
VOID _gx_system_pen_speed_init(GX_POINT *current);
118122
VOID _gx_system_pen_speed_update(GX_POINT *current);
119-
VOID _gx_system_pen_flick_test(VOID);
123+
VOID _gx_system_pen_flick_test(GX_WIDGET *target);
120124
UINT _gx_system_pen_configure(GX_PEN_CONFIGURATION *pen_configuration);
121125

122126
UINT _gx_system_private_string_copy(GX_STRING *ptr_address, GX_CONST GX_STRING *text);

common/src/gx_animation_drag_tracking.c

Lines changed: 60 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,14 @@
2727
#include "gx_api.h"
2828
#include "gx_widget.h"
2929
#include "gx_animation.h"
30-
30+
#include "gx_canvas.h"
3131

3232
/**************************************************************************/
3333
/* */
3434
/* FUNCTION RELEASE */
3535
/* */
3636
/* _gx_animation_drag_tracking PORTABLE C */
37-
/* 6.1 */
37+
/* 6.1.11 */
3838
/* AUTHOR */
3939
/* */
4040
/* Kenneth Maxwell, Microsoft Corporation */
@@ -73,25 +73,32 @@
7373
/* 05-19-2020 Kenneth Maxwell Initial Version 6.0 */
7474
/* 09-30-2020 Kenneth Maxwell Modified comment(s), */
7575
/* resulting in version 6.1 */
76+
/* 04-25-2022 Ting Zhu Modified comment(s), */
77+
/* added canvas and block move */
78+
/* support, */
79+
/* resulting in version 6.1.11 */
7680
/* */
7781
/**************************************************************************/
7882
UINT _gx_animation_drag_tracking(GX_ANIMATION *animation, GX_POINT penpos)
7983
{
80-
GX_VALUE delta_x = 0;
81-
GX_VALUE delta_y = 0;
82-
GX_VALUE shift_x = 0;
83-
GX_VALUE shift_y = 0;
84-
GX_VALUE last_pos;
85-
GX_VALUE start_pos;
86-
GX_VALUE pen_pos;
87-
GX_WIDGET *target_1 = GX_NULL;
88-
GX_WIDGET *target_2 = GX_NULL;
84+
GX_VALUE delta_x = 0;
85+
GX_VALUE delta_y = 0;
86+
GX_VALUE shift_x = 0;
87+
GX_VALUE shift_y = 0;
88+
GX_VALUE last_pos;
89+
GX_VALUE start_pos;
90+
GX_VALUE pen_pos;
91+
GX_WIDGET *target_1 = GX_NULL;
92+
GX_WIDGET *target_2 = GX_NULL;
93+
GX_WIDGET *parent;
94+
GX_RECTANGLE block;
95+
GX_VALUE border_width;
8996

9097
if (animation -> gx_animation_slide_target_index_1 >= 0)
9198
{
9299
target_1 = animation -> gx_animation_info.gx_animation_slide_screen_list[animation -> gx_animation_slide_target_index_1];
93100
}
94-
101+
95102
if (target_1 == GX_NULL)
96103
{
97104
return GX_SUCCESS;
@@ -131,6 +138,13 @@ GX_WIDGET *target_2 = GX_NULL;
131138
_gx_widget_detach(target_2);
132139
}
133140

141+
if (animation -> gx_animation_canvas)
142+
{
143+
_gx_widget_shift(target_1,
144+
animation -> gx_animation_canvas -> gx_canvas_display_offset_x,
145+
animation -> gx_animation_canvas -> gx_canvas_display_offset_y, GX_TRUE);
146+
}
147+
134148
_gx_animation_drag_tracking_start(animation, penpos);
135149

136150
if (animation -> gx_animation_slide_target_index_2 >= 0)
@@ -154,11 +168,7 @@ GX_WIDGET *target_2 = GX_NULL;
154168
}
155169
}
156170

157-
if (target_2)
158-
{
159-
_gx_widget_shift(target_2, (GX_VALUE)(shift_x + delta_x), (GX_VALUE)(shift_y + delta_y), GX_TRUE);
160-
}
161-
else
171+
if (!target_2)
162172
{
163173
if (animation -> gx_animation_info.gx_animation_style & GX_ANIMATION_VERTICAL)
164174
{
@@ -172,7 +182,39 @@ GX_WIDGET *target_2 = GX_NULL;
172182
}
173183
}
174184

175-
_gx_widget_shift(target_1, (GX_VALUE)(shift_x + delta_x), (GX_VALUE)(shift_y + delta_y), GX_TRUE);
185+
if (animation -> gx_animation_canvas)
186+
{
187+
/* adjust canvas offset */
188+
_gx_canvas_offset_set(animation -> gx_animation_canvas,
189+
(GX_VALUE)(animation -> gx_animation_canvas -> gx_canvas_display_offset_x + shift_x + delta_x),
190+
(GX_VALUE)(animation -> gx_animation_canvas -> gx_canvas_display_offset_y + shift_y + delta_y));
191+
}
192+
else
193+
{
194+
if (animation -> gx_animation_info.gx_animation_style & GX_ANIMATION_BLOCK_MOVE)
195+
{
196+
if (target_2)
197+
{
198+
_gx_widget_scroll_shift(target_2, (GX_VALUE)(shift_x + delta_x), (GX_VALUE)(shift_y + delta_y), GX_TRUE);
199+
}
200+
201+
_gx_widget_scroll_shift(target_1, (GX_VALUE)(shift_x + delta_x), (GX_VALUE)(shift_y + delta_y), GX_TRUE);
202+
203+
parent = animation -> gx_animation_info.gx_animation_parent;
204+
_gx_widget_border_width_get(parent, &border_width);
205+
_gx_widget_client_get(parent, border_width, &block);
206+
_gx_widget_block_move(parent, &block, (GX_VALUE)(shift_x + delta_x), (GX_VALUE)(shift_y + delta_y));
207+
}
208+
else
209+
{
210+
if (target_2)
211+
{
212+
_gx_widget_shift(target_2, (GX_VALUE)(shift_x + delta_x), (GX_VALUE)(shift_y + delta_y), GX_TRUE);
213+
}
214+
215+
_gx_widget_shift(target_1, (GX_VALUE)(shift_x + delta_x), (GX_VALUE)(shift_y + delta_y), GX_TRUE);
216+
}
217+
}
176218

177219
animation -> gx_animation_slide_tracking_current_pos = pen_pos;
178220
}

0 commit comments

Comments
 (0)