// CommandBarsDesigner.h // // (c)1998-2025 Codejock Software, All Rights Reserved. // // THIS SOURCE FILE IS THE PROPERTY OF CODEJOCK SOFTWARE AND IS NOT TO BE // RE-DISTRIBUTED BY ANY MEANS WHATSOEVER WITHOUT THE EXPRESSED WRITTEN // CONSENT OF CODEJOCK SOFTWARE. // // THIS SOURCE CODE CAN ONLY BE USED UNDER THE TERMS AND CONDITIONS OUTLINED // IN THE XTREME TOOLKIT PRO LICENSE AGREEMENT. CODEJOCK SOFTWARE GRANTS TO // YOU (ONE SOFTWARE DEVELOPER) THE LIMITED RIGHT TO USE THIS SOFTWARE ON A // SINGLE COMPUTER. // // CONTACT INFORMATION: // support@codejock.com // http://www.codejock.com // ///////////////////////////////////////////////////////////////////////////// #if !defined(AFX_COMMANDBARSDESIGNER_H__3D7EA821_8D9C_4378_944E_9FAFC5ADF727__INCLUDED_) # define AFX_COMMANDBARSDESIGNER_H__3D7EA821_8D9C_4378_944E_9FAFC5ADF727__INCLUDED_ # if _MSC_VER > 1000 # pragma once # endif // _MSC_VER > 1000 # ifndef __AFXWIN_H__ # error include 'stdafx.h' before including this file for PCH # endif # include "resource.h" // main symbols const LPCTSTR lpTypes[] = { NULL, _T("xtpControlButton"), _T("xtpControlPopup"), _T("xtpControlButtonPopup"), _T("xtpControlSplitButtonPopup"), _T("xtpControlComboBox"), _T("xtpControlEdit"), NULL, _T("xtpControlLabel"), _T("xtpControlCheckBox"), _T("xtpControlGallery"), _T("xtpControlRadioButton") }; enum CurrentUtilityTheme { DefaultTheme = 0, Office2016 = 1 }; ///////////////////////////////////////////////////////////////////////////// // CCommandBarsDesignerApp: // See CommandBarsDesigner.cpp for the implementation of this class // class CCommandBarsDesignerApp : public CXTPWinApp { public: CCommandBarsDesignerApp(); public: virtual BOOL InitInstance(); CMultiDocTemplate* m_pDocTemplate; BOOL m_bRunAutomated; BOOL m_bNewBlank; private: virtual BOOL OnCmdMsg(UINT nID, int nCode, void* pExtra, AFX_CMDHANDLERINFO* pHandlerInfo); BOOL CheckPreviewAppMode(); BOOL ExecuteDesignerFlow(); BOOL ExecutePreviewFlow(); COleTemplateServer m_server; HWND m_hwndPreviewOwner; BOOL m_bPreviewMode; afx_msg void OnAppAbout(); afx_msg void OnFileNew(); afx_msg void OnFileNewBlank(); afx_msg void OnFileOpen(); afx_msg void OnFilePrintSetup(); DECLARE_MESSAGE_MAP() }; extern CString StripChars(CString str); extern void XTPStringRemove(CString& str, TCHAR chRemove); extern int XTPStringDelete(CString& str, int nIndex, int nCount = 1); extern COLORREF GetStaticFrameColor(); extern BOOL IsRunAutomated(); AFX_INLINE BOOL IsXMLEngineAvailable() { static BOOL bAvailable = (BOOL)-1; if (bAvailable == (BOOL)-1) { CXTPDOMDocumentPtr xmlDocPtr; bAvailable = SUCCEEDED(xmlDocPtr.CreateInstance(CLSID_XTPDOMDocument)); } return bAvailable; } class CPaneHolder : public CWnd { public: virtual CObject* RefreshPropertyGrid(CXTPPropertyGrid* pPropertyGrid) { UNREFERENCED_PARAMETER(pPropertyGrid); return NULL; } virtual BOOL OnPropertyGridValueChanged(CObject* pActiveObject, CXTPPropertyGridItem* pItem) { UNREFERENCED_PARAMETER(pActiveObject); UNREFERENCED_PARAMETER(pItem); return FALSE; } CurrentUtilityTheme m_nTheme; virtual void RefreshTheme() { } }; class CDesignerRectTracker : public CRectTracker { public: explicit CDesignerRectTracker(BOOL bPreviewMode = FALSE) : CRectTracker(CRect(10, 10, 310, 289), CRectTracker::resizeOutside | (!bPreviewMode ? CRectTracker::hatchedBorder : 0)) { m_nHandleSize = 7; m_sizeMin = CSize(150, 120); } virtual UINT GetHandleMask() const { return 32 + 4 + 64; } }; ///////////////////////////////////////////////////////////////////////////// //{{AFX_INSERT_LOCATION}} // Microsoft Visual C++ will insert additional declarations immediately before the previous line. #endif // !defined(AFX_COMMANDBARSDESIGNER_H__3D7EA821_8D9C_4378_944E_9FAFC5ADF727__INCLUDED_)