Made EnableParse() to return nsresult. Used to return PRBool

git-svn-id: svn://10.0.0.236/trunk@41356 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
harishd%netscape.com
1999-07-27 23:32:30 +00:00
parent e45e3dc6a4
commit aa418dc7e3
6 changed files with 10 additions and 12 deletions

View File

@@ -165,7 +165,7 @@ CLASS_EXPORT_HTMLPARS nsIParser : public nsISupports {
* until you wind up being emitted to the given contentsink (which may or may not
* be a proxy for the NGLayout content model).
******************************************************************************************/
virtual PRBool EnableParser(PRBool aState) = 0;
virtual nsresult EnableParser(PRBool aState) = 0;
virtual PRBool IsParserEnabled() = 0;
virtual nsresult Parse(nsIURI* aURL,nsIStreamObserver* aListener = nsnull,PRBool aEnableVerify=PR_FALSE, void* aKey=0,eParseMode aMode=eParseMode_autodetect) = 0;
virtual nsresult Parse(nsIInputStream& aStream, PRBool aEnableVerify=PR_FALSE, void* aKey=0,eParseMode aMode=eParseMode_autodetect) = 0;

View File

@@ -600,7 +600,7 @@ nsresult nsParser::Terminate(void){
* @param aState determines whether we parse/tokenize or just cache.
* @return current state
*/
PRBool nsParser::EnableParser(PRBool aState){
nsresult nsParser::EnableParser(PRBool aState){
nsIParser* me = nsnull;
// If the stream has already finished, there's a good chance
@@ -624,7 +624,7 @@ PRBool nsParser::EnableParser(PRBool aState){
// Release reference if we added one at the top of this routine
NS_IF_RELEASE(me);
return aState;
return result;
}
/**
@@ -899,8 +899,7 @@ nsresult nsParser::ResumeParse(nsIDTD* aDefaultDTD, PRBool aIsFinalChunk) {
// in) until the parser is enabled.
//PRUint32 b1=NS_ERROR_HTMLPARSER_BLOCK;
if(NS_ERROR_HTMLPARSER_BLOCK==result) {
EnableParser(PR_FALSE);
result=NS_OK;
result=EnableParser(PR_FALSE);
}
}//if
}//if

View File

@@ -205,7 +205,7 @@ friend class CTokenHandler;
* @param aState determines whether we parse/tokenize or just cache.
* @return current state
*/
virtual PRBool EnableParser(PRBool aState);
virtual nsresult EnableParser(PRBool aState);
virtual nsresult Terminate(void);
/**

View File

@@ -165,7 +165,7 @@ CLASS_EXPORT_HTMLPARS nsIParser : public nsISupports {
* until you wind up being emitted to the given contentsink (which may or may not
* be a proxy for the NGLayout content model).
******************************************************************************************/
virtual PRBool EnableParser(PRBool aState) = 0;
virtual nsresult EnableParser(PRBool aState) = 0;
virtual PRBool IsParserEnabled() = 0;
virtual nsresult Parse(nsIURI* aURL,nsIStreamObserver* aListener = nsnull,PRBool aEnableVerify=PR_FALSE, void* aKey=0,eParseMode aMode=eParseMode_autodetect) = 0;
virtual nsresult Parse(nsIInputStream& aStream, PRBool aEnableVerify=PR_FALSE, void* aKey=0,eParseMode aMode=eParseMode_autodetect) = 0;

View File

@@ -600,7 +600,7 @@ nsresult nsParser::Terminate(void){
* @param aState determines whether we parse/tokenize or just cache.
* @return current state
*/
PRBool nsParser::EnableParser(PRBool aState){
nsresult nsParser::EnableParser(PRBool aState){
nsIParser* me = nsnull;
// If the stream has already finished, there's a good chance
@@ -624,7 +624,7 @@ PRBool nsParser::EnableParser(PRBool aState){
// Release reference if we added one at the top of this routine
NS_IF_RELEASE(me);
return aState;
return result;
}
/**
@@ -899,8 +899,7 @@ nsresult nsParser::ResumeParse(nsIDTD* aDefaultDTD, PRBool aIsFinalChunk) {
// in) until the parser is enabled.
//PRUint32 b1=NS_ERROR_HTMLPARSER_BLOCK;
if(NS_ERROR_HTMLPARSER_BLOCK==result) {
EnableParser(PR_FALSE);
result=NS_OK;
result=EnableParser(PR_FALSE);
}
}//if
}//if

View File

@@ -205,7 +205,7 @@ friend class CTokenHandler;
* @param aState determines whether we parse/tokenize or just cache.
* @return current state
*/
virtual PRBool EnableParser(PRBool aState);
virtual nsresult EnableParser(PRBool aState);
virtual nsresult Terminate(void);
/**