Changeset 68114 in webkit
- Timestamp:
- Sep 22, 2010 7:08:30 PM (14 years ago)
- Location:
- trunk
- Files:
-
- 2 deleted
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r68109 r68114 1 2010-09-22 Mihai Parparita <mihaip@chromium.org> 2 3 Reviewed by Darin Fisher. 4 5 [Chromium] User style layout tests don't pass on Chromium 6 https://bugs.webkit.org/show_bug.cgi?id=46069 7 8 User style tests should now pass with the Chromium DRT since we now 9 apply the styles immediately, just like the other ports (once we also 10 remove some bad baselines for user-style-top-frame-only added by 11 r62958). 12 13 Tests still don't pass with test_shell until it starts to use 14 InjectInExistingDocuments too. 15 16 * platform/chromium-mac/userscripts/user-style-top-frame-only-expected.txt: Removed. 17 * platform/chromium-win/userscripts/user-style-top-frame-only-expected.txt: Removed. 18 * platform/chromium/drt_expectations.txt: 19 1 20 2010-09-22 Kinuko Yasuda <kinuko@chromium.org> 2 21 -
trunk/LayoutTests/platform/chromium/drt_expectations.txt
r68013 r68114 141 141 BUG_DRT : platform/chromium/accessibility = PASS 142 142 BUG_DRT : userscripts/user-script-top-frame-only.html = PASS 143 BUG_DRT : userscripts/mixed-case-stylesheet.html = PASS 144 BUG_DRT : userscripts/simple-stylesheet.html = PASS 145 BUG_DRT : userscripts/user-style-all-frames.html = PASS 146 BUG_DRT : userscripts/user-style-top-frame-only.html = PASS -
trunk/WebCore/ChangeLog
r68112 r68114 1 2010-09-22 Mihai Parparita <mihaip@chromium.org> 2 3 Reviewed by Darin Fisher. 4 5 [Chromium] User style layout tests don't pass on Chromium 6 https://bugs.webkit.org/show_bug.cgi?id=46069 7 8 Instead of making resetUserStyleCacheInAllFrames be a no-op for 9 Chromium, have it be controlled by a UserStyleInjectionTime enum. 10 11 Also move the UserStyleSheet::Level enum to be inside 12 UserStyleSheetTypes for consistency. 13 14 * WebCore.exp.in: 15 * dom/Document.cpp: 16 (WebCore::Document::pageGroupUserSheets): 17 * page/PageGroup.cpp: 18 (WebCore::PageGroup::addUserStyleSheetToWorld): 19 * page/PageGroup.h: 20 * page/UserStyleSheet.h: 21 (WebCore::UserStyleSheet::UserStyleSheet): 22 (WebCore::UserStyleSheet::level): 23 * page/UserStyleSheetTypes.h: 24 1 25 2010-09-22 Ruben <chromium@hybridsource.org> 2 26 -
trunk/WebCore/WebCore.exp.in
r68054 r68114 829 829 __ZN7WebCore9PageGroup20removeAllUserContentEv 830 830 __ZN7WebCore9PageGroup21removeAllVisitedLinksEv 831 __ZN7WebCore9PageGroup24addUserStyleSheetToWorldEPNS_15DOMWrapperWorldERKN3WTF6StringERKNS_4KURLENS3_10PassOwnPtrINS3_6VectorIS4_Lm0EEEEESD_NS_25UserContentInjectedFramesENS_14UserStyle Sheet5LevelE831 __ZN7WebCore9PageGroup24addUserStyleSheetToWorldEPNS_15DOMWrapperWorldERKN3WTF6StringERKNS_4KURLENS3_10PassOwnPtrINS3_6VectorIS4_Lm0EEEEESD_NS_25UserContentInjectedFramesENS_14UserStyleLevelENS_22UserStyleInjectionTimeE 832 832 __ZN7WebCore9PageGroup25removeUserScriptFromWorldEPNS_15DOMWrapperWorldERKNS_4KURLE 833 833 __ZN7WebCore9PageGroup26removeUserScriptsFromWorldEPNS_15DOMWrapperWorldE -
trunk/WebCore/dom/Document.cpp
r68096 r68114 2309 2309 continue; 2310 2310 RefPtr<CSSStyleSheet> parsedSheet = CSSStyleSheet::createInline(const_cast<Document*>(this), sheet->url()); 2311 parsedSheet->setIsUserStyleSheet(sheet->level() == UserStyle Sheet::UserLevel);2311 parsedSheet->setIsUserStyleSheet(sheet->level() == UserStyleUserLevel); 2312 2312 parsedSheet->parseString(sheet->source(), !inQuirksMode()); 2313 2313 if (!m_pageGroupUserSheets) -
trunk/WebCore/page/PageGroup.cpp
r66247 r68114 241 241 PassOwnPtr<Vector<String> > whitelist, PassOwnPtr<Vector<String> > blacklist, 242 242 UserContentInjectedFrames injectedFrames, 243 UserStyleSheet::Level level) 243 UserStyleLevel level, 244 UserStyleInjectionTime injectionTime) 244 245 { 245 246 ASSERT_ARG(world, world); … … 253 254 styleSheetsInWorld->append(userStyleSheet.release()); 254 255 255 resetUserStyleCacheInAllFrames(); 256 if (injectionTime == InjectInExistingDocuments) 257 resetUserStyleCacheInAllFrames(); 256 258 } 257 259 … … 359 361 void PageGroup::resetUserStyleCacheInAllFrames() 360 362 { 361 #if !PLATFORM(CHROMIUM)362 363 // Clear our cached sheets and have them just reparse. 363 364 HashSet<Page*>::const_iterator end = m_pages.end(); … … 366 367 frame->document()->updatePageGroupUserSheets(); 367 368 } 368 #endif369 369 } 370 370 -
trunk/WebCore/page/PageGroup.h
r65670 r68114 84 84 PassOwnPtr<Vector<String> > whitelist, PassOwnPtr<Vector<String> > blacklist, 85 85 UserContentInjectedFrames, 86 UserStyle Sheet::Level level = UserStyleSheet::UserLevel);87 86 UserStyleLevel level = UserStyleUserLevel, 87 UserStyleInjectionTime injectionTime = InjectInExistingDocuments); 88 88 void removeUserScriptFromWorld(DOMWrapperWorld*, const KURL&); 89 89 void removeUserStyleSheetFromWorld(DOMWrapperWorld*, const KURL&); -
trunk/WebCore/page/UserStyleSheet.h
r65273 r68114 38 38 class UserStyleSheet : public Noncopyable { 39 39 public: 40 enum Level {41 UserLevel,42 AuthorLevel43 };44 45 40 UserStyleSheet(const String& source, const KURL& url, 46 41 PassOwnPtr<Vector<String> > whitelist, PassOwnPtr<Vector<String> > blacklist, 47 UserContentInjectedFrames injectedFrames, Level level)42 UserContentInjectedFrames injectedFrames, UserStyleLevel level) 48 43 : m_source(source) 49 44 , m_url(url) … … 60 55 const Vector<String>* blacklist() const { return m_blacklist.get(); } 61 56 UserContentInjectedFrames injectedFrames() const { return m_injectedFrames; } 62 Level level() const { return m_level; }57 UserStyleLevel level() const { return m_level; } 63 58 64 59 private: … … 68 63 OwnPtr<Vector<String> > m_blacklist; 69 64 UserContentInjectedFrames m_injectedFrames; 70 Level m_level;65 UserStyleLevel m_level; 71 66 }; 72 67 -
trunk/WebCore/page/UserStyleSheetTypes.h
r50907 r68114 32 32 namespace WebCore { 33 33 34 enum UserStyleInjectionTime { InjectInExistingDocuments, InjectInSubsequentDocuments }; 35 enum UserStyleLevel { UserStyleUserLevel, UserStyleAuthorLevel }; 36 34 37 class DOMWrapperWorld; 35 38 class UserStyleSheet; -
trunk/WebKit/chromium/ChangeLog
r68113 r68114 1 2010-09-22 Mihai Parparita <mihaip@chromium.org> 2 3 Reviewed by Darin Fisher. 4 5 [Chromium] User style layout tests don't pass on Chromium 6 https://bugs.webkit.org/show_bug.cgi?id=46069 7 8 Expose UserStyleInjectionTime in WebView. 9 10 * public/WebView.h: 11 * src/WebViewImpl.cpp: 12 (WebKit::WebView::addUserStyleSheet): 13 1 14 2010-09-22 James Robinson <jamesr@chromium.org> 2 15 -
trunk/WebKit/chromium/public/WebView.h
r68000 r68114 66 66 UserContentInjectInTopFrameOnly 67 67 }; 68 69 // Controls which documents user styles are injected into. 70 enum UserStyleInjectionTime { 71 UserStyleInjectInExistingDocuments, 72 UserStyleInjectInSubsequentDocuments 73 }; 74 68 75 69 76 // Initialization ------------------------------------------------------ … … 329 336 WEBKIT_API static void addUserStyleSheet(const WebString& sourceCode, 330 337 const WebVector<WebString>& patterns, 331 UserContentInjectIn injectIn); 338 UserContentInjectIn injectIn, 339 UserStyleInjectionTime injectionTime = UserStyleInjectInSubsequentDocuments); 332 340 WEBKIT_API static void removeAllUserContent(); 333 341 -
trunk/WebKit/chromium/src/AssertMatchingEnums.cpp
r68012 r68114 50 50 #include "UserContentTypes.h" 51 51 #include "UserScriptTypes.h" 52 #include "UserStyleSheetTypes.h" 52 53 #include "VideoFrameChromium.h" 53 54 #include "WebAccessibilityObject.h" … … 354 355 COMPILE_ASSERT_MATCHING_ENUM(WebView::UserContentInjectInAllFrames, InjectInAllFrames); 355 356 COMPILE_ASSERT_MATCHING_ENUM(WebView::UserContentInjectInTopFrameOnly, InjectInTopFrameOnly); 357 COMPILE_ASSERT_MATCHING_ENUM(WebView::UserStyleInjectInExistingDocuments, InjectInExistingDocuments); 358 COMPILE_ASSERT_MATCHING_ENUM(WebView::UserStyleInjectInSubsequentDocuments, InjectInSubsequentDocuments); 356 359 357 360 COMPILE_ASSERT_MATCHING_ENUM(WebIDBKey::NullType, IDBKey::NullType); -
trunk/WebKit/chromium/src/WebViewImpl.cpp
r68112 r68114 2016 2016 void WebView::addUserStyleSheet(const WebString& sourceCode, 2017 2017 const WebVector<WebString>& patternsIn, 2018 WebView::UserContentInjectIn injectIn) 2018 WebView::UserContentInjectIn injectIn, 2019 WebView::UserStyleInjectionTime injectionTime) 2019 2020 { 2020 2021 OwnPtr<Vector<String> > patterns(new Vector<String>); … … 2031 2032 pageGroup->addUserStyleSheetToWorld(world.get(), sourceCode, WebURL(), patterns.release(), 0, 2032 2033 static_cast<UserContentInjectedFrames>(injectIn), 2033 UserStyleSheet::AuthorLevel); 2034 UserStyleAuthorLevel, 2035 static_cast<WebCore::UserStyleInjectionTime>(injectionTime)); 2034 2036 } 2035 2037 -
trunk/WebKitTools/ChangeLog
r68107 r68114 1 2010-09-22 Mihai Parparita <mihaip@chromium.org> 2 3 Reviewed by Darin Fisher. 4 5 [Chromium] User style layout tests don't pass on Chromium 6 https://bugs.webkit.org/show_bug.cgi?id=46069 7 8 Fix a typo in LayoutTestController::addUserStyleSheet that was causing a 9 crash the Chromium DRT. Pass InjectInExistingDocuments to mimic DRT 10 behavior from other ports. 11 12 * DumpRenderTree/chromium/LayoutTestController.cpp: 13 (LayoutTestController::addUserStyleSheet): 14 1 15 2010-09-22 Brent Fulgham <bfulgham@webkit.org> 2 16 -
trunk/WebKitTools/DumpRenderTree/chromium/LayoutTestController.cpp
r67809 r68114 1444 1444 WebView::addUserStyleSheet( 1445 1445 cppVariantToWebString(arguments[0]), WebVector<WebString>(), 1446 arguments[2].toBoolean() ? WebView::UserContentInjectInAllFrames : WebView::UserContentInjectInTopFrameOnly); 1446 arguments[1].toBoolean() ? WebView::UserContentInjectInAllFrames : WebView::UserContentInjectInTopFrameOnly, 1447 // Chromium defaults to InjectInSubsequentDocuments, but for compatibility 1448 // with the other ports' DRTs, we use UserStyleInjectInExistingDocuments. 1449 WebView::UserStyleInjectInExistingDocuments); 1447 1450 } 1448 1451
Note: See TracChangeset
for help on using the changeset viewer.