Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move BuilderState::createFilterOperations() to a separate file #5479

Conversation

shallawa
Copy link
Contributor

@shallawa shallawa commented Oct 18, 2022

ea05e83

Move BuilderState::createFilterOperations() to a separate file
https://bugs.webkit.org/show_bug.cgi?id=246675

Reviewed by Antti Koivisto.

Make this function a stand-alone function and make used by the CSS style builder.
The plan is to use this function the 2D canvas for the filter API.

* Source/WebCore/Sources.txt:
* Source/WebCore/WebCore.xcodeproj/project.pbxproj:
* Source/WebCore/css/CSSFilterImageValue.cpp:
(WebCore::CSSFilterImageValue::createFilterOperations):
* Source/WebCore/style/ColorFromPrimitiveValue.cpp: Added.
(WebCore::colorFromPrimitiveValue):
(WebCore::colorFromPrimitiveValueWithResolvedCurrentColor):
* Source/WebCore/style/ColorFromPrimitiveValue.h: Added.
* Source/WebCore/style/FilterOperationsBuilder.cpp: Added.
(WebCore::filterOperationForType):
(WebCore::createFilterOperations):
* Source/WebCore/style/FilterOperationsBuilder.h: Added.
* Source/WebCore/style/StyleBuilderConverter.h:
(WebCore::Style::BuilderConverter::convertFilterOperations):
* Source/WebCore/style/StyleBuilderState.cpp:
(WebCore::Style::BuilderState::createFilterOperations):
(WebCore::Style::BuilderState::colorFromPrimitiveValue const):
(WebCore::Style::BuilderState::colorFromPrimitiveValueWithResolvedCurrentColor const):
(WebCore::Style::filterOperationForType): Deleted.
* Source/WebCore/style/StyleBuilderState.h:

Canonical link: https://commits.webkit.org/255706@main

fb7622f

Misc iOS, tvOS & watchOS macOS Linux Windows
βœ… πŸ§ͺ style βœ… πŸ›  ios βœ… πŸ›  mac βœ… πŸ›  wpe   πŸ›  πŸ§ͺ win
βœ… πŸ§ͺ bindings βœ… πŸ›  ios-sim βœ… πŸ›  mac-debug βœ… πŸ›  gtk   πŸ›  wincairo
βœ… πŸ§ͺ webkitperl   πŸ§ͺ ios-wk2 βœ… πŸ›  mac-AS-debug βœ… πŸ§ͺ gtk-wk2
βœ… πŸ§ͺ api-ios βœ… πŸ§ͺ api-mac   πŸ§ͺ api-gtk
βœ… πŸ›  tv   πŸ§ͺ mac-wk1
βœ… πŸ›  tv-sim βœ… πŸ§ͺ mac-wk2
βœ… πŸ›  πŸ§ͺ merge βœ… πŸ›  watch   πŸ§ͺ mac-AS-debug-wk2
βœ… πŸ›  watch-sim βœ… πŸ§ͺ mac-wk2-stress

@shallawa shallawa self-assigned this Oct 18, 2022
@shallawa shallawa added Layout and Rendering For bugs with layout and rendering of Web pages. WebKit Nightly Build labels Oct 18, 2022
@webkit-ews-buildbot webkit-ews-buildbot added the merging-blocked Applied to prevent a change from being merged label Oct 18, 2022
@shallawa shallawa removed the merging-blocked Applied to prevent a change from being merged label Oct 18, 2022
@shallawa shallawa force-pushed the eng/Move-BuilderStatecreateFilterOperations-to-a-separate-file branch from 95331ac to 5d32e99 Compare October 18, 2022 16:25
@shallawa shallawa requested a review from anttijk October 18, 2022 17:42
Comment on lines +28 to +29
namespace WebCore {

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should go to Style namespace

Comment on lines 33 to 35
namespace Style {
enum class ForVisitedLink : bool;
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything should be in Style namespace

Comment on lines +35 to +37
namespace WebCore {

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Style namespace

#include "StyleBuilderState.h"
#include "StyleColor.h"

namespace WebCore {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be in WebCore::Style namespace

@shallawa shallawa force-pushed the eng/Move-BuilderStatecreateFilterOperations-to-a-separate-file branch from 5d32e99 to fb7622f Compare October 18, 2022 21:07
@shallawa shallawa added Canvas Bugs related to the canvas element. and removed Layout and Rendering For bugs with layout and rendering of Web pages. labels Oct 18, 2022
@shallawa shallawa added the merge-queue Applied to send a pull request to merge-queue label Oct 18, 2022
https://bugs.webkit.org/show_bug.cgi?id=246675

Reviewed by Antti Koivisto.

Make this function a stand-alone function and make used by the CSS style builder.
The plan is to use this function the 2D canvas for the filter API.

* Source/WebCore/Sources.txt:
* Source/WebCore/WebCore.xcodeproj/project.pbxproj:
* Source/WebCore/css/CSSFilterImageValue.cpp:
(WebCore::CSSFilterImageValue::createFilterOperations):
* Source/WebCore/style/ColorFromPrimitiveValue.cpp: Added.
(WebCore::colorFromPrimitiveValue):
(WebCore::colorFromPrimitiveValueWithResolvedCurrentColor):
* Source/WebCore/style/ColorFromPrimitiveValue.h: Added.
* Source/WebCore/style/FilterOperationsBuilder.cpp: Added.
(WebCore::filterOperationForType):
(WebCore::createFilterOperations):
* Source/WebCore/style/FilterOperationsBuilder.h: Added.
* Source/WebCore/style/StyleBuilderConverter.h:
(WebCore::Style::BuilderConverter::convertFilterOperations):
* Source/WebCore/style/StyleBuilderState.cpp:
(WebCore::Style::BuilderState::createFilterOperations):
(WebCore::Style::BuilderState::colorFromPrimitiveValue const):
(WebCore::Style::BuilderState::colorFromPrimitiveValueWithResolvedCurrentColor const):
(WebCore::Style::filterOperationForType): Deleted.
* Source/WebCore/style/StyleBuilderState.h:

Canonical link: https://commits.webkit.org/255706@main
@webkit-early-warning-system webkit-early-warning-system force-pushed the eng/Move-BuilderStatecreateFilterOperations-to-a-separate-file branch from fb7622f to ea05e83 Compare October 19, 2022 00:27
@webkit-commit-queue
Copy link
Collaborator

Committed 255706@main (ea05e83): https://commits.webkit.org/255706@main

Reviewed commits have been landed. Closing PR #5479 and removing active labels.

@webkit-early-warning-system webkit-early-warning-system merged commit ea05e83 into WebKit:main Oct 19, 2022
@webkit-commit-queue webkit-commit-queue removed the merge-queue Applied to send a pull request to merge-queue label Oct 19, 2022
@shallawa shallawa deleted the eng/Move-BuilderStatecreateFilterOperations-to-a-separate-file branch May 9, 2023 20:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Canvas Bugs related to the canvas element.
Projects
None yet
5 participants