diff options
author | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-16 02:39:47 +0000 |
---|---|---|
committer | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-16 02:39:47 +0000 |
commit | 9ecd399719439f11461912ee56a9d51763239a26 (patch) | |
tree | bc25739f4314c8bf56cf1319bf405522f4e09e14 /chrome/common/content_settings_helper.h | |
parent | 4c8442fb310087c71bc7a8c2233dee9ad8c9b072 (diff) | |
download | chromium_src-9ecd399719439f11461912ee56a9d51763239a26.zip chromium_src-9ecd399719439f11461912ee56a9d51763239a26.tar.gz chromium_src-9ecd399719439f11461912ee56a9d51763239a26.tar.bz2 |
Factor out OriginToString into a common function in chrome/common/.
With that, notifications doesn't depend on geolocation code anymore.
(NOTE: this was a TODO for bulach).
BUG=None
TEST=out/Debug/unit_tests --gtest_filter=ContentSettingsHelperTest.*
Signed-off-by: Thiago Farina <tfarina@chromium.org>
Review URL: http://codereview.chromium.org/2910005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@52597 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/content_settings_helper.h')
-rw-r--r-- | chrome/common/content_settings_helper.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/chrome/common/content_settings_helper.h b/chrome/common/content_settings_helper.h new file mode 100644 index 0000000..0aa2947 --- /dev/null +++ b/chrome/common/content_settings_helper.h @@ -0,0 +1,20 @@ +// Copyright (c) 2010 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef CHROME_COMMON_CONTENT_SETTINGS_HELPER_H_ +#define CHROME_COMMON_CONTENT_SETTINGS_HELPER_H_ + +#include <string> + +class GURL; + +namespace content_settings_helper { + +// Return simplified string representing origin. If origin is using http or +// the standard port, those parts are not included in the output. +std::wstring OriginToWString(const GURL& origin); + +} // namespace content_settings_helper + +#endif // CHROME_COMMON_CONTENT_SETTINGS_HELPER_H_ |