gecko-dev/cmd/winfe/fmselone.h

86 lines
2.7 KiB
C
Raw Normal View History

1998-03-28 02:44:41 +00:00
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public License
* Version 1.0 (the "NPL"); you may not use this file except in
* compliance with the NPL. You may obtain a copy of the NPL at
* http://www.mozilla.org/NPL/
*
* Software distributed under the NPL is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
* for the specific language governing rights and limitations under the
* NPL.
*
* The Initial Developer of this code under the NPL is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
* Reserved.
*/
#ifndef __FORM_SELECT_ONE_H
#define __FORM_SELECT_ONE_H
// This file is dedicated to form type select one elements
// otherwise known as combo boxes on windows and
// their implementation as requried by the XP layout
// library.
#include "fmabstra.h"
class CFormSelectOne : public CFormElement {
// Construction/destruction.
// Do not construct directly, use GetFormElement instead.
protected:
CFormSelectOne();
virtual ~CFormSelectOne();
friend CFormElement;
// The form element we represent.
// This can be called at various times, so always update
// our information when this function is called
// (refresh cached or calculated XP data).
protected:
virtual void SetElement(LO_FormElementStruct *pFormElement);
// This is called to inform us of the owning context.
// Once set, we should query it to decide how we will represent our
// selves (printing through a DC, existing as a window, etc).
protected:
virtual void SetContext(CAbstractCX *pCX);
// Actions that we've been told to take.
public:
virtual void DisplayFormElement(LTRB& Rect);
protected:
// Destroy the widget (window) implemenation of the form.
virtual void DestroyWidget();
// Create the widget (window) implementation of the form
// but DO NOT DISPLAY.
virtual void CreateWidget();
// Copy the current data out of the layout struct into the form
// widget, or mark that you should represent using the current data.
virtual void UseCurrentData();
// Copy the default data out of the layout struct into the form
// widget, or mark that you should represent using the default data.
virtual void UseDefaultData();
// Fill in the layout size information in the layout struct regarding
// the dimensions of the widget.
virtual void FillSizeInfo();
// Copy the current data out of the form element back into the
// layout struct.
1998-10-14 20:24:50 +00:00
virtual void UpdateCurrentData(BOOL bSubmit);
1998-03-28 02:44:41 +00:00
public:
virtual HWND GetRaw();
// Our widget representation.
private:
CMochaComboBox *m_pWidget;
};
#endif // __FORM_SELECT_ONE_H