WebKit:
[WebKit-https.git] / WebKit / WebView.subproj / WebPreferences.m
index 5d7d50ab8f5ea25d4a9991a446feda1a887e53bd..249903a551eaa1b19a74a0eeaae4feb01578f12e 100644 (file)
@@ -46,6 +46,7 @@
 #define WebKitObjectCacheSizePreferenceKey @"WebKitObjectCacheSizePreferenceKey"
 #define WebKitBackForwardCacheExpirationIntervalKey @"WebKitBackForwardCacheExpirationIntervalKey"
 #define WebKitTabToLinksPreferenceKey @"WebKitTabToLinksPreferenceKey"
+#define WebKitHistoryIsFrozenPreferenceKey @"WebKitHistoryIsFrozen"
 
 NSString *WebPreferencesChangedNotification = @"WebPreferencesChangedNotification";
 
@@ -234,6 +235,7 @@ NS_ENDHANDLER
         [NSNumber numberWithBool:YES],  WebKitDisplayImagesKey,
         @"1800",                        WebKitBackForwardCacheExpirationIntervalKey,
         [NSNumber numberWithBool:NO],   WebKitTabToLinksPreferenceKey,
+        [NSNumber numberWithBool:NO],   WebKitHistoryIsFrozenPreferenceKey,
         nil];
 
     [[NSUserDefaults standardUserDefaults] registerDefaults:dict];
@@ -608,6 +610,16 @@ NS_ENDHANDLER
     return [[NSUserDefaults standardUserDefaults] boolForKey:WebKitTabToLinksPreferenceKey];
 }
 
+- (void)setHistoryIsFrozen:(BOOL)flag
+{
+    [self _setBoolValue:flag forKey:WebKitHistoryIsFrozenPreferenceKey];
+}
+
+- (BOOL)historyIsFrozen
+{
+    return [[NSUserDefaults standardUserDefaults] boolForKey:WebKitHistoryIsFrozenPreferenceKey];
+}
+
 static NSMutableDictionary *webPreferencesInstances = nil;
 
 + (WebPreferences *)_getInstanceForIdentifier:(NSString *)ident