summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authorshess@chromium.org <shess@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-12 17:38:17 +0000
committershess@chromium.org <shess@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-12 17:38:17 +0000
commit8d34b3d8fe1190d5400a1bea41d30838f20ee2ef (patch)
tree46f87b6751eeefacb1cb6e352498a8524fdf5e91 /chrome
parent0d0f0ac6478b619f8684ada49e8ef1b953bcefa2 (diff)
downloadchromium_src-8d34b3d8fe1190d5400a1bea41d30838f20ee2ef.zip
chromium_src-8d34b3d8fe1190d5400a1bea41d30838f20ee2ef.tar.gz
chromium_src-8d34b3d8fe1190d5400a1bea41d30838f20ee2ef.tar.bz2
Address Mike's last complaint about Issue 114017.
http://codereview.chromium.org/114017 Add comment about operation of PropertyAccessor<> instance. Review URL: http://codereview.chromium.org/113275 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15867 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/autocomplete/autocomplete_edit_view_mac.mm8
1 files changed, 5 insertions, 3 deletions
diff --git a/chrome/browser/autocomplete/autocomplete_edit_view_mac.mm b/chrome/browser/autocomplete/autocomplete_edit_view_mac.mm
index e1a2a53..d66c4cc 100644
--- a/chrome/browser/autocomplete/autocomplete_edit_view_mac.mm
+++ b/chrome/browser/autocomplete/autocomplete_edit_view_mac.mm
@@ -27,10 +27,12 @@ struct AutocompleteEditViewMacState {
};
// Returns a lazily initialized property bag accessor for saving our
-// state in a TabContents.
+// state in a TabContents. When constructed |accessor| generates a
+// globally-unique id used to index into the per-tab PropertyBag used
+// to store the state data.
PropertyAccessor<AutocompleteEditViewMacState>* GetStateAccessor() {
- static PropertyAccessor<AutocompleteEditViewMacState> state;
- return &state;
+ static PropertyAccessor<AutocompleteEditViewMacState> accessor;
+ return &accessor;
}
// Accessors for storing and getting the state from the tab.