aduiTabExtension.h 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. //////////////////////////////////////////////////////////////////////////////
  2. //
  3. // Copyright 2015 Autodesk, Inc. All rights reserved.
  4. //
  5. // Use of this software is subject to the terms of the Autodesk license
  6. // agreement provided at the time of installation or download, or which
  7. // otherwise accompanies this software in either electronic or hard copy form.
  8. //
  9. //////////////////////////////////////////////////////////////////////////////
  10. //
  11. // DESCRIPTION
  12. //
  13. // Include file for classes dealing with extended tabs.
  14. //
  15. /////////////////////////////////////////////////////////////////////////////
  16. #ifndef _aduiTabExtension_h
  17. #define _aduiTabExtension_h
  18. #pragma pack (push, 8)
  19. /////////////////////////////////////////////////////////////////////////////
  20. // This class manages extended tabs in a tab extensible dialog.
  21. // A tab extensible dialog has one instance of this class in the
  22. // dialog object which is initialized in the dialog's constructor.
  23. class ADUI_PORT CAdUiTabExtensionManager {
  24. public:
  25. CAdUiTabExtensionManager ();
  26. virtual ~CAdUiTabExtensionManager ();
  27. // Tab Extension Manager
  28. private:
  29. CString m_dlgName; // Buffer for GetDialogName().
  30. CAdUiTabMainDialog *m_pDlg; // The tab extensible dialog.
  31. CAdUiTab *m_pTabCtrl; // The tab control in the dialog.
  32. // Adds tabs to a dialog that have been registered by a particular application.
  33. BOOL AddApplicationTabs (LPCTSTR pszAppName);
  34. public:
  35. // This function in called in the OnInitDialog() of a tab extensible
  36. // dialog to add extended tabs to itself.
  37. int AddExtendedTabs ();
  38. // Actually adds an extended tab.
  39. virtual BOOL AddTab (
  40. HINSTANCE hInstRes,
  41. UINT uTemplateID,
  42. LPCTSTR pszTabName, // since templates don't have captions...
  43. CAdUiTabChildDialog *pDialog
  44. );
  45. // Return the dialog name used as a registry key for extended tabs.
  46. virtual LPCTSTR GetDialogName ();
  47. // Initialize the manager.
  48. void Initialize (CAdUiTab *pTabCtrl, CAdUiTabMainDialog *pDlg);
  49. CAdUiTab* GetTabControl() const {return m_pTabCtrl;}
  50. };
  51. /////////////////////////////////////////////////////////////////////////////
  52. #pragma pack (pop)
  53. #endif
  54. /////////////////////////////////////////////////////////////////////////////