| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/ui/screen_capture_notification_ui.h" | 5 #include "chrome/browser/ui/screen_capture_notification_ui.h" |
| 6 | 6 |
| 7 #include "ash/shell.h" | 7 #include "ash/shell.h" |
| 8 #include "chrome/app/chrome_dll_resource.h" | 8 #include "chrome/app/chrome_dll_resource.h" |
| 9 #include "chrome/browser/ui/views/chrome_views_export.h" | 9 #include "chrome/browser/ui/views/chrome_views_export.h" |
| 10 #include "grit/generated_resources.h" | 10 #include "grit/generated_resources.h" |
| (...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 234 return client_view_; | 234 return client_view_; |
| 235 } | 235 } |
| 236 | 236 |
| 237 views::NonClientFrameView* | 237 views::NonClientFrameView* |
| 238 ScreenCaptureNotificationUIViews::CreateNonClientFrameView( | 238 ScreenCaptureNotificationUIViews::CreateNonClientFrameView( |
| 239 views::Widget* widget) { | 239 views::Widget* widget) { |
| 240 views::BubbleFrameView* frame = new views::BubbleFrameView( | 240 views::BubbleFrameView* frame = new views::BubbleFrameView( |
| 241 gfx::Insets(kPadding, kPaddingLeft, kPadding, kPadding)); | 241 gfx::Insets(kPadding, kPaddingLeft, kPadding, kPadding)); |
| 242 SkColor color = widget->GetNativeTheme()->GetSystemColor( | 242 SkColor color = widget->GetNativeTheme()->GetSystemColor( |
| 243 ui::NativeTheme::kColorId_DialogBackground); | 243 ui::NativeTheme::kColorId_DialogBackground); |
| 244 views::BubbleBorder* border = new views::BubbleBorder( | 244 frame->SetBubbleBorder(scoped_ptr<views::BubbleBorder>( |
| 245 views::BubbleBorder::NONE, views::BubbleBorder::SMALL_SHADOW, color); | 245 new views::BubbleBorder(views::BubbleBorder::NONE, |
| 246 frame->SetBubbleBorder(border); | 246 views::BubbleBorder::SMALL_SHADOW, |
| 247 color))); |
| 247 return frame; | 248 return frame; |
| 248 } | 249 } |
| 249 | 250 |
| 250 base::string16 ScreenCaptureNotificationUIViews::GetWindowTitle() const { | 251 base::string16 ScreenCaptureNotificationUIViews::GetWindowTitle() const { |
| 251 return text_; | 252 return text_; |
| 252 } | 253 } |
| 253 | 254 |
| 254 bool ScreenCaptureNotificationUIViews::ShouldShowWindowTitle() const { | 255 bool ScreenCaptureNotificationUIViews::ShouldShowWindowTitle() const { |
| 255 return false; | 256 return false; |
| 256 } | 257 } |
| (...skipping 15 matching lines...) Expand all Loading... |
| 272 } | 273 } |
| 273 } | 274 } |
| 274 | 275 |
| 275 } // namespace | 276 } // namespace |
| 276 | 277 |
| 277 scoped_ptr<ScreenCaptureNotificationUI> ScreenCaptureNotificationUI::Create( | 278 scoped_ptr<ScreenCaptureNotificationUI> ScreenCaptureNotificationUI::Create( |
| 278 const base::string16& text) { | 279 const base::string16& text) { |
| 279 return scoped_ptr<ScreenCaptureNotificationUI>( | 280 return scoped_ptr<ScreenCaptureNotificationUI>( |
| 280 new ScreenCaptureNotificationUIViews(text)); | 281 new ScreenCaptureNotificationUIViews(text)); |
| 281 } | 282 } |
| OLD | NEW |