Ignore:
Timestamp:
Jul 10, 2003, 2:18:25 PM (22 years ago)
Author:
mjs
Message:

JavaScriptCore:

Reviewed by Darin.

The crux of this was saving and restoring the prototype objects
for all the standard types when saving and restoring for the page
cache.

  • kjs/internal.cpp: (InterpreterImp::saveBuiltins): (InterpreterImp::restoreBuiltins):
  • kjs/internal.h:
  • kjs/interpreter.cpp: (Interpreter::saveBuiltins): (Interpreter::restoreBuiltins): (SavedBuiltins::SavedBuiltins): (SavedBuiltins::~SavedBuiltins):
  • kjs/interpreter.h:
  • kjs/property_map.cpp:

WebCore:

Reviewed by Darin.

  • kwq/KWQKHTMLPart.h:
  • kwq/KWQKHTMLPart.mm: (KWQKHTMLPart::saveLocationProperties): Save the location object's properties, not the window's (!) (KWQKHTMLPart::saveInterpreterBuiltins): New function to save builtin properties of the interpeter. (KWQKHTMLPart::restoreInterpreterBuiltins): Similarly to restore them. (KWQKHTMLPart::openURLFromPageCache): Restore interpreter builtins too.
  • kwq/KWQPageState.h:
  • kwq/KWQPageState.mm: (-[KWQPageState initWithDocument:URL:windowProperties:locationProperties:interpreterBuiltins:]): Handle interpreter builtins. (-[KWQPageState invalidate]): Likewise. (-[KWQPageState dealloc]): Likewise. (-[KWQPageState interpreterBuiltins]): New method.
  • kwq/WebCoreBridge.mm: (-[WebCoreBridge saveDocumentToPageCache]): Handle interpeter builtins.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/kjs/interpreter.h

    r4363 r4612  
    107107  };
    108108
     109  class SavedBuiltinsInternal;
     110
     111  class SavedBuiltins {
     112    friend class InterpreterImp;
     113  public:
     114    SavedBuiltins();
     115    ~SavedBuiltins();
     116  private:
     117    SavedBuiltinsInternal *_internal;
     118  };
     119
    109120  /**
    110121   * Interpreter objects can be used to evaluate ECMAScript code. Each
     
    345356#endif
    346357
     358    void saveBuiltins (SavedBuiltins &) const;
     359    void restoreBuiltins (const SavedBuiltins &);
     360   
    347361  private:
    348362    InterpreterImp *rep;
Note: See TracChangeset for help on using the changeset viewer.