4 * Copyright (C) 2005-2013 Team XBMC
7 * This Program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2, or (at your option)
12 * This Program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with XBMC; see the file COPYING. If not, see
19 * <http://www.gnu.org/licenses/>.
23 #include "GUIDialogSettings.h"
24 #include "addons/Scraper.h"
25 #include "addons/AddonManager.h"
34 class CGUIDialogContentSettings : public CGUIDialogSettings
37 CGUIDialogContentSettings(void);
38 virtual ~CGUIDialogContentSettings(void);
39 virtual bool OnMessage(CGUIMessage& message);
41 static bool Show(ADDON::ScraperPtr& scraper, CONTENT_TYPE musicContext = CONTENT_NONE);
42 static bool Show(ADDON::ScraperPtr& scraper, VIDEO::SScanSettings& settings, CONTENT_TYPE musicContext = CONTENT_NONE);
43 static bool ShowForDirectory(const CStdString& strDirectory, ADDON::ScraperPtr& scraper, VIDEO::SScanSettings& settings);
44 virtual bool HasListItems() const { return true; };
45 virtual CFileItemPtr GetCurrentListItem(int offset = 0);
47 virtual void OnOkay();
48 virtual void OnCancel();
49 virtual void OnInitWindow();
50 virtual void SetupPage();
51 virtual void CreateSettings();
52 void FillContentTypes();
53 void FillContentTypes(const CONTENT_TYPE& content);
54 void AddContentType(const CONTENT_TYPE& content);
55 void FillListControl();
56 virtual void OnSettingChanged(SettingInfo& setting);
60 bool m_bShowScanSettings;
61 bool m_bScanRecursive;
66 std::map<CONTENT_TYPE, ADDON::VECADDONS> m_scrapers;
67 std::map<CONTENT_TYPE, ADDON::AddonPtr> m_lastSelected;
68 CFileItemList* m_vecItems;
70 CStdString m_strContentType;
71 ADDON::AddonPtr m_scraper;
72 CStdString m_defaultScraper;
73 CONTENT_TYPE m_content;
74 CONTENT_TYPE m_origContent;