Back to index

lightning-sunbird  0.9+nobinonly
nsIStatefulFrame.h
Go to the documentation of this file.
00001 #ifndef _nsIStatefulFrame_h
00002 #define _nsIStatefulFrame_h
00003 
00004 #include "nsISupports.h"
00005 
00006 class nsPresContext;
00007 class nsPresState;
00008 
00009 #define NS_ISTATEFULFRAME_IID \
00010 {0x26254ab7, 0xdea3, 0x4375, \
00011 {0xb0, 0x1d, 0xbd, 0x11, 0xa1, 0x4b, 0x54, 0xbc}}
00012 
00013 class nsIStatefulFrame : public nsISupports {
00014  public: 
00015   NS_DEFINE_STATIC_IID_ACCESSOR(NS_ISTATEFULFRAME_IID)
00016 
00017   // If you create a special type stateful frame (e.g. scroll) that needs
00018   // to be captured outside of the standard pass through the frames, you'll need
00019   // a special ID by which to refer to that type.
00020   //
00021   // There is space reserved between standard ID's and special ID's by the
00022   // offset NS_CONTENT_ID_COUNTER_BASE
00023   enum SpecialStateID {eNoID=0, eDocumentScrollState};
00024 
00025   NS_IMETHOD SaveState(nsPresContext* aPresContext, nsPresState** aState) = 0;
00026   NS_IMETHOD RestoreState(nsPresContext* aPresContext, nsPresState* aState) = 0;
00027 };
00028 
00029 #endif /* _nsIStatefulFrame_h */