2001-09-28 20:14:13 +00:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
2012-05-21 11:12:37 +00:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
1999-01-22 18:14:23 +00:00
|
|
|
|
|
|
|
#ifndef nsIFormControlFrame_h___
|
|
|
|
#define nsIFormControlFrame_h___
|
|
|
|
|
2009-01-12 19:20:59 +00:00
|
|
|
#include "nsQueryFrame.h"
|
2001-11-02 07:40:01 +00:00
|
|
|
class nsAString;
|
1999-01-22 19:10:10 +00:00
|
|
|
class nsIContent;
|
2002-07-25 18:31:10 +00:00
|
|
|
class nsIAtom;
|
2005-12-12 23:53:06 +00:00
|
|
|
struct nsSize;
|
1999-01-22 18:14:23 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* nsIFormControlFrame is the common interface for frames of form controls. It
|
|
|
|
* provides a uniform way of creating widgets, resizing, and painting.
|
|
|
|
* @see nsLeafFrame and its base classes for more info
|
|
|
|
*/
|
2009-01-12 19:20:59 +00:00
|
|
|
class nsIFormControlFrame : public nsQueryFrame
|
|
|
|
{
|
1999-01-22 18:14:23 +00:00
|
|
|
public:
|
2009-09-12 16:49:24 +00:00
|
|
|
NS_DECL_QUERYFRAME_TARGET(nsIFormControlFrame)
|
1999-01-22 18:14:23 +00:00
|
|
|
|
fixed bugs #6303, #6753, #6756, #6759
Re-wrote nsComboboxFrame.
removed the obsolete nsHTMLAtoms: comboText,comoTextSelected,comTextSelectedFocus,dropDownVisible,
dropdownHidden, dropDownBtnOut, dropDownBtnPressed,
Added nsHTMLAtoms::combobox, nsLayoutAtoms::popupList
Renamed dropDownList to dropDownListPseudo
Added "arrow.gif" as to be used the background-image for the combobox button
ua.css - added rules for select to differentiate between comboboxes and listboxes.
Added style rules to more closely match the XPTOOLKIT XPWidgets look.
removed the following :-moz-combobox-text, -moz-combobox-textselected
nsIFormControlFrame.h - Added SetSuggestedSize method.
nsButtonControlFrame - Implemented SetSuggestedSize.
nsCSSFrameConstructor.cpp - Rewrote ConstructSelectFrame.
nsIWidget.h -Added GetAbsoluteBounds method.
nsWindow.cpp - Implemented GetAbsoluteBounds.
1999-07-14 22:00:24 +00:00
|
|
|
/**
|
2005-12-12 23:53:06 +00:00
|
|
|
*
|
|
|
|
* @param aOn
|
|
|
|
* @param aRepaint
|
fixed bugs #6303, #6753, #6756, #6759
Re-wrote nsComboboxFrame.
removed the obsolete nsHTMLAtoms: comboText,comoTextSelected,comTextSelectedFocus,dropDownVisible,
dropdownHidden, dropDownBtnOut, dropDownBtnPressed,
Added nsHTMLAtoms::combobox, nsLayoutAtoms::popupList
Renamed dropDownList to dropDownListPseudo
Added "arrow.gif" as to be used the background-image for the combobox button
ua.css - added rules for select to differentiate between comboboxes and listboxes.
Added style rules to more closely match the XPTOOLKIT XPWidgets look.
removed the following :-moz-combobox-text, -moz-combobox-textselected
nsIFormControlFrame.h - Added SetSuggestedSize method.
nsButtonControlFrame - Implemented SetSuggestedSize.
nsCSSFrameConstructor.cpp - Rewrote ConstructSelectFrame.
nsIWidget.h -Added GetAbsoluteBounds method.
nsWindow.cpp - Implemented GetAbsoluteBounds.
1999-07-14 22:00:24 +00:00
|
|
|
*/
|
2011-09-29 06:19:26 +00:00
|
|
|
virtual void SetFocus(bool aOn = true, bool aRepaint = false) = 0;
|
1999-01-22 19:10:10 +00:00
|
|
|
|
1999-01-25 22:16:27 +00:00
|
|
|
/**
|
1999-05-13 23:45:40 +00:00
|
|
|
* Set a property on the form control frame.
|
|
|
|
*
|
1999-01-25 22:16:27 +00:00
|
|
|
* @param aName name of the property to set
|
|
|
|
* @param aValue value of the property
|
|
|
|
* @returns NS_OK if the property name is valid, otherwise an error code
|
|
|
|
*/
|
2005-12-12 23:53:06 +00:00
|
|
|
virtual nsresult SetFormProperty(nsIAtom* aName, const nsAString& aValue) = 0;
|
1999-01-25 22:16:27 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Get a property from the form control frame
|
1999-05-13 23:45:40 +00:00
|
|
|
*
|
2005-12-12 23:53:06 +00:00
|
|
|
* @param aName name of the property to get.
|
|
|
|
* @param aValue Value to set.
|
|
|
|
* @returns NS_OK if the property name is valid, otherwise an error code.
|
2001-11-02 07:40:01 +00:00
|
|
|
*/
|
1999-03-06 19:43:13 +00:00
|
|
|
|
2005-12-12 23:53:06 +00:00
|
|
|
virtual nsresult GetFormProperty(nsIAtom* aName, nsAString& aValue) const = 0;
|
1999-01-22 18:14:23 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|