Added implementation for SetJSStatus and SetJSDefaultStatus. r=hyatt

This commit is contained in:
tbogard%aol.net 2000-02-14 06:15:35 +00:00
parent b1608c3a04
commit 17460e44b3
2 changed files with 19 additions and 4 deletions

View File

@ -192,14 +192,27 @@ NS_IMETHODIMP nsContentTreeOwner::GetNewWindow(PRInt32 aChromeFlags,
NS_IMETHODIMP nsContentTreeOwner::SetJSStatus(const PRUnichar* aStatus)
{
NS_ERROR("Haven't Implemented this yet");
return NS_ERROR_FAILURE;
nsAutoString status(aStatus);
if(!status.Length())
status = mDefaultStatus;
nsAutoString statusName("status");
NS_ENSURE_SUCCESS(mXULWindow->NotifyObservers(statusName.GetUnicode(),
status.GetUnicode()), NS_ERROR_FAILURE);
return NS_OK;
}
NS_IMETHODIMP nsContentTreeOwner::SetJSDefaultStatus(const PRUnichar* aStatus)
{
NS_ERROR("Haven't Implemented this yet");
return NS_ERROR_FAILURE;
mDefaultStatus = aStatus;
nsAutoString statusName("defaultStatus");
NS_ENSURE_SUCCESS(mXULWindow->NotifyObservers(statusName.GetUnicode(),
aStatus), NS_ERROR_FAILURE);
return NS_OK;
}
NS_IMETHODIMP nsContentTreeOwner::SetOverLink(const PRUnichar* aLink)

View File

@ -25,6 +25,7 @@
// Helper Classes
#include "nsCOMPtr.h"
#include "nsString.h"
// Interfaces Needed
#include "nsIBaseWindow.h"
@ -62,6 +63,7 @@ protected:
nsXULWindow* mXULWindow;
PRBool mPrimary;
PRUint32 mChromeMask;
nsString mDefaultStatus;
};
#endif /* nsContentTreeOwner_h__ */