newntui/discovermdi/src/dockablebrowser.cpp
//---------------------------------------------------------------------------------
// This function will calculate variable size of the dockable window.
// (This dimention can be changed by shifting a splitter)
//---------------------------------------------------------------------------------
This function will calculate variable size of the dockable window.
(This dimention can be changed by shifting a splitter)
This function will calculate variable size of the dockable window . ( This dimention can be changed by shifting a splitter )
void CDockableBrowser::CalculateVariableSize() {
CRect frameRect;
      if(!::IsWindow(*this)) return;
       GetParent()->GetWindowRect(&frameRect); 
	   switch(GetDockSide()) {
	       case DOCK_LEFT : m_sizeDefault.cy=frameRect.Height()+3;
			                break;
	       case DOCK_RIGHT: m_sizeDefault.cy=frameRect.Height()+3;
			                break;
	       case DOCK_TOP :  m_sizeDefault.cx=frameRect.Width()+3;						
			                break;
	       case DOCK_BOTTOM:m_sizeDefault.cx=frameRect.Width()+3;
			                break;
	   }
}
void CDockableBrowser :: CalculateVariableSize ( ) { CRect frameRect ; if ( ! :: IsWindow ( * this ) ) return ; GetParent ( ) -> GetWindowRect ( & frameRect ) ; switch ( GetDockSide ( ) ) { case DOCK_LEFT : m_sizeDefault . cy = frameRect . Height ( ) + 3 ; break ; case DOCK_RIGHT : m_sizeDefault . cy = frameRect . Height ( ) + 3 ; break ; case DOCK_TOP : m_sizeDefault . cx = frameRect . Width ( ) + 3 ; break ; case DOCK_BOTTOM : m_sizeDefault . cx = frameRect . Width ( ) + 3 ; break ; } }
This function will calculate variable size of the dockable window.
This function will calculate variable size of the dockable window .