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

Side by Side Diff: chrome/browser/ui/views/screen_capture_notification_ui_views.cc

Issue 145033006: views: Make View::set_border() take a scoped_ptr<>. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase to ToT Created 6 years, 11 months 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 | Annotate | Revision Log
OLDNEW
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
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
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 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/profile_reset_bubble_view.cc ('k') | chrome/browser/ui/views/speech_recognition_bubble_views.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698