| OLD | NEW |
| 1 /* | 1 /* |
| 2 Copyright (C) 2000 Harri Porten (porten@kde.org) | 2 Copyright (C) 2000 Harri Porten (porten@kde.org) |
| 3 Copyright (C) 2000 Daniel Molkentin (molkentin@kde.org) | 3 Copyright (C) 2000 Daniel Molkentin (molkentin@kde.org) |
| 4 Copyright (C) 2000 Stefan Schimanski (schimmi@kde.org) | 4 Copyright (C) 2000 Stefan Schimanski (schimmi@kde.org) |
| 5 Copyright (C) 2003, 2004, 2005, 2006, 2007 Apple Inc. All Rights Reserved. | 5 Copyright (C) 2003, 2004, 2005, 2006, 2007 Apple Inc. All Rights Reserved. |
| 6 Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 6 Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
| 7 | 7 |
| 8 This library is free software; you can redistribute it and/or | 8 This library is free software; you can redistribute it and/or |
| 9 modify it under the terms of the GNU Library General Public | 9 modify it under the terms of the GNU Library General Public |
| 10 License as published by the Free Software Foundation; either | 10 License as published by the Free Software Foundation; either |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 97 return 0; | 97 return 0; |
| 98 } | 98 } |
| 99 | 99 |
| 100 String PluginData::pluginNameForMimeType(const String& mimeType) const | 100 String PluginData::pluginNameForMimeType(const String& mimeType) const |
| 101 { | 101 { |
| 102 if (const PluginInfo* info = pluginInfoForMimeType(mimeType)) | 102 if (const PluginInfo* info = pluginInfoForMimeType(mimeType)) |
| 103 return info->name; | 103 return info->name; |
| 104 return String(); | 104 return String(); |
| 105 } | 105 } |
| 106 | 106 |
| 107 String PluginData::pluginFileForMimeType(const String& mimeType) const | |
| 108 { | |
| 109 if (const PluginInfo* info = pluginInfoForMimeType(mimeType)) | |
| 110 return info->file; | |
| 111 return String(); | |
| 112 } | |
| 113 | |
| 114 void PluginData::initPlugins(const Page*) | 107 void PluginData::initPlugins(const Page*) |
| 115 { | 108 { |
| 116 const Vector<PluginInfo>& plugins = pluginCache().plugins(); | 109 const Vector<PluginInfo>& plugins = pluginCache().plugins(); |
| 117 for (size_t i = 0; i < plugins.size(); ++i) | 110 for (size_t i = 0; i < plugins.size(); ++i) |
| 118 m_plugins.append(plugins[i]); | 111 m_plugins.append(plugins[i]); |
| 119 } | 112 } |
| 120 | 113 |
| 121 void PluginData::refresh() | 114 void PluginData::refresh() |
| 122 { | 115 { |
| 123 pluginCache().reset(true); | 116 pluginCache().reset(true); |
| (...skipping 10 matching lines...) Expand all Loading... |
| 134 for (size_t k = 0; k < extensions.size(); ++k) { | 127 for (size_t k = 0; k < extensions.size(); ++k) { |
| 135 if (extension == extensions[k]) | 128 if (extension == extensions[k]) |
| 136 return mime.type; | 129 return mime.type; |
| 137 } | 130 } |
| 138 } | 131 } |
| 139 } | 132 } |
| 140 return String(); | 133 return String(); |
| 141 } | 134 } |
| 142 | 135 |
| 143 } // namespace blink | 136 } // namespace blink |
| OLD | NEW |