Added SetProperty/GetProperty methods to nsIFormControlFrame. Added stub

implementations for all classes that derive from nsIFormControlFrame
This commit is contained in:
kmcclusk%netscape.com 1999-01-25 22:16:27 +00:00
Родитель 9d713b4c89
Коммит 3c7d93524c
32 изменённых файлов: 302 добавлений и 0 удалений

Просмотреть файл

@ -899,3 +899,14 @@ nsComboboxControlFrame::ListWasSelected(nsIPresContext* aPresContext)
return NS_OK;
}
NS_IMETHODIMP nsComboboxControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsComboboxControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -48,6 +48,7 @@ public:
NS_IMETHOD QueryInterface(const nsIID& aIID, void** aInstancePtr);
// nsIFrame
NS_IMETHOD SetInitialChildList(nsIPresContext& aPresContext,
nsIAtom* aListName,
nsIFrame* aChildList);
@ -77,6 +78,10 @@ public:
virtual PRBool GetNamesValues(PRInt32 aMaxNumValues, PRInt32& aNumValues,
nsString* aValues, nsString* aNames);
// nsIFormControLFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
//nsTextControlFrame* GetTextFrame() { return mTextFrame; }
//void SetTextFrame(nsTextControlFrame* aFrame) { mTextFrame = aFrame; }

Просмотреть файл

@ -352,3 +352,13 @@ nsFileControlFrame::GetHorizontalInsidePadding(nsIPresContext& aPresContext,
{
return 0;
}
NS_IMETHODIMP nsFileControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsFileControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -31,6 +31,10 @@ class nsFileControlFrame : public nsHTMLContainerFrame,
public:
nsFileControlFrame();
// nsIFormControlFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
NS_IMETHOD QueryInterface(const nsIID& aIID, void** aInstancePtr);
NS_IMETHOD Reflow(nsIPresContext& aCX,

Просмотреть файл

@ -758,6 +758,17 @@ nsresult nsFormControlFrame::SetCurrentCheckState(PRBool aState)
return res;
}
NS_IMETHODIMP nsFormControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsFormControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}
#if 0
>>>>>>> 1.41

Просмотреть файл

@ -193,6 +193,11 @@ protected:
virtual ~nsFormControlFrame();
// nsIFormControLFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
/**
* Get the size that this frame would occupy without any constraints
* @param aPresContext the presentation context

Просмотреть файл

@ -119,6 +119,10 @@ public:
void GetDefaultLabel(nsString& aLabel);
// nsIFormControlFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
protected:
NS_IMETHOD_(nsrefcnt) AddRef(void);
NS_IMETHOD_(nsrefcnt) Release(void);
@ -727,4 +731,15 @@ nsHTMLButtonControlFrame::GetHorizontalInsidePadding(nsIPresContext& aPresContex
return 0;
}
NS_IMETHODIMP nsHTMLButtonControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsHTMLButtonControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -77,6 +77,24 @@ public:
*/
NS_IMETHOD GetFormContent(nsIContent*& aContent) const = 0;
/**
* Set a property on the form control frame
* @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
*/
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue) = 0;
/**
* Get a property from the form control frame
* @param aName name of the property to get
* @param aValue value of the property
* @returns NS_OK if the property name is valid, otherwise an error code
*/
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue) = 0;
};
#endif

Просмотреть файл

@ -105,6 +105,9 @@ public:
float aPixToTwip,
nscoord aInnerWidth,
nscoord aCharWidth) const;
// nsIFormControlFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
protected:
void GetTranslatedRect(nsRect& aRect); // XXX this implementation is a copy of nsHTMLButtonControlFrame
@ -387,3 +390,13 @@ nsImageControlFrame::GetHorizontalInsidePadding(nsIPresContext& aPresContext,
{
return 0;
}
NS_IMETHODIMP nsImageControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsImageControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -1584,6 +1584,17 @@ nsListControlFrame::GetSelectedItem(nsString & aStr)
return NS_OK;
}
NS_IMETHODIMP nsListControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsListControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}
#if 0
//----------------------------------------------------------------------
NS_IMETHODIMP

