| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/extensions/extensions_ui.h" | 5 #include "chrome/browser/extensions/extensions_ui.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/base64.h" | 9 #include "base/base64.h" |
| 10 #include "base/callback.h" | 10 #include "base/callback.h" |
| (...skipping 937 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 948 } else if (!extension->web_extent().ContainsURL(url)) { | 948 } else if (!extension->web_extent().ContainsURL(url)) { |
| 949 continue; | 949 continue; |
| 950 } | 950 } |
| 951 | 951 |
| 952 result->push_back(ExtensionPage(url, process->id(), host->routing_id(), | 952 result->push_back(ExtensionPage(url, process->id(), host->routing_id(), |
| 953 process->profile()->IsOffTheRecord())); | 953 process->profile()->IsOffTheRecord())); |
| 954 } | 954 } |
| 955 } | 955 } |
| 956 | 956 |
| 957 ExtensionsDOMHandler::~ExtensionsDOMHandler() { | 957 ExtensionsDOMHandler::~ExtensionsDOMHandler() { |
| 958 // There may be pending file dialogs, we need to tell them that we've gone |
| 959 // away so they don't try and call back to us. |
| 960 if (load_extension_dialog_.get()) |
| 961 load_extension_dialog_->ListenerDestroyed(); |
| 962 |
| 958 if (pack_job_.get()) | 963 if (pack_job_.get()) |
| 959 pack_job_->ClearClient(); | 964 pack_job_->ClearClient(); |
| 960 | 965 |
| 961 if (icon_loader_.get()) | 966 if (icon_loader_.get()) |
| 962 icon_loader_->Cancel(); | 967 icon_loader_->Cancel(); |
| 963 } | 968 } |
| 964 | 969 |
| 965 // ExtensionsDOMHandler, public: ----------------------------------------------- | 970 // ExtensionsDOMHandler, public: ----------------------------------------------- |
| 966 | 971 |
| 967 ExtensionsUI::ExtensionsUI(TabContents* contents) : WebUI(contents) { | 972 ExtensionsUI::ExtensionsUI(TabContents* contents) : WebUI(contents) { |
| (...skipping 13 matching lines...) Expand all Loading... |
| 981 // static | 986 // static |
| 982 RefCountedMemory* ExtensionsUI::GetFaviconResourceBytes() { | 987 RefCountedMemory* ExtensionsUI::GetFaviconResourceBytes() { |
| 983 return ResourceBundle::GetSharedInstance(). | 988 return ResourceBundle::GetSharedInstance(). |
| 984 LoadDataResourceBytes(IDR_PLUGIN); | 989 LoadDataResourceBytes(IDR_PLUGIN); |
| 985 } | 990 } |
| 986 | 991 |
| 987 // static | 992 // static |
| 988 void ExtensionsUI::RegisterUserPrefs(PrefService* prefs) { | 993 void ExtensionsUI::RegisterUserPrefs(PrefService* prefs) { |
| 989 prefs->RegisterBooleanPref(prefs::kExtensionsUIDeveloperMode, false); | 994 prefs->RegisterBooleanPref(prefs::kExtensionsUIDeveloperMode, false); |
| 990 } | 995 } |
| OLD | NEW |