Bug 99275

Summary: Make UserScript and UserStyleSheet classes into value objects that are copyable
Product: WebKit Reporter: Sam Weinig <sam>
Component: New BugsAssignee: Sam Weinig <sam>
Status: RESOLVED FIXED    
Severity: Normal CC: abecsi, cmarcelo, gustavo, gyuyoung.kim, menard, philn, rakuco, thorton, webkit.review.bot, xan.lopez
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch thorton: review+

Sam Weinig
Reported 2012-10-14 14:18:23 PDT
Make UserScript and UserStyleSheet value objects that are copyable
Attachments
Patch (31.14 KB, patch)
2012-10-14 14:26 PDT, Sam Weinig
no flags
Patch (32.97 KB, patch)
2012-10-14 14:38 PDT, Sam Weinig
thorton: review+
Sam Weinig
Comment 1 2012-10-14 14:26:25 PDT
WebKit Review Bot
Comment 2 2012-10-14 14:29:55 PDT
Attachment 168590 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebCore/ChangeLog', u'Source/WebCor..." exit_code: 1 Source/WebCore/page/PageGroup.cpp:265: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebCore/page/PageGroup.cpp:280: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebCore/page/UserStyleSheet.h:40: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebKit/efl/WebCoreSupport/DumpRenderTreeSupportEfl.cpp:299: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebCore/page/UserScript.h:40: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebCore/page/PageGroup.h:86: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebCore/page/PageGroup.h:89: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Total errors found: 7 in 19 files If any of these errors are false positives, please file a bug against check-webkit-style.
Early Warning System Bot
Comment 3 2012-10-14 14:34:59 PDT
Sam Weinig
Comment 4 2012-10-14 14:38:16 PDT
Tim Horton
Comment 5 2012-10-14 14:40:45 PDT
View in context: https://bugs.webkit.org/attachment.cgi?id=168590&action=review r=me assuming you've just managed to fix the build issues. > Source/WebCore/ChangeLog:34 > + (WebCore::PageGroup::addUserScriptToWorld): > + (WebCore::PageGroup::addUserStyleSheetToWorld): > + * page/PageGroup.h: > + (PageGroup): > + * page/UserContentURLPattern.cpp: > + (WebCore::UserContentURLPattern::matchesPatterns): > + * page/UserContentURLPattern.h: > + (UserContentURLPattern): > + Update to not assume whitelist and blacklist are in Vector<String>*. > + > + * page/UserScript.h: > + (UserScript): > + (WebCore::UserScript::UserScript): > + (WebCore::UserScript::whitelist): > + (WebCore::UserScript::blacklist): > + * page/UserStyleSheet.h: > + (UserStyleSheet): > + (WebCore::UserStyleSheet::UserStyleSheet): > + (WebCore::UserStyleSheet::whitelist): > + (WebCore::UserStyleSheet::blacklist): Dan would not be happy about this lack of per-function comments. > Source/WebCore/page/UserContentURLPattern.cpp:39 > + for (unsigned i = 0; i < whitelist.size(); ++i) { I know you're not introducing this, but should we save size aside instead of computing it every time? >> Source/WebCore/page/UserScript.h:40 >> + const Vector<String>& whitelist, const Vector<String>& blacklist, > > Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Stylebot is right, why are these all lined up? That is unusual for WebCore.
WebKit Review Bot
Comment 6 2012-10-14 14:41:26 PDT
Attachment 168592 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebCore/ChangeLog', u'Source/WebCor..." exit_code: 1 Source/WebCore/page/PageGroup.cpp:265: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebCore/page/PageGroup.cpp:280: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebCore/page/UserStyleSheet.h:40: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebKit/efl/WebCoreSupport/DumpRenderTreeSupportEfl.cpp:299: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebCore/page/UserScript.h:40: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebCore/page/PageGroup.h:86: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Source/WebCore/page/PageGroup.h:89: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Total errors found: 7 in 21 files If any of these errors are false positives, please file a bug against check-webkit-style.
Sam Weinig
Comment 7 2012-10-14 14:55:48 PDT
Note You need to log in before you can comment on or make changes to this bug.