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

Side by Side Diff: third_party/WebKit/Source/core/frame/VisualViewport.cpp

Issue 2858963002: Replace ASSERT with DCHECK in core/ (Closed)
Patch Set: WorkerBackingThread Created 3 years, 7 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 424 matching lines...) Expand 10 before | Expand all | Expand 10 after
435 is_horizontal ? web_overlay_scrollbar_horizontal_ 435 is_horizontal ? web_overlay_scrollbar_horizontal_
436 : web_overlay_scrollbar_vertical_; 436 : web_overlay_scrollbar_vertical_;
437 437
438 ScrollbarThemeOverlay& theme = ScrollbarThemeOverlay::MobileTheme(); 438 ScrollbarThemeOverlay& theme = ScrollbarThemeOverlay::MobileTheme();
439 int thumb_thickness = theme.ThumbThickness(); 439 int thumb_thickness = theme.ThumbThickness();
440 int scrollbar_thickness = theme.ScrollbarThickness(kRegularScrollbar); 440 int scrollbar_thickness = theme.ScrollbarThickness(kRegularScrollbar);
441 int scrollbar_margin = theme.ScrollbarMargin(); 441 int scrollbar_margin = theme.ScrollbarMargin();
442 442
443 if (!web_scrollbar_layer) { 443 if (!web_scrollbar_layer) {
444 ScrollingCoordinator* coordinator = GetPage().GetScrollingCoordinator(); 444 ScrollingCoordinator* coordinator = GetPage().GetScrollingCoordinator();
445 ASSERT(coordinator); 445 DCHECK(coordinator);
446 ScrollbarOrientation webcore_orientation = 446 ScrollbarOrientation webcore_orientation =
447 is_horizontal ? kHorizontalScrollbar : kVerticalScrollbar; 447 is_horizontal ? kHorizontalScrollbar : kVerticalScrollbar;
448 web_scrollbar_layer = coordinator->CreateSolidColorScrollbarLayer( 448 web_scrollbar_layer = coordinator->CreateSolidColorScrollbarLayer(
449 webcore_orientation, thumb_thickness, scrollbar_margin, false); 449 webcore_orientation, thumb_thickness, scrollbar_margin, false);
450 450
451 // The compositor will control the scrollbar's visibility. Set to invisible 451 // The compositor will control the scrollbar's visibility. Set to invisible
452 // by default so scrollbars don't show up in layout tests. 452 // by default so scrollbars don't show up in layout tests.
453 web_scrollbar_layer->Layer()->SetOpacity(0); 453 web_scrollbar_layer->Layer()->SetOpacity(0);
454 scrollbar_graphics_layer->SetContentsToPlatformLayer( 454 scrollbar_graphics_layer->SetContentsToPlatformLayer(
455 web_scrollbar_layer->Layer()); 455 web_scrollbar_layer->Layer());
(...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after
856 } else if (graphics_layer == root_transform_layer_.get()) { 856 } else if (graphics_layer == root_transform_layer_.get()) {
857 name = "Root Transform Layer"; 857 name = "Root Transform Layer";
858 } else { 858 } else {
859 NOTREACHED(); 859 NOTREACHED();
860 } 860 }
861 861
862 return name; 862 return name;
863 } 863 }
864 864
865 } // namespace blink 865 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698