summaryrefslogtreecommitdiffstats
path: root/xbmc/addons/settings/SettingUrlEncodedString.h
diff options
context:
space:
mode:
Diffstat (limited to 'xbmc/addons/settings/SettingUrlEncodedString.h')
-rw-r--r--xbmc/addons/settings/SettingUrlEncodedString.h33
1 files changed, 33 insertions, 0 deletions
diff --git a/xbmc/addons/settings/SettingUrlEncodedString.h b/xbmc/addons/settings/SettingUrlEncodedString.h
new file mode 100644
index 0000000..80bad4d
--- /dev/null
+++ b/xbmc/addons/settings/SettingUrlEncodedString.h
@@ -0,0 +1,33 @@
+/*
+ * Copyright (C) 2017-2018 Team Kodi
+ * This file is part of Kodi - https://kodi.tv
+ *
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ * See LICENSES/README.md for more information.
+ */
+
+#pragma once
+
+#include "settings/lib/Setting.h"
+
+class CSettingsManager;
+
+namespace ADDON
+{
+ class CSettingUrlEncodedString : public CSettingString
+ {
+ public:
+ CSettingUrlEncodedString(const std::string& id, CSettingsManager* settingsManager = nullptr);
+ CSettingUrlEncodedString(const std::string& id,
+ int label,
+ const std::string& value,
+ CSettingsManager* settingsManager = nullptr);
+ CSettingUrlEncodedString(const std::string &id, const CSettingUrlEncodedString &setting);
+ ~CSettingUrlEncodedString() override = default;
+
+ SettingPtr Clone(const std::string &id) const override { return std::make_shared<CSettingUrlEncodedString>(id, *this); }
+
+ std::string GetDecodedValue() const;
+ bool SetDecodedValue(const std::string& decodedValue);
+ };
+}