Просмотреть файл

@ -123,6 +123,11 @@ public:
NS_IMETHOD Deselect();
// nsIFormControlFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
#if 0
virtual void GetStyleSize(nsIPresContext& aContext,
const nsHTMLReflowState& aReflowState,

Просмотреть файл

@ -719,3 +719,13 @@ nsTextControlFrame::Paint(nsIPresContext& aPresContext,
}
return NS_OK;
}
NS_IMETHODIMP nsTextControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsTextControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -26,6 +26,10 @@ class nsIPresContext;
class nsTextControlFrame : public nsFormControlFrame {
public:
// nsIFormControlFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
virtual nsWidgetInitData* GetWidgetInitData(nsIPresContext& aPresContext);
NS_IMETHOD AttributeChanged(nsIPresContext* aPresContext,

Просмотреть файл

@ -77,6 +77,24 @@ public:
*/
NS_IMETHOD GetFormContent(nsIContent*& aContent) const = 0;
/**
* Set a property on the form control frame
* @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
*/
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue) = 0;
/**
* Get a property from the form control frame
* @param aName name of the property to get
* @param aValue value of the property
* @returns NS_OK if the property name is valid, otherwise an error code
*/
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue) = 0;
};
#endif

Просмотреть файл

@ -402,3 +402,13 @@ nsButtonControlFrame::PaintButton(nsIPresContext& aPresContext,
}
NS_IMETHODIMP nsButtonControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsButtonControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -23,6 +23,10 @@
class nsButtonControlFrame : public nsFormControlFrame {
public:
// nsIFormControLFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
NS_IMETHOD Paint(nsIPresContext& aPresContext,
nsIRenderingContext& aRenderingContext,
const nsRect& aDirtyRect,

Просмотреть файл

@ -72,6 +72,10 @@ public:
virtual void Reset();
// nsIFormControLFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
//
// Methods used to GFX-render the checkbox
//
@ -359,6 +363,15 @@ NS_METHOD nsCheckboxControlFrame::HandleEvent(nsIPresContext& aPresContext,
return(nsFormControlFrame::HandleEvent(aPresContext, aEvent, aEventStatus));
}
NS_IMETHODIMP nsCheckboxControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsCheckboxControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -899,3 +899,14 @@ nsComboboxControlFrame::ListWasSelected(nsIPresContext* aPresContext)
return NS_OK;
}
NS_IMETHODIMP nsComboboxControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsComboboxControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -48,6 +48,7 @@ public:
NS_IMETHOD QueryInterface(const nsIID& aIID, void** aInstancePtr);
// nsIFrame
NS_IMETHOD SetInitialChildList(nsIPresContext& aPresContext,
nsIAtom* aListName,
nsIFrame* aChildList);
@ -77,6 +78,10 @@ public:
virtual PRBool GetNamesValues(PRInt32 aMaxNumValues, PRInt32& aNumValues,
nsString* aValues, nsString* aNames);
// nsIFormControLFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
//nsTextControlFrame* GetTextFrame() { return mTextFrame; }
//void SetTextFrame(nsTextControlFrame* aFrame) { mTextFrame = aFrame; }

Просмотреть файл

@ -352,3 +352,13 @@ nsFileControlFrame::GetHorizontalInsidePadding(nsIPresContext& aPresContext,
{
return 0;
}
NS_IMETHODIMP nsFileControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsFileControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -31,6 +31,10 @@ class nsFileControlFrame : public nsHTMLContainerFrame,
public:
nsFileControlFrame();
// nsIFormControlFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
NS_IMETHOD QueryInterface(const nsIID& aIID, void** aInstancePtr);
NS_IMETHOD Reflow(nsIPresContext& aCX,

Просмотреть файл

@ -758,6 +758,17 @@ nsresult nsFormControlFrame::SetCurrentCheckState(PRBool aState)
return res;
}
NS_IMETHODIMP nsFormControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsFormControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}
#if 0
>>>>>>> 1.41

Просмотреть файл

@ -193,6 +193,11 @@ protected:
virtual ~nsFormControlFrame();
// nsIFormControLFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
/**
* Get the size that this frame would occupy without any constraints
* @param aPresContext the presentation context

Просмотреть файл

@ -119,6 +119,10 @@ public:
void GetDefaultLabel(nsString& aLabel);
// nsIFormControlFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
protected:
NS_IMETHOD_(nsrefcnt) AddRef(void);
NS_IMETHOD_(nsrefcnt) Release(void);
@ -727,4 +731,15 @@ nsHTMLButtonControlFrame::GetHorizontalInsidePadding(nsIPresContext& aPresContex
return 0;
}
NS_IMETHODIMP nsHTMLButtonControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsHTMLButtonControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -105,6 +105,9 @@ public:
float aPixToTwip,
nscoord aInnerWidth,
nscoord aCharWidth) const;
// nsIFormControlFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
protected:
void GetTranslatedRect(nsRect& aRect); // XXX this implementation is a copy of nsHTMLButtonControlFrame
@ -387,3 +390,13 @@ nsImageControlFrame::GetHorizontalInsidePadding(nsIPresContext& aPresContext,
{
return 0;
}
NS_IMETHODIMP nsImageControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsImageControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -1584,6 +1584,17 @@ nsListControlFrame::GetSelectedItem(nsString & aStr)
return NS_OK;
}
NS_IMETHODIMP nsListControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsListControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}
#if 0
//----------------------------------------------------------------------
NS_IMETHODIMP

Просмотреть файл

@ -123,6 +123,11 @@ public:
NS_IMETHOD Deselect();
// nsIFormControlFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
#if 0
virtual void GetStyleSize(nsIPresContext& aContext,
const nsHTMLReflowState& aReflowState,

Просмотреть файл

@ -338,3 +338,14 @@ nsRadioControlFrame::Paint(nsIPresContext& aPresContext,
}
return NS_OK;
}
NS_IMETHODIMP nsRadioControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsRadioControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -29,6 +29,11 @@ class nsIAtom;
class nsRadioControlFrame : public nsFormControlFrame
{
public:
// nsIFormControlFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
virtual void PostCreateWidget(nsIPresContext* aPresContext,
nscoord& aWidth,
nscoord& aHeight);

Просмотреть файл

@ -117,6 +117,10 @@ public:
virtual void MouseClicked(nsIPresContext* aPresContext);
// nsIFormControLFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
protected:
PRUint32 mNumRows;
@ -1006,3 +1010,14 @@ nsSelectControlFrame::MouseClicked(nsIPresContext* aPresContext)
}
}
}
NS_IMETHODIMP nsSelectControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsSelectControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -719,3 +719,13 @@ nsTextControlFrame::Paint(nsIPresContext& aPresContext,
}
return NS_OK;
}
NS_IMETHODIMP nsTextControlFrame::SetProperty(nsIAtom* aName, const nsString& aValue)
{
return NS_OK;
}
NS_IMETHODIMP nsTextControlFrame::GetProperty(nsIAtom* aName, nsString& aValue)
{
return NS_OK;
}

Просмотреть файл

@ -26,6 +26,10 @@ class nsIPresContext;
class nsTextControlFrame : public nsFormControlFrame {
public:
// nsIFormControlFrame
NS_IMETHOD SetProperty(nsIAtom* aName, const nsString& aValue);
NS_IMETHOD GetProperty(nsIAtom* aName, nsString& aValue);
virtual nsWidgetInitData* GetWidgetInitData(nsIPresContext& aPresContext);
NS_IMETHOD AttributeChanged(nsIPresContext* aPresContext,