Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(72)

Side by Side Diff: chrome/browser/extensions/extension_uninstall_dialog.cc

Issue 711343003: [Merge] Cancel uninstall if the uninstall dialog's parent window is destroyed prior to the uninstal… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2171
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/extension_uninstall_dialog.h" 5 #include "chrome/browser/extensions/extension_uninstall_dialog.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 21 matching lines...) Expand all
32 const gfx::ImageSkia& image = 32 const gfx::ImageSkia& image =
33 is_app ? util::GetDefaultAppIcon() : util::GetDefaultExtensionIcon(); 33 is_app ? util::GetDefaultAppIcon() : util::GetDefaultExtensionIcon();
34 return image.GetRepresentation( 34 return image.GetRepresentation(
35 gfx::ImageSkia::GetMaxSupportedScale()).sk_bitmap(); 35 gfx::ImageSkia::GetMaxSupportedScale()).sk_bitmap();
36 } 36 }
37 37
38 } // namespace 38 } // namespace
39 39
40 ExtensionUninstallDialog::ExtensionUninstallDialog( 40 ExtensionUninstallDialog::ExtensionUninstallDialog(
41 Profile* profile, 41 Profile* profile,
42 gfx::NativeWindow parent,
43 ExtensionUninstallDialog::Delegate* delegate) 42 ExtensionUninstallDialog::Delegate* delegate)
44 : profile_(profile), 43 : profile_(profile),
45 parent_(parent),
46 delegate_(delegate), 44 delegate_(delegate),
47 extension_(NULL), 45 extension_(NULL),
48 triggering_extension_(NULL), 46 triggering_extension_(NULL),
49 ui_loop_(base::MessageLoop::current()) { 47 ui_loop_(base::MessageLoop::current()) {
50 } 48 }
51 49
52 ExtensionUninstallDialog::~ExtensionUninstallDialog() { 50 ExtensionUninstallDialog::~ExtensionUninstallDialog() {
53 } 51 }
54 52
55 void ExtensionUninstallDialog::ConfirmProgrammaticUninstall( 53 void ExtensionUninstallDialog::ConfirmProgrammaticUninstall(
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 return l10n_util::GetStringFUTF8( 117 return l10n_util::GetStringFUTF8(
120 IDS_EXTENSION_PROGRAMMATIC_UNINSTALL_PROMPT_HEADING, 118 IDS_EXTENSION_PROGRAMMATIC_UNINSTALL_PROMPT_HEADING,
121 base::UTF8ToUTF16(triggering_extension_->name()), 119 base::UTF8ToUTF16(triggering_extension_->name()),
122 base::UTF8ToUTF16(extension_->name())); 120 base::UTF8ToUTF16(extension_->name()));
123 } 121 }
124 return l10n_util::GetStringFUTF8(IDS_EXTENSION_UNINSTALL_PROMPT_HEADING, 122 return l10n_util::GetStringFUTF8(IDS_EXTENSION_UNINSTALL_PROMPT_HEADING,
125 base::UTF8ToUTF16(extension_->name())); 123 base::UTF8ToUTF16(extension_->name()));
126 } 124 }
127 125
128 } // namespace extensions 126 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698