From fe091f0e1acb2245a009847525e6d3a56d145623 Mon Sep 17 00:00:00 2001 From: Hrvoje Jasak Date: Thu, 27 Aug 2015 21:42:32 +0100 Subject: [PATCH] Added missing Win compilation file for tecsrc --- .../foamToTecplot360/tecio/tecsrc/W__BASE.h | 105 ++++++++++++++++++ 1 file changed, 105 insertions(+) create mode 100644 applications/utilities/postProcessing/dataConversion/foamToTecplot360/tecio/tecsrc/W__BASE.h diff --git a/applications/utilities/postProcessing/dataConversion/foamToTecplot360/tecio/tecsrc/W__BASE.h b/applications/utilities/postProcessing/dataConversion/foamToTecplot360/tecio/tecsrc/W__BASE.h new file mode 100644 index 000000000..641c91b95 --- /dev/null +++ b/applications/utilities/postProcessing/dataConversion/foamToTecplot360/tecio/tecsrc/W__BASE.h @@ -0,0 +1,105 @@ +/* +****************************************************************** +****************************************************************** +******* ******** +****** (C) 1988-2010 Tecplot, Inc. ******* +******* ******** +****************************************************************** +****************************************************************** +*/ +#ifndef _W__BASE_h +#define _W__BASE_h + +#if defined TECPLOTKERNEL + +#include "C__BASE.h" + +typedef ULONG_PTR Widget; +#define NULLWIDGET ((unsigned long)0) + +extern BOOL MSWinIsLargeFont; +extern CWnd *(TPClassArray[TPNUMCLASSES]); + +typedef struct +{ + CRect Rect; + BOOL RectSet; + CRect MinRect; // Only used for resizable dialogs + BOOL MinRectSet; // Only used for resizable dialogs +} TPDialogRect_s; + +extern TPDialogRect_s TPDialogRect[TPNUMCLASSES]; + +#define WindowIsResizable(wnd) ((wnd)->GetStyle() & WS_THICKFRAME) + +/* + * NOTE: C = class number in TPClassArray (see C__BASE.h) + * 0=no class + * 1=TPMAINWND + * O = offset within container + * 0 means the container itself + * any other number is the offset within control (starting at 1) + * I = control number/id + * 0 = class itself + * for bitmap button groups, this is the container id + * for all other controls, this is the control id + * WidgetValue 0 is the NULL widget. + */ + +//#define MAKEWIDGET(C,I,O) ((Widget)((((C)&0xFFFF)<<16)|(((O)&0xFF)<<8)|((I)&0xFF))) + +#define CLASS_NUM_BITS 10 +#define ITEM_ID_BITS 16 /* must be at least 16-bits to fit in the workarea */ +#define ITEM_OFFSET_BITS 6 + +/* The FILTER is also the maximum value. */ +#define CLASS_NUM_FILTER ((1<> ITEM_ID_BITS) >> ITEM_OFFSET_BITS; +} +inline INT_PTR GetItemID(Widget W) +{ + return (W >> ITEM_OFFSET_BITS) & ITEM_ID_FILTER; +} +inline INT_PTR GetItemOffset(Widget W) +{ + return W & ITEM_OFFSET_FILTER; +} + +/* + * We cannot use Boolean_t here because it is not defined yet. + */ +extern CWnd *GetWindowFromWidget(Widget); +extern CWnd *GetParentWndFromWidget(Widget); +extern Widget GetWidgetFromWindow(CWnd *); +extern BOOL WidgetExists(Widget W); +extern BOOL TPEnableDialog(CWnd *wnd, + BOOL bEnable); +extern void TPEnableAllDialogs(BOOL bEnable); +extern TPDialogRect_s* GetDialogRectFromWidget(Widget); +extern TPDialogRect_s* GetDialogRectFromWindow(CWnd* pWnd); + + +#endif /* TECPLOTKERNEL */ + +/* + * This is the start of the translated string ID's + * in the resource file + */ +#define TP_TRANSLATED_STRING_START_ID 20000 + +#endif