Bug 35380

Summary: [Qt] Compilation fails when WTF_USE_ACCELERATED_COMPOSITING=0
Product: WebKit Reporter: Jarkko Sakkinen <jarkko.sakkinen>
Component: CSSAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: Linux   
Attachments:
Description Flags
Fix suggestion
kenneth: review-
Compilation fix to MediaQuerySelector.cpp when WTF_USE_ACCELERATED_COMPOSITING=0
kenneth: review+, kenneth: commit-queue+
Same fix, added missing bug URL. none

Description Jarkko Sakkinen 2010-02-25 05:10:41 PST
WebKit trunk compilation failes when WTF_USE_ACCELERATED_COMPOSITING is set to zero.

I resolved this issue by doing the following change:

###########################################################################################################
diff --git a/WebCore/css/MediaQueryEvaluator.cpp b/WebCore/css/MediaQueryEvaluator.cpp
index 4963ed4..6864231 100644
--- a/WebCore/css/MediaQueryEvaluator.cpp
+++ b/WebCore/css/MediaQueryEvaluator.cpp
@@ -47,7 +47,7 @@
 #include "PlatformScreen.h"
 #include <wtf/HashMap.h>
 
-#if ENABLE(3D_RENDERING)
+#if ENABLE(3D_RENDERING) && USE(ACCELERATED_COMPOSITING)
 #include "RenderLayerCompositor.h"
 #endif
 
@@ -472,10 +472,12 @@ static bool transform_3dMediaFeatureEval(CSSValue* value, RenderStyle*, Frame* f
     bool returnValueIfNoParameter;
     int have3dRendering;
 
-#if ENABLE(3D_RENDERING)
+#if ENABLE(3D_RENDERING) 
     bool threeDEnabled = false;
+#if USE(ACCELERATED_COMPOSITING)
     if (RenderView* view = frame->contentRenderer())
         threeDEnabled = view->compositor()->hasAcceleratedCompositing();
+#endif
 
     returnValueIfNoParameter = threeDEnabled;
     have3dRendering = threeDEnabled ? 1 : 0;
###########################################################################################################
Comment 1 Jarkko Sakkinen 2010-02-25 05:13:03 PST
Created attachment 49478 [details]
Fix suggestion

Quickly done fix for the issue.
Comment 2 Kenneth Rohde Christiansen 2010-02-25 05:15:06 PST
Comment on attachment 49478 [details]
Fix suggestion

Looks OK to me, but needs a ChangeLog
Comment 3 Jarkko Sakkinen 2010-02-25 05:45:24 PST
Created attachment 49480 [details]
Compilation fix to MediaQuerySelector.cpp when WTF_USE_ACCELERATED_COMPOSITING=0
Comment 4 Jarkko Sakkinen 2010-02-26 01:12:43 PST
Created attachment 49574 [details]
Same fix, added missing bug URL.
Comment 5 WebKit Commit Bot 2010-02-26 12:59:15 PST
Comment on attachment 49574 [details]
Same fix, added missing bug URL.

Clearing flags on attachment: 49574

Committed r55303: <http://trac.webkit.org/changeset/55303>
Comment 6 WebKit Commit Bot 2010-02-26 12:59:19 PST
All reviewed patches have been landed.  Closing bug.