RT1050 GUI demo using emWin library

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers SLIDER_Private.h Source File

SLIDER_Private.h

00001 /*********************************************************************
00002 *                SEGGER Microcontroller GmbH & Co. KG                *
00003 *        Solutions for real time microcontroller applications        *
00004 **********************************************************************
00005 *                                                                    *
00006 *        (c) 1996 - 2016  SEGGER Microcontroller GmbH & Co. KG       *
00007 *                                                                    *
00008 *        Internet: www.segger.com    Support:  support@segger.com    *
00009 *                                                                    *
00010 **********************************************************************
00011 
00012 ** emWin V5.38 - Graphical user interface for embedded applications **
00013 All  Intellectual Property rights  in the Software belongs to  SEGGER.
00014 emWin is protected by  international copyright laws.  Knowledge of the
00015 source code may not be used to write a similar product.  This file may
00016 only be used in accordance with the following terms:
00017 
00018 The software has been licensed to  NXP Semiconductors USA, Inc.  whose
00019 registered  office  is  situated  at 411 E. Plumeria Drive, San  Jose,
00020 CA 95134, USA  solely for  the  purposes  of  creating  libraries  for
00021 NXPs M0, M3/M4 and  ARM7/9 processor-based  devices,  sublicensed  and
00022 distributed under the terms and conditions of the NXP End User License
00023 Agreement.
00024 Full source code is available at: www.segger.com
00025 
00026 We appreciate your understanding and fairness.
00027 ----------------------------------------------------------------------
00028 Licensing information
00029 
00030 Licensor:                 SEGGER Microcontroller Systems LLC
00031 Licensed to:              NXP Semiconductors, 1109 McKay Dr, M/S 76, San Jose, CA 95131, USA
00032 Licensed SEGGER software: emWin
00033 License number:           GUI-00186
00034 License model:            emWin License Agreement, dated August 20th 2011
00035 Licensed product:         -
00036 Licensed platform:        NXP's ARM 7/9, Cortex-M0,M3,M4
00037 Licensed number of seats: -
00038 ----------------------------------------------------------------------
00039 File        : SLIDER_Private.h
00040 Purpose     : SLIDER private header file
00041 --------------------END-OF-HEADER-------------------------------------
00042 */
00043 
00044 #ifndef SLIDER_PRIVATE_H
00045 #define SLIDER_PRIVATE_H
00046 
00047 #include "WM.h"
00048 #include "WIDGET.h"
00049 #include "SLIDER.h"
00050 
00051 #if GUI_WINSUPPORT
00052 
00053 /*********************************************************************
00054 *
00055 *       Defines
00056 *
00057 **********************************************************************
00058 */
00059 //
00060 // Flags
00061 //
00062 #define SLIDER_FLAG_DRAW_FOCUS_RECT (1 << 0)
00063 
00064 /*********************************************************************
00065 *
00066 *       Object definition
00067 *
00068 **********************************************************************
00069 */
00070 typedef struct {
00071   WIDGET_DRAW_ITEM_FUNC * pfDrawSkin;
00072 } SLIDER_SKIN_PRIVATE;
00073 
00074 typedef struct {
00075   U8                  Flags;
00076   GUI_COLOR           BkColor;
00077   GUI_COLOR           BarColor;
00078   GUI_COLOR           FocusColor;
00079   GUI_COLOR           TickColor;
00080   SLIDER_SKIN_PRIVATE SkinPrivate;
00081 } SLIDER_PROPS;
00082 
00083 typedef struct {
00084   WIDGET              Widget;
00085   SLIDER_PROPS        Props;
00086   WIDGET_SKIN const * pWidgetSkin;
00087   int                 NumTicks;
00088   int                 Max;
00089   int                 Min;
00090   int                 v;
00091   I16                 Width;
00092 } SLIDER_Obj;
00093 
00094 /*********************************************************************
00095 *
00096 *       Macros for internal use
00097 *
00098 **********************************************************************
00099 */
00100 #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_CHECK_ALL
00101   #define SLIDER_INIT_ID(p) (p->Widget.DebugId = SLIDER_ID)
00102 #else
00103   #define SLIDER_INIT_ID(p)
00104 #endif
00105 
00106 #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_CHECK_ALL
00107   SLIDER_Obj * SLIDER_LockH(SLIDER_Handle h);
00108   #define SLIDER_LOCK_H(h)  SLIDER_LockH(h)
00109 #else
00110   #define SLIDER_LOCK_H(h)  (SLIDER_Obj *)GUI_LOCK_H(h)
00111 #endif
00112 
00113 #ifndef   SLIDER_SUPPORT_TRANSPARENCY
00114   #define SLIDER_SUPPORT_TRANSPARENCY WM_SUPPORT_TRANSPARENCY
00115 #endif
00116 
00117 /*********************************************************************
00118 *
00119 *       Public data (internal defaults)
00120 *
00121 **********************************************************************
00122 */
00123 extern       SLIDER_PROPS   SLIDER__DefaultProps;
00124 extern const WIDGET_SKIN    SLIDER__SkinClassic;
00125 extern       WIDGET_SKIN    SLIDER__Skin;
00126 extern const WIDGET_SKIN  * SLIDER__pSkinDefault;
00127 
00128 #endif  // GUI_WINSUPPORT
00129 #endif  // SLIDER_PRIVATE_H
00130 
00131 /*************************** End of file ****************************/