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

Side by Side Diff: Source/core/rendering/RenderObject.cpp

Issue 360103008: Remove dead StyleDifference::needsRecompositeLayer (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv ed. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv ed.
7 * Copyright (C) 2009 Google Inc. All rights reserved. 7 * Copyright (C) 2009 Google Inc. All rights reserved.
8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) 8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/)
9 * 9 *
10 * This library is free software; you can redistribute it and/or 10 * This library is free software; you can redistribute it and/or
(...skipping 1871 matching lines...) Expand 10 before | Expand all | Expand 10 after
1882 { 1882 {
1883 if (contextSensitiveProperties & ContextSensitivePropertyTransform && isSVG( )) 1883 if (contextSensitiveProperties & ContextSensitivePropertyTransform && isSVG( ))
1884 diff.setNeedsFullLayout(); 1884 diff.setNeedsFullLayout();
1885 1885
1886 // If transform changed, and the layer does not paint into its own separate backing, then we need to invalidate paints. 1886 // If transform changed, and the layer does not paint into its own separate backing, then we need to invalidate paints.
1887 if (contextSensitiveProperties & ContextSensitivePropertyTransform) { 1887 if (contextSensitiveProperties & ContextSensitivePropertyTransform) {
1888 // Text nodes share style with their parents but transforms don't apply to them, 1888 // Text nodes share style with their parents but transforms don't apply to them,
1889 // hence the !isText() check. 1889 // hence the !isText() check.
1890 if (!isText() && (!hasLayer() || !toRenderLayerModelObject(this)->layer( )->hasStyleDeterminedDirectCompositingReasons())) 1890 if (!isText() && (!hasLayer() || !toRenderLayerModelObject(this)->layer( )->hasStyleDeterminedDirectCompositingReasons()))
1891 diff.setNeedsRepaintLayer(); 1891 diff.setNeedsRepaintLayer();
1892 else
1893 diff.setNeedsRecompositeLayer();
1894 } 1892 }
1895 1893
1896 // If opacity or zIndex changed, and the layer does not paint into its own s eparate backing, then we need to invalidate paints (also 1894 // If opacity or zIndex changed, and the layer does not paint into its own s eparate backing, then we need to invalidate paints (also
1897 // ignoring text nodes) 1895 // ignoring text nodes)
1898 if (contextSensitiveProperties & (ContextSensitivePropertyOpacity | ContextS ensitivePropertyZIndex)) { 1896 if (contextSensitiveProperties & (ContextSensitivePropertyOpacity | ContextS ensitivePropertyZIndex)) {
1899 if (!isText() && (!hasLayer() || !toRenderLayerModelObject(this)->layer( )->hasStyleDeterminedDirectCompositingReasons())) 1897 if (!isText() && (!hasLayer() || !toRenderLayerModelObject(this)->layer( )->hasStyleDeterminedDirectCompositingReasons()))
1900 diff.setNeedsRepaintLayer(); 1898 diff.setNeedsRepaintLayer();
1901 else
1902 diff.setNeedsRecompositeLayer();
1903 } 1899 }
1904 1900
1905 // If filter changed, and the layer does not paint into its own separate bac king or it paints with filters, then we need to invalidate paints. 1901 // If filter changed, and the layer does not paint into its own separate bac king or it paints with filters, then we need to invalidate paints.
1906 if ((contextSensitiveProperties & ContextSensitivePropertyFilter) && hasLaye r()) { 1902 if ((contextSensitiveProperties & ContextSensitivePropertyFilter) && hasLaye r()) {
1907 RenderLayer* layer = toRenderLayerModelObject(this)->layer(); 1903 RenderLayer* layer = toRenderLayerModelObject(this)->layer();
1908 if (!layer->hasStyleDeterminedDirectCompositingReasons() || layer->paint sWithFilters()) 1904 if (!layer->hasStyleDeterminedDirectCompositingReasons() || layer->paint sWithFilters())
1909 diff.setNeedsRepaintLayer(); 1905 diff.setNeedsRepaintLayer();
1910 else
1911 diff.setNeedsRecompositeLayer();
1912 } 1906 }
1913 1907
1914 if ((contextSensitiveProperties & ContextSensitivePropertyTextOrColor) && !d iff.needsRepaint() 1908 if ((contextSensitiveProperties & ContextSensitivePropertyTextOrColor) && !d iff.needsRepaint()
1915 && hasImmediateNonWhitespaceTextChildOrPropertiesDependentOnColor()) 1909 && hasImmediateNonWhitespaceTextChildOrPropertiesDependentOnColor())
1916 diff.setNeedsRepaintObject(); 1910 diff.setNeedsRepaintObject();
1917 1911
1918 // The answer to layerTypeRequired() for plugins, iframes, and canvas can ch ange without the actual 1912 // The answer to layerTypeRequired() for plugins, iframes, and canvas can ch ange without the actual
1919 // style changing, since it depends on whether we decide to composite these elements. When the 1913 // style changing, since it depends on whether we decide to composite these elements. When the
1920 // layer status of one of these elements changes, we need to force a layout. 1914 // layer status of one of these elements changes, we need to force a layout.
1921 if (!diff.needsFullLayout() && style() && isLayerModelObject()) { 1915 if (!diff.needsFullLayout() && style() && isLayerModelObject()) {
(...skipping 1509 matching lines...) Expand 10 before | Expand all | Expand 10 after
3431 { 3425 {
3432 if (object1) { 3426 if (object1) {
3433 const WebCore::RenderObject* root = object1; 3427 const WebCore::RenderObject* root = object1;
3434 while (root->parent()) 3428 while (root->parent())
3435 root = root->parent(); 3429 root = root->parent();
3436 root->showRenderTreeAndMark(object1, "*", object2, "-", 0); 3430 root->showRenderTreeAndMark(object1, "*", object2, "-", 0);
3437 } 3431 }
3438 } 3432 }
3439 3433
3440 #endif 3434 #endif
OLDNEW
« no previous file with comments | « Source/core/editing/SimplifyMarkupCommand.cpp ('k') | Source/core/rendering/style/RenderStyle.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698