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 /** Button Management (Button) */
19 /** */
20 /**************************************************************************/
21
22 #define GX_SOURCE_CODE
23
24
25 /* Include necessary system files. */
26
27 #include "gx_api.h"
28 #include "gx_system.h"
29 #include "gx_display.h"
30 #include "gx_context.h"
31 #include "gx_widget.h"
32 #include "gx_button.h"
33 #include "gx_port.h"
34
35 /* Bring in externs for caller checking code. */
36 GX_CALLER_CHECKING_EXTERNS
37
38
39 /**************************************************************************/
40 /* */
41 /* FUNCTION RELEASE */
42 /* */
43 /* _gxe_multi_line_text_button_text_id_set PORTABLE C */
44 /* 6.1 */
45 /* AUTHOR */
46 /* */
47 /* Kenneth Maxwell, Microsoft Corporation */
48 /* */
49 /* DESCRIPTION */
50 /* */
51 /* This function checks for errors in the button text assignment */
52 /* */
53 /* INPUT */
54 /* */
55 /* button Pointer to the button */
56 /* control block */
57 /* string_id Resource ID from string table */
58 /* OUTPUT */
59 /* */
60 /* status Completion status */
61 /* */
62 /* CALLS */
63 /* */
64 /* _gx_multi_line_text_button_text_id_set Actual function */
65 /* */
66 /* CALLED BY */
67 /* */
68 /* Application Code */
69 /* */
70 /* RELEASE HISTORY */
71 /* */
72 /* DATE NAME DESCRIPTION */
73 /* */
74 /* 05-19-2020 Kenneth Maxwell Initial Version 6.0 */
75 /* 09-30-2020 Kenneth Maxwell Modified comment(s), */
76 /* resulting in version 6.1 */
77 /* */
78 /**************************************************************************/
_gxe_multi_line_text_button_text_id_set(GX_MULTI_LINE_TEXT_BUTTON * button,GX_RESOURCE_ID string_id)79 UINT _gxe_multi_line_text_button_text_id_set(GX_MULTI_LINE_TEXT_BUTTON *button,
80 GX_RESOURCE_ID string_id)
81 {
82 UINT status;
83
84 /* Check for appropriate caller. */
85 GX_INIT_AND_THREADS_CALLER_CHECKING
86
87 /* Check for invalid input pointers. */
88 if (button == GX_NULL)
89 {
90 return(GX_PTR_ERROR);
91 }
92
93 /* Call the actual button draw function. */
94 status = _gx_multi_line_text_button_text_id_set(button, string_id);
95
96 /* Return completion status. */
97 return status;
98 }
99
100