Changeset 432 for Common/URegistry.pas
- Timestamp:
- Oct 25, 2012, 2:11:47 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Common/URegistry.pas
r404 r432 26 26 TRegistryEx = class(TRegistry) 27 27 private 28 function GetContext: TRegistryContext; 29 procedure SetContext(AValue: TRegistryContext); 28 30 public 29 31 function ReadBoolWithDefault(const Name: string; … … 35 37 function DeleteKeyRecursive(const Key: string): Boolean; 36 38 function OpenKey(const Key: string; CanCreate: Boolean): Boolean; 39 property Context: TRegistryContext read GetContext write SetContext; 37 40 end; 38 41 … … 106 109 end; 107 110 111 function TRegistryEx.GetContext: TRegistryContext; 112 begin 113 Result.Key := CurrentPath; 114 Result.RootKey := RootKey; 115 end; 116 117 procedure TRegistryEx.SetContext(AValue: TRegistryContext); 118 begin 119 RootKey := AValue.RootKey; 120 OpenKey(AValue.Key, True); 121 end; 122 108 123 function TRegistryEx.ReadBoolWithDefault(const Name: string; 109 124 DefaultValue: Boolean): Boolean;
Note:
See TracChangeset
for help on using the changeset viewer.