'From Squeak3.0 of 4 February 2001 [latest update: #3522] on 17 February 2001 at 11:31:44 pm'! "Change Set: FasterAddPrefs-dew Date: 17 February 2001 Author: Doug Way Speeds up the adding of new preferences by a factor of about 25. At some point in 2.9alpha this became considerably slower than it was in 2.8, because Symbol>>hash is slower."! !Preferences class methodsFor: 'initialization' stamp: 'dew 2/17/2001 23:12'! initializeAddedPreferences "Initialize any preference not yet known to the prefs dictionary as per descriptions in the 'initial values' category, but don't change the setting of any existing preference. Also, compile accessor methods for retrieving any preference that lacks one" "Preferences initializeAddedPreferences" | sym selectors | selectors _ self class selectors. "(this can take some time)" self allPreferenceInitializationSpecs do: [:triplet | (selectors includes: (sym _ triplet first)) ifFalse: [self compileAccessMethodFor: sym]. (FlagDictionary includesKey: sym) ifFalse: [triplet second == #true ifTrue: [self enable: sym] ifFalse: [self disable: sym]]]. self resetCategoryInfo ! !