CtrlColorBrowsingModeRadio.cpp 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. /* Copyright (c) 2002-2012 Croteam Ltd.
  2. This program is free software; you can redistribute it and/or modify
  3. it under the terms of version 2 of the GNU General Public License as published by
  4. the Free Software Foundation
  5. This program is distributed in the hope that it will be useful,
  6. but WITHOUT ANY WARRANTY; without even the implied warranty of
  7. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  8. GNU General Public License for more details.
  9. You should have received a copy of the GNU General Public License along
  10. with this program; if not, write to the Free Software Foundation, Inc.,
  11. 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */
  12. // CtrlColorBrowsingModeRadio.cpp : implementation file
  13. //
  14. #include "stdafx.h"
  15. #ifdef _DEBUG
  16. #undef new
  17. #define new DEBUG_NEW
  18. #undef THIS_FILE
  19. static char THIS_FILE[] = __FILE__;
  20. #endif
  21. /////////////////////////////////////////////////////////////////////////////
  22. // CCtrlColorBrowsingModeRadio
  23. CCtrlColorBrowsingModeRadio::CCtrlColorBrowsingModeRadio()
  24. {
  25. }
  26. CCtrlColorBrowsingModeRadio::~CCtrlColorBrowsingModeRadio()
  27. {
  28. }
  29. void CCtrlColorBrowsingModeRadio::SetDialogPtr( CPropertyComboBar *pDialog)
  30. {
  31. m_pDialog = pDialog;
  32. }
  33. BEGIN_MESSAGE_MAP(CCtrlColorBrowsingModeRadio, CButton)
  34. //{{AFX_MSG_MAP(CCtrlColorBrowsingModeRadio)
  35. ON_CONTROL_REFLECT(BN_CLICKED, OnClicked)
  36. //}}AFX_MSG_MAP
  37. END_MESSAGE_MAP()
  38. /////////////////////////////////////////////////////////////////////////////
  39. // CCtrlColorBrowsingModeRadio message handlers
  40. void CCtrlColorBrowsingModeRadio::OnClicked()
  41. {
  42. // don't do anything if document doesn't exist
  43. if( theApp.GetDocument() == NULL) return;
  44. // select clicked axis radio
  45. m_pDialog->SelectColorBrowsingModeRadio( this);
  46. // show that second axis have been selected
  47. m_pDialog->ArrangeControls();
  48. }