OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/gtk/options/content_exceptions_window_gtk.h" | 5 #include "chrome/browser/gtk/options/content_exceptions_window_gtk.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 | 8 |
9 #include "app/gfx/gtk_util.h" | 9 #include "app/gfx/gtk_util.h" |
10 #include "app/l10n_util.h" | 10 #include "app/l10n_util.h" |
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
236 case CONTENT_SETTINGS_TYPE_COOKIES: | 236 case CONTENT_SETTINGS_TYPE_COOKIES: |
237 return l10n_util::GetStringUTF8(IDS_COOKIE_EXCEPTION_TITLE); | 237 return l10n_util::GetStringUTF8(IDS_COOKIE_EXCEPTION_TITLE); |
238 case CONTENT_SETTINGS_TYPE_IMAGES: | 238 case CONTENT_SETTINGS_TYPE_IMAGES: |
239 return l10n_util::GetStringUTF8(IDS_IMAGES_EXCEPTION_TITLE); | 239 return l10n_util::GetStringUTF8(IDS_IMAGES_EXCEPTION_TITLE); |
240 case CONTENT_SETTINGS_TYPE_JAVASCRIPT: | 240 case CONTENT_SETTINGS_TYPE_JAVASCRIPT: |
241 return l10n_util::GetStringUTF8(IDS_JS_EXCEPTION_TITLE); | 241 return l10n_util::GetStringUTF8(IDS_JS_EXCEPTION_TITLE); |
242 case CONTENT_SETTINGS_TYPE_PLUGINS: | 242 case CONTENT_SETTINGS_TYPE_PLUGINS: |
243 return l10n_util::GetStringUTF8(IDS_PLUGINS_EXCEPTION_TITLE); | 243 return l10n_util::GetStringUTF8(IDS_PLUGINS_EXCEPTION_TITLE); |
244 case CONTENT_SETTINGS_TYPE_POPUPS: | 244 case CONTENT_SETTINGS_TYPE_POPUPS: |
245 return l10n_util::GetStringUTF8(IDS_POPUP_EXCEPTION_TITLE); | 245 return l10n_util::GetStringUTF8(IDS_POPUP_EXCEPTION_TITLE); |
| 246 case CONTENT_SETTINGS_TYPE_GEOLOCATION: |
| 247 return l10n_util::GetStringUTF8(IDS_GEOLOCATION_EXCEPTION_TITLE); |
246 default: | 248 default: |
247 NOTREACHED(); | 249 NOTREACHED(); |
248 } | 250 } |
249 return std::string(); | 251 return std::string(); |
250 } | 252 } |
251 | 253 |
252 // static | 254 // static |
253 void ContentExceptionsWindowGtk::OnWindowDestroy( | 255 void ContentExceptionsWindowGtk::OnWindowDestroy( |
254 GtkWidget* widget, | 256 GtkWidget* widget, |
255 ContentExceptionsWindowGtk* window) { | 257 ContentExceptionsWindowGtk* window) { |
256 instances[window->model_->content_type()] = NULL; | 258 instances[window->model_->content_type()] = NULL; |
257 MessageLoop::current()->DeleteSoon(FROM_HERE, window); | 259 MessageLoop::current()->DeleteSoon(FROM_HERE, window); |
258 } | 260 } |
259 | 261 |
260 // static | 262 // static |
261 void ContentExceptionsWindowGtk::OnSelectionChanged( | 263 void ContentExceptionsWindowGtk::OnSelectionChanged( |
262 GtkTreeSelection* selection, | 264 GtkTreeSelection* selection, |
263 ContentExceptionsWindowGtk* window) { | 265 ContentExceptionsWindowGtk* window) { |
264 window->UpdateButtonState(); | 266 window->UpdateButtonState(); |
265 } | 267 } |
OLD | NEW |