From 75419991319fbf48b09ace859b7e2553641b8517 Mon Sep 17 00:00:00 2001 From: "radha%netscape.com" Date: Thu, 18 Aug 2005 11:15:27 +0000 Subject: [PATCH] Initial checkin for history listener interface bug 65608 r=valeski sr=rpotts git-svn-id: svn://10.0.0.236/trunk@178049 18797224-902f-48f8-a5cc-f745e15eee43 --- .../shistory/public/nsISHistoryListener.idl | 72 +++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 mozilla/docshell/shistory/public/nsISHistoryListener.idl diff --git a/mozilla/docshell/shistory/public/nsISHistoryListener.idl b/mozilla/docshell/shistory/public/nsISHistoryListener.idl new file mode 100644 index 00000000000..2d65644d81e --- /dev/null +++ b/mozilla/docshell/shistory/public/nsISHistoryListener.idl @@ -0,0 +1,72 @@ +/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- + * + * The contents of this file are subject to the Mozilla Public + * License Version 1.1 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.mozilla.org/MPL/ + * + * Software distributed under the License is distributed on an "AS + * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or + * implied. See the License for the specific language governing + * rights and limitations under the License. + * + * The Original Code is the Mozilla browser. + * + * The Initial Developer of the Original Code is Netscape + * Communications, Inc. Portions created by Netscape are + * Copyright (C) 1999, Mozilla. All Rights Reserved. + * + * Contributor(s): + * Radha Kulkarni */ + +#include "nsISupports.idl" + +interface nsIURI; + + +/** + * nsISHistoryListener defines an interface for an object to receive + * notifications about activities in History. A History listener will be + * notified about page additions,back,forward,goto traversals thro' + * Session history + */ +%{C++ +#define NS_SHISTORYLISTENER_CONTRACTID "@mozilla.org/browser/shistorylistener;1" +%} + +// interface nsISHistoryListener + +[scriptable, uuid(3b07f591-e8e1-11d4-9882-00c04fa02f40)] +interface nsISHistoryListener : nsISupports +{ + + /** + * Notify when a new page is added to History + */ + void OnHistoryNewEntry(in nsIURI aNewURI); + + /** + * Notification for going back with an option to cancel the operation + */ + boolean OnHistoryGoBack(in nsIURI aBackURI); + + /** + * Notification for going forward with an option to cancel the operation + */ + boolean OnHistoryGoForward(in nsIURI aForwardURI); + + /** + * Notification for Reload with an option to cancel + */ + boolean OnHistoryReload(in nsIURI aReloadURI, in unsigned long aReloadFlags); + + /** + * Notify while going to an particular index with an option to cancel + */ + boolean OnHistoryGotoIndex(in long aIndex, in nsIURI aGotoURI); + + /** + * Notify when History is about to be trimmed with an option to cancel + */ + boolean OnHistoryPurge(in long aNumEntries); +}; \ No newline at end of file