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

Side by Side Diff: Source/core/testing/Internals.cpp

Issue 23516012: Rename StyleSheetCollections to StyleEngine. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 3 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
« no previous file with comments | « Source/core/rendering/RootInlineBox.cpp ('k') | Source/web/WebDocument.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * Copyright (C) 2013 Apple Inc. All rights reserved. 3 * Copyright (C) 2013 Apple Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 1907 matching lines...) Expand 10 before | Expand all | Expand 10 after
1918 } 1918 }
1919 1919
1920 void Internals::insertAuthorCSS(Document* document, const String& css) const 1920 void Internals::insertAuthorCSS(Document* document, const String& css) const
1921 { 1921 {
1922 if (!document) 1922 if (!document)
1923 return; 1923 return;
1924 1924
1925 RefPtr<StyleSheetContents> parsedSheet = StyleSheetContents::create(*documen t); 1925 RefPtr<StyleSheetContents> parsedSheet = StyleSheetContents::create(*documen t);
1926 parsedSheet->setIsUserStyleSheet(false); 1926 parsedSheet->setIsUserStyleSheet(false);
1927 parsedSheet->parseString(css); 1927 parsedSheet->parseString(css);
1928 document->styleSheetCollections()->addAuthorSheet(parsedSheet); 1928 document->styleEngine()->addAuthorSheet(parsedSheet);
1929 } 1929 }
1930 1930
1931 void Internals::insertUserCSS(Document* document, const String& css) const 1931 void Internals::insertUserCSS(Document* document, const String& css) const
1932 { 1932 {
1933 if (!document) 1933 if (!document)
1934 return; 1934 return;
1935 1935
1936 RefPtr<StyleSheetContents> parsedSheet = StyleSheetContents::create(*documen t); 1936 RefPtr<StyleSheetContents> parsedSheet = StyleSheetContents::create(*documen t);
1937 parsedSheet->setIsUserStyleSheet(true); 1937 parsedSheet->setIsUserStyleSheet(true);
1938 parsedSheet->parseString(css); 1938 parsedSheet->parseString(css);
1939 document->styleSheetCollections()->addUserSheet(parsedSheet); 1939 document->styleEngine()->addUserSheet(parsedSheet);
1940 } 1940 }
1941 1941
1942 String Internals::counterValue(Element* element) 1942 String Internals::counterValue(Element* element)
1943 { 1943 {
1944 if (!element) 1944 if (!element)
1945 return String(); 1945 return String();
1946 1946
1947 return counterValueForElement(element); 1947 return counterValueForElement(element);
1948 } 1948 }
1949 1949
(...skipping 321 matching lines...) Expand 10 before | Expand all | Expand 10 after
2271 return false; 2271 return false;
2272 sharedContext->getExtensions()->loseContextCHROMIUM(Extensions3D::GUILTY_CON TEXT_RESET_ARB, Extensions3D::INNOCENT_CONTEXT_RESET_ARB); 2272 sharedContext->getExtensions()->loseContextCHROMIUM(Extensions3D::GUILTY_CON TEXT_RESET_ARB, Extensions3D::INNOCENT_CONTEXT_RESET_ARB);
2273 // To prevent tests that call loseSharedGraphicsContext3D from being 2273 // To prevent tests that call loseSharedGraphicsContext3D from being
2274 // flaky, we call finish so that the context is guaranteed to be lost 2274 // flaky, we call finish so that the context is guaranteed to be lost
2275 // synchronously (i.e. before returning). 2275 // synchronously (i.e. before returning).
2276 sharedContext->finish(); 2276 sharedContext->finish();
2277 return true; 2277 return true;
2278 } 2278 }
2279 2279
2280 } 2280 }
OLDNEW
« no previous file with comments | « Source/core/rendering/RootInlineBox.cpp ('k') | Source/web/WebDocument.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698