Add support to encode selection informaton

git-svn-id: svn://10.0.0.236/trunk@24162 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
kostello%netscape.com 1999-03-15 05:10:03 +00:00
parent 212c5568d0
commit b795dfd74a
2 changed files with 19 additions and 3 deletions

View File

@ -64,6 +64,23 @@ nsXIFConverter::~nsXIFConverter()
}
void nsXIFConverter::SetSelection(nsIDOMSelection* aSelection) {
mSelection = aSelection;
BeginStartTag("encode");
if (mSelection == nsnull)
{
AddAttribute("selection","0");
}
else
{
AddAttribute("selection","1");
}
FinishStartTag("encode",PR_TRUE,PR_TRUE);
}
void nsXIFConverter::BeginStartTag(const nsString& aTag)
{

View File

@ -114,9 +114,8 @@ public:
// Output routines
void Write();
void SetSelection(nsIDOMSelection* aSelection) {
mSelection = aSelection;
}
void SetSelection(nsIDOMSelection* aSelection);
nsIDOMSelection* GetSelection() {
return mSelection;
}