removed radiogroup functionality

This commit is contained in:
rods 1998-06-15 22:05:24 +00:00
Родитель 10ec006b41
Коммит 6f55477ed0
2 изменённых файлов: 1 добавлений и 52 удалений

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

@ -31,7 +31,6 @@
//-------------------------------------------------------------------------
nsRadioButton::nsRadioButton(nsISupports *aOuter) : nsWindow(aOuter)
{
fRadioGroup = NULL;
}
@ -66,7 +65,7 @@ nsresult nsRadioButton::QueryObject(const nsIID& aIID, void** aInstancePtr)
//-------------------------------------------------------------------------
//
// Sets the state of the nsRadioButton but it DOES notify its nsRadioGroup.
// Sets the state of the nsRadioButton
//
//-------------------------------------------------------------------------
void nsRadioButton::SetState(PRBool aState)
@ -74,20 +73,6 @@ void nsRadioButton::SetState(PRBool aState)
fState = aState;
::SendMessage(GetWindowHandle(), BM_SETCHECK, (WPARAM)(fState), 0L);
if (nsnull != fRadioGroup)
fRadioGroup->Clicked(this);
}
//-------------------------------------------------------------------------
//
// Sets the state of the nsRadioButton but it does not notify
// its nsRadioGroup.
//
//-------------------------------------------------------------------------
void nsRadioButton::SetStateNoNotify(PRBool aState)
{
fState = aState;
::SendMessage(GetWindowHandle(), BM_SETCHECK, (WPARAM)(fState), 0L);
}
//-------------------------------------------------------------------------
@ -100,36 +85,6 @@ PRBool nsRadioButton::GetState()
return fState;
}
//-------------------------------------------------------------------------
//
// Return the radio group this radio button belongs to
//
//-------------------------------------------------------------------------
nsIRadioGroup* nsRadioButton::GetRadioGroup()
{
if (fRadioGroup)
fRadioGroup->AddRef();
return fRadioGroup;
}
//-------------------------------------------------------------------------
//
// Set the radio button group
//
//-------------------------------------------------------------------------
void nsRadioButton::SetRadioGroup(nsIRadioGroup* aGroup)
{
if (aGroup)
aGroup->AddRef();
if (fRadioGroup)
NS_RELEASE(fRadioGroup);
fRadioGroup = aGroup;
fRadioGroup->Add(this);
}
//-------------------------------------------------------------------------
//
// Set this button label

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

@ -25,7 +25,6 @@
#include "nsString.h"
#include "nsIRadioButton.h"
#include "nsIRadioGroup.h"
/**
@ -57,15 +56,10 @@ public:
virtual PRBool OnResize(nsRect &aWindowRect);
virtual void SetState(PRBool aState);
virtual void SetStateNoNotify(PRBool aState);
virtual PRBool GetState();
virtual nsIRadioGroup* GetRadioGroup();
virtual void SetRadioGroup(nsIRadioGroup* aGroup);
protected:
PRBool fState;
nsIRadioGroup* fRadioGroup;
virtual LPCTSTR WindowClass();
virtual DWORD WindowStyle();