CSelectionView Class Reference

Search Toolkit Book for CSelectionView

#include <selection_view.hpp>

Inheritance diagram for CSelectionView:

Inheritance graph
[legend]
Collaboration diagram for CSelectionView:

Collaboration graph
[legend]
List of all members.

Detailed Description

CSelectionView.

Definition at line 156 of file selection_view.hpp.

Public Member Functions

 CSelectionView ()
virtual ~CSelectionView ()
IView
virtual const CViewTypeDescriptorGetTypeDescriptor () const
 IView interface implementation.
virtual void SetWorkbench (IWorkbench *workbench)
 connect / disconnect this view with / from Workbench
virtual void CreateViewWindow (wxWindow *parent)
 create Window corresponding to the view
virtual void DestroyViewWindow ()
 destroy Window corresponding to the view
IWMClient interface implementation
virtual wxWindow * GetWindow ()
 IWMClient interface implementation.
virtual wxEvtHandler * GetCommandHandler ()
 returns a pointer to the command handler (for menu commands and updates)
virtual string GetClientLabel (IWMClient::ELabel ltype=IWMClient::eDefault) const
 returns the client label (name) to be displayed in UI
virtual string GetIconAlias () const
 returns an icon alias that can be used to retrieve the client's icon
virtual const CRgbaColorGetColor () const
 returns a color associated with the client, n/a if NULL
virtual void SetColor (const CRgbaColor &aColor)
 returns a color associated with the client
virtual const wxMenu * GetMenu ()
 returns menu that can be merged with main menu of an application
virtual void UpdateMenu (wxMenu &aRootMenu)
virtual CFingerprint GetFingerprint () const
 returns a fingerprint identifying the client
IRegSettings interface implementation
virtual void SetRegistryPath (const string &reg_path)
 IRegSettings interface implementation.
virtual void LoadSettings ()
virtual void SaveSettings () const
IObserver interface implementation
virtual void OnUpdate (IObserverUpdate &update)
ISelectionClient interface implementation
virtual void GetSelection (TConstScopedObjects &objects) const
 shall return data objects representing selected things, return one data object for every selected thing.
virtual void SetSelectionService (ISelectionService *service)
virtual string GetSelClientLabel ()
 returns a string identifying the client in UI
virtual void GetSelection (CSelectionEvent &evt) const
 get selection for broadcasting
virtual void SetSelection (CSelectionEvent &evt)
 set broadcasted selection
virtual void GetMainObject (TConstScopedObjects &objects) const
 Adds the main data objects represented by the client to "objects".
virtual CRef< objects::CScope > GetScope () const
 if all selected elements belong to the same scope - return it, otherwise return NULL

Protected Attributes

CSelectionServicem_Service
bool m_Broadcasting
CSelectionPanelm_Panel
wxEvtHandler * m_Handler

Static Protected Attributes

static CViewTypeDescriptor m_TypeDescr

Private Member Functions

 CSelectionView (const CSelectionView &)
CSelectionViewoperator= (const CSelectionView &)

Friends

class CSelectionViewFactory


Constructor & Destructor Documentation

CSelectionView::CSelectionView  ) 
 

Definition at line 544 of file selection_view.cpp.

CSelectionView::~CSelectionView  )  [virtual]
 

Definition at line 552 of file selection_view.cpp.

References m_Handler, and SetWorkbench().

CSelectionView::CSelectionView const CSelectionView  )  [private]
 


Member Function Documentation

void CSelectionView::CreateViewWindow wxWindow *  parent  )  [virtual]
 

create Window corresponding to the view

Implements IView.

Definition at line 622 of file selection_view.cpp.

References CSelectionPanel::Create(), GetWindow(), m_Handler, m_Panel, and PushFrontEventHandler().

void CSelectionView::DestroyViewWindow  )  [virtual]
 

destroy Window corresponding to the view

Implements IView.

Definition at line 633 of file selection_view.cpp.

References CSelectionPanel::Destroy(), GetWindow(), m_Handler, m_Panel, and PopFrontEventHandler().

string CSelectionView::GetClientLabel IWMClient::ELabel  ltype = IWMClient::eDefault  )  const [virtual]
 

returns the client label (name) to be displayed in UI

Implements IWMClient.

Definition at line 654 of file selection_view.cpp.

References CUIObject::GetLabel(), and m_TypeDescr.

const CRgbaColor * CSelectionView::GetColor  )  const [virtual]
 

returns a color associated with the client, n/a if NULL

Implements IWMClient.

Definition at line 666 of file selection_view.cpp.

virtual wxEvtHandler* CSelectionView::GetCommandHandler  )  [inline, virtual]
 

returns a pointer to the command handler (for menu commands and updates)

Implements IWMClient.

Definition at line 181 of file selection_view.hpp.

References GetWindow().

IWMClient::CFingerprint CSelectionView::GetFingerprint  )  const [virtual]
 

returns a fingerprint identifying the client

Implements IWMClient.

Definition at line 689 of file selection_view.cpp.

References CUIObject::GetLabel(), and m_TypeDescr.

string CSelectionView::GetIconAlias  )  const [virtual]
 

returns an icon alias that can be used to retrieve the client's icon

Implements IWMClient.

Definition at line 660 of file selection_view.cpp.

References CUIObject::GetIconAlias(), and m_TypeDescr.

void CSelectionView::GetMainObject TConstScopedObjects objects  )  const [virtual]
 

Adds the main data objects represented by the client to "objects".

Implementation shall not clear the container as it can be used for accumulating objects.

Implements ISelectionClient.

Definition at line 757 of file selection_view.cpp.

const wxMenu * CSelectionView::GetMenu  )  [virtual]
 

