summaryrefslogtreecommitdiffstats
path: root/chrome/browser/plugin_exceptions_table_model.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/plugin_exceptions_table_model.cc')
-rw-r--r--chrome/browser/plugin_exceptions_table_model.cc17
1 files changed, 10 insertions, 7 deletions
diff --git a/chrome/browser/plugin_exceptions_table_model.cc b/chrome/browser/plugin_exceptions_table_model.cc
index 21ed547..5b2a2c1 100644
--- a/chrome/browser/plugin_exceptions_table_model.cc
+++ b/chrome/browser/plugin_exceptions_table_model.cc
@@ -102,6 +102,10 @@ std::wstring PluginExceptionsTableModel::GetText(int row, int column_id) {
return std::wstring();
}
+bool PluginExceptionsTableModel::HasGroups() {
+ return true;
+}
+
void PluginExceptionsTableModel::SetObserver(TableModelObserver* observer) {
observer_ = observer;
}
@@ -130,17 +134,16 @@ void PluginExceptionsTableModel::ClearSettings() {
}
void PluginExceptionsTableModel::GetPlugins(
- NPAPI::PluginList::PluginMap* plugins) {
- NPAPI::PluginList::Singleton()->GetPluginGroups(false, plugins);
+ std::vector<webkit::npapi::PluginGroup>* plugin_groups) {
+ webkit::npapi::PluginList::Singleton()->GetPluginGroups(false, plugin_groups);
}
void PluginExceptionsTableModel::LoadSettings() {
int group_id = 0;
- NPAPI::PluginList::PluginMap plugins;
+ std::vector<webkit::npapi::PluginGroup> plugins;
GetPlugins(&plugins);
- for (NPAPI::PluginList::PluginMap::iterator it = plugins.begin();
- it != plugins.end(); ++it) {
- std::string plugin = it->first;
+ for (size_t i = 0; i < plugins.size(); ++i) {
+ std::string plugin = plugins[i].identifier();
HostContentSettingsMap::SettingsForOneType settings;
map_->GetSettingsForOneType(CONTENT_SETTINGS_TYPE_PLUGINS,
plugin,
@@ -151,7 +154,7 @@ void PluginExceptionsTableModel::LoadSettings() {
plugin,
&otr_settings);
}
- std::wstring title = UTF16ToWide(it->second->GetGroupName());
+ std::wstring title = UTF16ToWide(plugins[i].GetGroupName());
for (HostContentSettingsMap::SettingsForOneType::iterator setting_it =
settings.begin(); setting_it != settings.end(); ++setting_it) {
SettingsEntry entry = {