smjg.libs.sdwf.framewindow.FrameWindow Class Reference

The smjg.libs.sdwf.framewindow.FrameWindow class represents a window that frames another window or control. More...

Inheritance diagram for smjg.libs.sdwf.framewindow.FrameWindow:

smjg.libs.sdwf.window.Window smjg.libs.sdwf.windowbase.WindowBase smjg.libs.sdwf.mdi.ChildFrameWindow smjg.libs.sdwf.mdi.MDIFrameWindow

List of all members.

Public Member Functions

 this (string windowTitle, WindowBase p)
 Constructs a new FrameWindow owned by another window.
 this (string windowTitle, Application p)
 Constructs a new FrameWindow as a top-level application window.
void addBar (Bar b)
 Adds the given bar to this window.
Properties
WindowBase client ()
 The window object that serves as the client pane of this window.
WindowBase client (WindowBase c)
 The window object that serves as the client pane of this window.

Protected Member Functions

override void onDeactivate (ActivationEvent event)
 Calls client.onDeactivate to carry out operations when the window is made inactive.
override void initListeners ()
int frameWindowPredef (uint message, uint wParam, int lParam, WindowBase receivedVia, out bool swallow)
override void defaultCommandHandler (uint notify, uint id)
Callback Methods
override void setup ()
 Displays the client pane.
override void setWindowScale ()
 Adjusts the size of the client pane to fill the frame, and makes sure all bars are correctly positioned.
override bool confirmClose ()
 Calls client.confirmClose to determine whether the window can be closed.
override void onActivate (ActivationEvent event)
 Calls client.onActivate to carry out operations when the window is made active.

Protected Attributes

WindowBase _client
Bar[] _bars


Detailed Description

The smjg.libs.sdwf.framewindow.FrameWindow class represents a window that frames another window or control.

This enables the frame and client pane of a window to be handled as separate entities. It is also possible to use certain control classes (Control, EditBox, ListBox, TreeView) as client panes.

Unhandled messages received by the frame are forwarded to the client. This means that anything that can be done by deriving a class from Window can equally be done if a FrameWindow is used, without having to derive a class from FrameWindow.

Since 0.58, FrameWindow also enables a status bar to be added to a window, such that it will automatically be resized and repositioned when the window is resized, and the client pane is also automatically sized to fill the remaining space.

Since:
0.4

Constructor & Destructor Documentation

smjg.libs.sdwf.framewindow.FrameWindow.this ( string  windowTitle,
WindowBase  p 
)

Constructs a new FrameWindow owned by another window.

The Windows interface element itself is not yet created - this is done when show is called.

Parameters:
windowTitle the title bar text of the window.
p the parent window.
Status:
test

Reimplemented from smjg.libs.sdwf.window.Window.

Reimplemented in smjg.libs.sdwf.mdi.MDIFrameWindow.

smjg.libs.sdwf.framewindow.FrameWindow.this ( string  windowTitle,
Application  p 
)

Constructs a new FrameWindow as a top-level application window.

The Windows interface element itself is not yet created - this is done when show is called.

Parameters:
windowTitle the title bar text of the window.
p the application to which this window belongs.
Status:
done

Reimplemented from smjg.libs.sdwf.window.Window.

Reimplemented in smjg.libs.sdwf.mdi.MDIFrameWindow.


Member Function Documentation

void smjg.libs.sdwf.framewindow.FrameWindow.addBar ( Bar  b  ) 

Adds the given bar to this window.

Note:
If this FrameWindow has the WS_EX.CLIENTEDGE style, it will be removed and then, if client has already been set, the WS_EX.CLIENTEDGE style will be added to it.
Since:
0.58
Status:
done

WindowBase smjg.libs.sdwf.framewindow.FrameWindow.client (  ) 

The window object that serves as the client pane of this window.

Reimplemented in smjg.libs.sdwf.mdi.MDIFrameWindow.

WindowBase smjg.libs.sdwf.framewindow.FrameWindow.client ( WindowBase  c  ) 

The window object that serves as the client pane of this window.

This property must be set before calling FrameWindow.show.

Setting this property has the side effect of removing all border attributes from c.

Precondition:
It is illegal to set client more than once.
Status:
done

override void smjg.libs.sdwf.framewindow.FrameWindow.setup (  )  [protected]

Displays the client pane.

A subclass that overrides this method should include a call to super.setup().

Status:
done

Reimplemented from smjg.libs.sdwf.windowbase.WindowBase.

override void smjg.libs.sdwf.framewindow.FrameWindow.setWindowScale (  )  [protected]

Adjusts the size of the client pane to fill the frame, and makes sure all bars are correctly positioned.

A subclass that overrides this method should include a call to super.setWindowScale().

Status:
done

Reimplemented from smjg.libs.sdwf.window.Window.

override bool smjg.libs.sdwf.framewindow.FrameWindow.confirmClose (  )  [protected]

Calls client.confirmClose to determine whether the window can be closed.

A subclass that overrides this method should generally not return true unless a call to super.confirmClose() returns true.

Status:
done

Reimplemented from smjg.libs.sdwf.windowbase.WindowBase.

override void smjg.libs.sdwf.framewindow.FrameWindow.onActivate ( ActivationEvent  event  )  [protected]

Calls client.onActivate to carry out operations when the window is made active.

Since:
0.58

Reimplemented from smjg.libs.sdwf.windowbase.WindowBase.

override void smjg.libs.sdwf.framewindow.FrameWindow.onDeactivate ( ActivationEvent  event  )  [protected]

Calls client.onDeactivate to carry out operations when the window is made inactive.

Since:
0.58

Reimplemented from smjg.libs.sdwf.windowbase.WindowBase.

override void smjg.libs.sdwf.framewindow.FrameWindow.initListeners (  )  [protected, virtual]

Reimplemented from smjg.libs.sdwf.window.Window.

Reimplemented in smjg.libs.sdwf.mdi.MDIFrameWindow.

int smjg.libs.sdwf.framewindow.FrameWindow.frameWindowPredef ( uint  message,
uint  wParam,
int  lParam,
WindowBase  receivedVia,
out bool  swallow 
) [protected]

override void smjg.libs.sdwf.framewindow.FrameWindow.defaultCommandHandler ( uint  notify,
uint  id 
) [protected]

Reimplemented from smjg.libs.sdwf.windowbase.WindowBase.

Reimplemented in smjg.libs.sdwf.mdi.MDIFrameWindow.


Member Data Documentation

WindowBase smjg.libs.sdwf.framewindow.FrameWindow._client [protected]

Bar [] smjg.libs.sdwf.framewindow.FrameWindow._bars [protected]


The documentation for this class was generated from the following file:
Generated on Sun Jan 11 21:54:12 2009 for Stewart's D Windows Framework by  doxygen 1.5.4