returns menu that can be merged with main menu of an application

Implements IWMClient.

Definition at line 678 of file selection_view.cpp.

CRef< objects::CScope > CSelectionView::GetScope  )  const [virtual]
 

if all selected elements belong to the same scope - return it, otherwise return NULL

Implements ISelectionClient.

Definition at line 763 of file selection_view.cpp.

string CSelectionView::GetSelClientLabel  )  [virtual]
 

returns a string identifying the client in UI

Implements ISelectionClient.

Definition at line 728 of file selection_view.cpp.

void CSelectionView::GetSelection CSelectionEvent evt  )  const [virtual]
 

get selection for broadcasting

Implements ISelectionClient.

Definition at line 734 of file selection_view.cpp.

References CSelectionEvent::AddObjectSelection(), GetSelection(), and ITERATE.

void CSelectionView::GetSelection TConstScopedObjects objects  )  const [virtual]
 

shall return data objects representing selected things, return one data object for every selected thing.

Implementation shall not clear the container as it can be used for accumulating objects.

Implements ISelectionClient.

Definition at line 715 of file selection_view.cpp.

References CSelectionPanel::GetSelection(), and m_Panel.

Referenced by GetSelection().

const CViewTypeDescriptor & CSelectionView::GetTypeDescriptor  )  const [virtual]
 

IView interface implementation.

Implements IView.

Definition at line 597 of file selection_view.cpp.

References m_TypeDescr.

wxWindow * CSelectionView::GetWindow  )  [virtual]
 

IWMClient interface implementation.

Implements IWMClient.

Definition at line 648 of file selection_view.cpp.

References m_Panel.

Referenced by CreateViewWindow(), DestroyViewWindow(), and GetCommandHandler().

void CSelectionView::LoadSettings  )  [virtual]
 

Implements IRegSettings.

Definition at line 709 of file selection_view.cpp.

References CSelectionPanel::LoadSettings(), and m_Panel.

void CSelectionView::OnUpdate IObserverUpdate update  )  [virtual]
 

Implements IObserver.

Definition at line 558 of file selection_view.cpp.

References _ASSERT, CObserverUpdate::eAttached, CObserverUpdate::ePreDetach, CObserverUpdate::eStateChanged, CObserverUpdate::GetObservable(), CObserverUpdate::GetType(), m_Panel, m_Service, CSelectionPanel::OnSelServiceStateChange(), CSelectionPanel::SetSelectionService(), and CSelectionPanel::Update().

CSelectionView& CSelectionView::operator= const CSelectionView  )  [private]
 

void CSelectionView::SaveSettings  )  const [virtual]
 

Implements IRegSettings.

Definition at line 703 of file selection_view.cpp.

References m_Panel, and CSelectionPanel::SaveSettings().

void CSelectionView::SetColor const CRgbaColor aColor  )  [virtual]
 

returns a color associated with the client

Implements IWMClient.

Definition at line 672 of file selection_view.cpp.

void CSelectionView::SetRegistryPath const string &  reg_path  )  [virtual]
 

IRegSettings interface implementation.

Implements IRegSettings.

Definition at line 698 of file selection_view.cpp.

References m_Panel, and CSelectionPanel::SetRegistryPath().

void CSelectionView::SetSelection CSelectionEvent evt  )  [virtual]
 

set broadcasted selection

Implements ISelectionClient.

Definition at line 751 of file selection_view.cpp.

void CSelectionView::SetSelectionService ISelectionService service  )  [virtual]
 

Implements ISelectionClient.

Definition at line 721 of file selection_view.cpp.

References m_Service.

void CSelectionView::SetWorkbench IWorkbench workbench  )  [virtual]
 

connect / disconnect this view with / from Workbench

Implements IView.

Definition at line 603 of file selection_view.cpp.

References IObservable::DetachObserver(), IServiceLocator::GetServiceByType(), and m_Service.

Referenced by ~CSelectionView().

void CSelectionView::UpdateMenu wxMenu &  aRootMenu  )  [virtual]
 

Implements IWMClient.

Definition at line 684 of file selection_view.cpp.


Friends And Related Function Documentation

friend class CSelectionViewFactory [friend]
 

Definition at line 164 of file selection_view.hpp.


Member Data Documentation

bool CSelectionView::m_Broadcasting [protected]
 

Definition at line 222 of file selection_view.hpp.

wxEvtHandler* CSelectionView::m_Handler [protected]
 

Definition at line 225 of file selection_view.hpp.

Referenced by CreateViewWindow(), DestroyViewWindow(), and ~CSelectionView().

CSelectionPanel* CSelectionView::m_Panel [protected]
 

Definition at line 224 of file selection_view.hpp.

Referenced by CreateViewWindow(), DestroyViewWindow(), GetSelection(), GetWindow(), LoadSettings(), OnUpdate(), SaveSettings(), and SetRegistryPath().

CSelectionService* CSelectionView::m_Service [protected]
 

Definition at line 220 of file selection_view.hpp.

Referenced by OnUpdate(), SetSelectionService(), and SetWorkbench().

CViewTypeDescriptor CSelectionView::m_TypeDescr [static, protected]
 

Definition at line 219 of file selection_view.hpp.

Referenced by CSelectionViewFactory::CreateInstanceByFingerprint(), GetClientLabel(), GetFingerprint(), GetIconAlias(), GetTypeDescriptor(), and CSelectionViewFactory::GetViewTypeDescriptor().


The documentation for this class was generated from the following files:
Generated on Mon Dec 7 14:01:20 2009 for NCBI C++ ToolKit by  doxygen 1.4.6
Modified on Mon Dec 07 16:23:55 2009 by modify_doxy.py rev. 173732