1 /**************************************************************************/
2 /* */
3 /* Copyright (c) Microsoft Corporation. All rights reserved. */
4 /* */
5 /* This software is licensed under the Microsoft Software License */
6 /* Terms for Microsoft Azure RTOS. Full text of the license can be */
7 /* found in the LICENSE file at https://aka.ms/AzureRTOS_EULA */
8 /* and in the root directory of this software. */
9 /* */
10 /**************************************************************************/
11
12
13 /**************************************************************************/
14 /**************************************************************************/
15 /** */
16 /** GUIX Component */
17 /** */
18 /** System Management (System) */
19 /** */
20 /**************************************************************************/
21
22 #define GX_SOURCE_CODE
23
24
25 /* Include necessary system files. */
26
27 #include "gx_api.h"
28 #include "gx_display.h"
29
30 /**************************************************************************/
31 /* */
32 /* FUNCTION RELEASE */
33 /* */
34 /* _gx_display_string_table_get PORTABLE C */
35 /* 6.1 */
36 /* AUTHOR */
37 /* */
38 /* Kenneth Maxwell, Microsoft Corporation */
39 /* */
40 /* DESCRIPTION (Deprecated) */
41 /* */
42 /* This function returns a pointer to the display string table. */
43 /* */
44 /* INPUT */
45 /* */
46 /* display Pointer to display instance. */
47 /* language The language the string */
48 /* table is associated with */
49 /* get_table Pointer to string table */
50 /* get_size Number of strings in table */
51 /* */
52 /* OUTPUT */
53 /* */
54 /* status Completion status */
55 /* */
56 /* CALLS */
57 /* */
58 /* None */
59 /* */
60 /* CALLED BY */
61 /* */
62 /* Application Code */
63 /* */
64 /* RELEASE HISTORY */
65 /* */
66 /* DATE NAME DESCRIPTION */
67 /* */
68 /* 05-19-2020 Kenneth Maxwell Initial Version 6.0 */
69 /* 09-30-2020 Kenneth Maxwell Modified comment(s), */
70 /* resulting in version 6.1 */
71 /* */
72 /**************************************************************************/
73 #if defined(GX_ENABLE_DEPRECATED_STRING_API)
_gx_display_string_table_get(GX_DISPLAY * display,GX_UBYTE language,GX_CHAR *** put_table,UINT * put_size)74 UINT _gx_display_string_table_get(GX_DISPLAY *display, GX_UBYTE language, GX_CHAR ***put_table, UINT *put_size)
75 {
76 if(put_table)
77 {
78 if(display -> gx_display_language_table_deprecated)
79 {
80 *put_table = (GX_CHAR **)display -> gx_display_language_table_deprecated[language];
81 }
82 else
83 {
84 *put_table = GX_NULL;
85 }
86 }
87
88 if(put_size)
89 {
90 *put_size = display -> gx_display_string_table_size;
91 }
92
93 return GX_SUCCESS;
94 }
95 #endif
96
97 /**************************************************************************/
98 /* */
99 /* FUNCTION RELEASE */
100 /* */
101 /* _gx_display_string_table_get_ext PORTABLE C */
102 /* 6.1 */
103 /* AUTHOR */
104 /* */
105 /* Kenneth Maxwell, Microsoft Corporation */
106 /* */
107 /* DESCRIPTION */
108 /* */
109 /* This function returns a pointer to the display string table. */
110 /* */
111 /* INPUT */
112 /* */
113 /* display Pointer to display instance. */
114 /* language The language the string */
115 /* table is associated with */
116 /* put_table Pointer to string table */
117 /* put_size Number of strings in table */
118 /* */
119 /* OUTPUT */
120 /* */
121 /* status Completion status */
122 /* */
123 /* CALLS */
124 /* */
125 /* None */
126 /* */
127 /* CALLED BY */
128 /* */
129 /* Application Code */
130 /* */
131 /* RELEASE HISTORY */
132 /* */
133 /* DATE NAME DESCRIPTION */
134 /* */
135 /* 05-19-2020 Kenneth Maxwell Initial Version 6.0 */
136 /* 09-30-2020 Kenneth Maxwell Modified comment(s), */
137 /* resulting in version 6.1 */
138 /* */
139 /**************************************************************************/
_gx_display_string_table_get_ext(GX_DISPLAY * display,GX_UBYTE language,GX_STRING ** put_table,UINT * put_size)140 UINT _gx_display_string_table_get_ext(GX_DISPLAY *display, GX_UBYTE language, GX_STRING **put_table, UINT *put_size)
141 {
142 if (put_table)
143 {
144 if (display -> gx_display_language_table)
145 {
146 *put_table = (GX_STRING *) display -> gx_display_language_table[language];
147 }
148 else
149 {
150 *put_table = GX_NULL;
151 }
152 }
153 if (put_size)
154 {
155 *put_size = display -> gx_display_string_table_size;
156 }
157 return GX_SUCCESS;
158 }
159
160
161