Sourceforge.net - The VCF's Project Host
   The VCF Website Home   |   Online Discussion Forums   |   Sourceforge.net Project Page   

VCF::Win32Object Class Reference

#include <Win32Object.h>

Inheritance diagram for VCF::Win32Object:

VCF::ObjectWithEvents VCF::Object VCF::AbstractWin32Component VCF::Win32Button VCF::Win32ComboBox VCF::Win32Component VCF::Win32Edit VCF::Win32HTMLBrowser VCF::Win32ListBox VCF::Win32Listview VCF::Win32Toolbar VCF::Win32Tree VCF::Win32Window List of all members.

Public Types

typedef std::pair< DWORD,
DWORD > 
CreateParams

Public Member Functions

 Win32Object ()
virtual ~Win32Object ()
void registerWin32Class (const String &className, WNDPROC wndProc)
bool isRegistered ()
 Checks whether the class has been registered.
virtual CreateParams createParams ()
 called before the create window is called.
void init ()
 This is where the window is actually created.
virtual bool handleEventMessages (UINT message, WPARAM wParam, LPARAM lParam, LRESULT &wndProcResult, WNDPROC defaultWndProc=NULL)
 returns true if no further handling is required, otherwise returns false, which means the rest of the handling needs to be done by the default wnd proc.
HWND getHwnd ()
LRESULT defaultWndProcedure (UINT message, WPARAM wParam, LPARAM lParam)
void setCreated (const bool &creationComplete)
bool isCreated ()
void setPeerControl (Control *control)
ControlgetPeerControl ()
virtual bool acceptsWMCommandMessages ()
void subclassWindow ()

Static Public Member Functions

static void addRegisterWin32Class (const String &className)
static Win32ObjectgetWin32ObjectFromHWND (HWND hwnd)
static void registerWin32Object (Win32Object *wndObj)

Protected Member Functions

void destroyWindowHandle ()

Protected Attributes

WNDPROC wndProc_
 this actually contains the current window proc
WNDPROC defaultWndProc_
 this contains the window proc used for window subclassing or just performing the default behaviour.
HWND hwnd_
bool created_
ControlpeerControl_

Static Protected Attributes

static std::vector< StringregisteredWindowClasses_
static std::map< HWND, Win32Object * > windowMap_

Member Typedef Documentation

typedef std::pair<DWORD,DWORD> VCF::Win32Object::CreateParams
 


Constructor & Destructor Documentation

VCF::Win32Object::Win32Object  ) 
 

virtual VCF::Win32Object::~Win32Object  )  [virtual]
 


Member Function Documentation

virtual bool VCF::Win32Object::acceptsWMCommandMessages  )  [inline, virtual]
 

Reimplemented in VCF::Win32Edit, and VCF::Win32Toolbar.

static void VCF::Win32Object::addRegisterWin32Class const String className  )  [static]
 

virtual CreateParams VCF::Win32Object::createParams  )  [virtual]
 

called before the create window is called.

Overide this to change the style and style ex parameters. Returns a pair, the pair.first is the style parameter, the pair.second is the style ex paramater.

Reimplemented in VCF::Win32Button, VCF::Win32ComboBox, VCF::Win32Dialog, VCF::Win32Edit, VCF::Win32ListBox, VCF::Win32Listview, VCF::Win32PopupWindowPeer, VCF::Win32Toolbar, VCF::Win32Tree, VCF::Win32Window, and VCF::Win32HTMLBrowser.

LRESULT VCF::Win32Object::defaultWndProcedure UINT  message,
WPARAM  wParam,
LPARAM  lParam
 

void VCF::Win32Object::destroyWindowHandle  )  [protected]
 

HWND VCF::Win32Object::getHwnd  ) 
 

Control* VCF::Win32Object::getPeerControl  ) 
 

static Win32Object* VCF::Win32Object::getWin32ObjectFromHWND HWND  hwnd  )  [static]
 

virtual bool VCF::Win32Object::handleEventMessages UINT  message,
WPARAM  wParam,
LPARAM  lParam,
LRESULT &  wndProcResult,
WNDPROC  defaultWndProc = NULL
[virtual]
 

returns true if no further handling is required, otherwise returns false, which means the rest of the handling needs to be done by the default wnd proc.

Reimplemented in VCF::AbstractWin32Component, VCF::Win32Button, VCF::Win32Dialog, VCF::Win32Edit, VCF::Win32Listview, VCF::Win32PopupWindowPeer, VCF::Win32Toolbar, VCF::Win32Tree, VCF::Win32Window, and VCF::Win32HTMLBrowser.

void VCF::Win32Object::init  ) 
 

This is where the window is actually created.

Called from constructors

Reimplemented from VCF::Object.

Reimplemented in VCF::AbstractWin32Component, and VCF::Win32Tree.

bool VCF::Win32Object::isCreated  ) 
 

bool VCF::Win32Object::isRegistered  ) 
 

Checks whether the class has been registered.

Performs a std::find() using the registeredWindowClasses_ static list

void VCF::Win32Object::registerWin32Class const String className,
WNDPROC  wndProc
 

static void VCF::Win32Object::registerWin32Object Win32Object wndObj  )  [static]
 

void VCF::Win32Object::setCreated const bool &  creationComplete  ) 
 

void VCF::Win32Object::setPeerControl Control control  ) 
 

void VCF::Win32Object::subclassWindow  ) 
 


Member Data Documentation

bool VCF::Win32Object::created_ [protected]
 

WNDPROC VCF::Win32Object::defaultWndProc_ [protected]
 

this contains the window proc used for window subclassing or just performing the default behaviour.

By default it is set to point to DefWindowProc()

HWND VCF::Win32Object::hwnd_ [protected]
 

Control* VCF::Win32Object::peerControl_ [protected]
 

std::vector< String > VCF::Win32Object::registeredWindowClasses_ [static, protected]
 

std::map<HWND, Win32Object*> VCF::Win32Object::windowMap_ [static, protected]
 

WNDPROC VCF::Win32Object::wndProc_ [protected]
 

this actually contains the current window proc


The documentation for this class was generated from the following file:
   Comments or Suggestions?    License Information