wxPlayerListCtrl

Displays all of the players in the PlayerDatabase in a list control.  Each player is displayed by name.  The list is sorted in alphabetical order.

Derived From

wxBaseListCtrl

Project

Cities3D

Include

PlayerListCtrl.h

Summary
Displays all of the players in the PlayerDatabase in a list control.
The wxPlayerListCtrl constructor.
Reads all the players from the PlayerDatabase and inserts the information into the list control.
The wxWidgets event table declaration.
Handles the mouse entering the list’s rectangle.

Public

Summary
The wxPlayerListCtrl constructor.

Constructors

wxPlayerListCtrl

wxPlayerListCtrl(wxWindow *parent, 
wxWindowID id, 
const wxPoint &pos = wxDefaultPosition,
const wxSize &size = wxDefaultSize)

The wxPlayerListCtrl constructor.  Creates the columns for the list control and then calls ImportPlayers to populate the control.

Parameters

parentThe parent window.
idThe message handling ID.  Should be a unique (to the parent window) ID, if the parent window wants to receive messages from the control.
posThe list control position in window coordinates.
sizeThe list control size.

Protected

Summary
Reads all the players from the PlayerDatabase and inserts the information into the list control.
The wxWidgets event table declaration.
Handles the mouse entering the list’s rectangle.

Functions

ImportPlayers

void ImportPlayers()

Reads all the players from the PlayerDatabase and inserts the information into the list control.

Variables

DECLARE_EVENT_TABLE

The wxWidgets event table declaration.

Event Message Handling

OnEnterWindow

void OnEnterWindow(wxMouseEvent &event)

Handles the mouse entering the list’s rectangle.  Sets the cursor to be an arrow.

Parameters

eventThe mouse event.
Still volatile.
wxPlayerListCtrl(wxWindow *parent, 
wxWindowID id, 
const wxPoint &pos = wxDefaultPosition,
const wxSize &size = wxDefaultSize)
The wxPlayerListCtrl constructor.
void ImportPlayers()
Reads all the players from the PlayerDatabase and inserts the information into the list control.
void OnEnterWindow(wxMouseEvent &event)
Handles the mouse entering the list’s rectangle.
A basic list control.
Cities3D is a cross-platform implementation of the board game Settlers of Catan with all expansions, including Seafarers, and Cities & Knights.