#ifndef WebSettings_h
#define WebSettings_h
#include "../platform/WebCommon.h"
#include "../platform/WebSize.h"
#include <unicode/uscript.h>
namespace blink {
class WebString;
class WebURL;
class WebSettings {
public:
enum EditingBehavior {
EditingBehaviorMac,
EditingBehaviorWin,
EditingBehaviorUnix,
EditingBehaviorAndroid
};
virtual bool mainFrameResizesAreOrientationChanges() const = 0;
virtual bool shrinksViewportContentToFit() const = 0;
virtual bool scrollAnimatorEnabled() const = 0;
virtual bool touchEditingEnabled() const = 0;
virtual bool viewportEnabled() const = 0;
virtual bool viewportMetaEnabled() const = 0;
virtual void setAccelerated2dCanvasEnabled(bool) = 0;
virtual void setAccelerated2dCanvasMSAASampleCount(int) = 0;
virtual void setAcceleratedCompositingEnabled(bool) = 0;
virtual void setAcceleratedCompositingFor3DTransformsEnabled(bool) = 0;
virtual void setAcceleratedCompositingForAnimationEnabled(bool) = 0;
virtual void setAcceleratedCompositingForCanvasEnabled(bool) = 0;
virtual void setAcceleratedCompositingForFiltersEnabled(bool) = 0;
virtual void setAcceleratedCompositingForFixedPositionEnabled(bool) = 0;
virtual void setAcceleratedCompositingForFixedRootBackgroundEnabled(bool) = 0;
virtual void setAcceleratedCompositingForGpuRasterizationHintEnabled(bool) = 0;
virtual void setAcceleratedCompositingForOverflowScrollEnabled(bool) = 0;
virtual void setCompositorDrivenAcceleratedScrollingEnabled(bool) = 0;
virtual void setAcceleratedCompositingForTransitionEnabled(bool) { };
virtual void setAcceleratedCompositingForPluginsEnabled(bool) = 0;
virtual void setAcceleratedCompositingForScrollableFramesEnabled(bool) = 0;
virtual void setAcceleratedCompositingForVideoEnabled(bool) = 0;
virtual void setAllowDisplayOfInsecureContent(bool) = 0;
virtual void setAllowFileAccessFromFileURLs(bool) = 0;
virtual void setAllowCustomScrollbarInMainFrame(bool) = 0;
virtual void setAllowRunningOfInsecureContent(bool) = 0;
virtual void setAllowScriptsToCloseWindows(bool) = 0;
virtual void setAllowUniversalAccessFromFileURLs(bool) = 0;
virtual void setAntialiased2dCanvasEnabled(bool) = 0;
virtual void setAsynchronousSpellCheckingEnabled(bool) = 0;
virtual void setAutoZoomFocusedNodeToLegibleScale(bool) = 0;
virtual void setCaretBrowsingEnabled(bool) = 0;
virtual void setClobberUserAgentInitialScaleQuirk(bool) = 0;
virtual void setCompositedScrollingForFramesEnabled(bool) = 0;
virtual void setCompositorTouchHitTesting(bool) = 0;
virtual void setContainerCullingEnabled(bool) = 0;
virtual void setCookieEnabled(bool) = 0;
virtual void setNavigateOnDragDrop(bool) = 0;
virtual void setCursiveFontFamily(const WebString&, UScriptCode = USCRIPT_COMMON) = 0;
virtual void setDNSPrefetchingEnabled(bool) = 0;
virtual void setDOMPasteAllowed(bool) = 0;
virtual void setDefaultFixedFontSize(int) = 0;
virtual void setDefaultFontSize(int) = 0;
virtual void setDefaultTextEncodingName(const WebString&) = 0;
virtual void setDefaultVideoPosterURL(const WebString&) = 0;
void setDeferred2dCanvasEnabled(bool) { }
virtual void setDeferredFiltersEnabled(bool) = 0;
virtual void setDeferredImageDecodingEnabled(bool) = 0;
virtual void setDeviceScaleAdjustment(float) = 0;
virtual void setDeviceSupportsMouse(bool) = 0;
virtual void setDeviceSupportsTouch(bool) = 0;
virtual void setDoubleTapToZoomEnabled(bool) = 0;
virtual void setDownloadableBinaryFontsEnabled(bool) = 0;
virtual void setEditableLinkBehaviorNeverLive() = 0;
virtual void setEditingBehavior(EditingBehavior) = 0;
virtual void setEnableScrollAnimator(bool) = 0;
virtual void setEnableTouchAdjustment(bool) = 0;
virtual void setRegionBasedColumnsEnabled(bool) = 0;
virtual void setExperimentalWebGLEnabled(bool) = 0;
virtual void setExperimentalWebSocketEnabled(bool) = 0;
virtual void setFantasyFontFamily(const WebString&, UScriptCode = USCRIPT_COMMON) = 0;
virtual void setFixedFontFamily(const WebString&, UScriptCode = USCRIPT_COMMON) = 0;
virtual void setForceCompositingMode(bool) = 0;
virtual void setGestureTapHighlightEnabled(bool) = 0;
virtual void setHyperlinkAuditingEnabled(bool) = 0;
virtual void setIgnoreMainFrameOverflowHiddenQuirk(bool) = 0;
virtual void setImagesEnabled(bool) = 0;
virtual void setJavaEnabled(bool) = 0;
virtual void setJavaScriptCanAccessClipboard(bool) = 0;
virtual void setJavaScriptCanOpenWindowsAutomatically(bool) = 0;
virtual void setJavaScriptEnabled(bool) = 0;
virtual void setLayerSquashingEnabled(bool) = 0;
virtual void setLoadsImagesAutomatically(bool) = 0;
virtual void setLoadWithOverviewMode(bool) = 0;
virtual void setLocalStorageEnabled(bool) = 0;
virtual void setMainFrameClipsContent(bool) = 0;
virtual void setMainFrameResizesAreOrientationChanges(bool) = 0;
virtual void setMaxTouchPoints(int) = 0;
virtual void setMediaPlaybackRequiresUserGesture(bool) = 0;
virtual void setMinimumAccelerated2dCanvasSize(int) = 0;
virtual void setMinimumFontSize(int) = 0;
virtual void setMinimumLogicalFontSize(int) = 0;
virtual void setMockScrollbarsEnabled(bool) = 0;
virtual void setNeedsSiteSpecificQuirks(bool) = 0;
virtual void setOfflineWebApplicationCacheEnabled(bool) = 0;
virtual void setOpenGLMultisamplingEnabled(bool) = 0;
virtual void setPasswordEchoDurationInSeconds(double) = 0;
virtual void setPasswordEchoEnabled(bool) = 0;
virtual void setPerTilePaintingEnabled(bool) = 0;
virtual void setPictographFontFamily(const WebString&, UScriptCode = USCRIPT_COMMON) = 0;
virtual void setPinchOverlayScrollbarThickness(int) = 0;
virtual void setPinchVirtualViewportEnabled(bool) = 0;
virtual void setPluginsEnabled(bool) = 0;
virtual void setPrivilegedWebGLExtensionsEnabled(bool) = 0;
virtual void setRenderVSyncNotificationEnabled(bool) = 0;
virtual void setReportScreenSizeInPhysicalPixelsQuirk(bool) = 0;
virtual void setSansSerifFontFamily(const WebString&, UScriptCode = USCRIPT_COMMON) = 0;
virtual void setSelectTrailingWhitespaceEnabled(bool) = 0;
virtual void setSelectionIncludesAltImageText(bool) = 0;
virtual void setSerifFontFamily(const WebString&, UScriptCode = USCRIPT_COMMON) = 0;
virtual void setShouldPrintBackgrounds(bool) = 0;
virtual void setShouldClearDocumentBackground(bool) = 0;
virtual void setShouldRespectImageOrientation(bool) = 0;
virtual void setShowFPSCounter(bool) = 0;
virtual void setShowPaintRects(bool) = 0;
virtual void setShrinksStandaloneImagesToFit(bool) = 0;
virtual void setShrinksViewportContentToFit(bool) = 0;
virtual void setSmartInsertDeleteEnabled(bool) = 0;
virtual void setSpatialNavigationEnabled(bool) = 0;
virtual void setStandardFontFamily(const WebString&, UScriptCode = USCRIPT_COMMON) = 0;
virtual void setSupportDeprecatedTargetDensityDPI(bool) = 0;
virtual void setSupportsMultipleWindows(bool) = 0;
virtual void setSyncXHRInDocumentsEnabled(bool) = 0;
virtual void setTextAreasAreResizable(bool) = 0;
virtual void setTextAutosizingEnabled(bool) = 0;
virtual void setAccessibilityFontScaleFactor(float) = 0;
virtual void setThreadedHTMLParser(bool) = 0;
virtual void setTouchDragDropEnabled(bool) = 0;
virtual void setTouchEditingEnabled(bool) = 0;
virtual void setUnifiedTextCheckerEnabled(bool) = 0;
virtual void setUnsafePluginPastingEnabled(bool) = 0;
virtual void setUsesEncodingDetector(bool) = 0;
virtual void setUseLegacyBackgroundSizeShorthandBehavior(bool) = 0;
virtual void setUseSolidColorScrollbars(bool) = 0;
virtual void setUseWideViewport(bool) = 0;
virtual void setValidationMessageTimerMagnification(int) = 0;
virtual void setViewportEnabled(bool) = 0;
virtual void setViewportMetaEnabled(bool) = 0;
virtual void setViewportMetaLayoutSizeQuirk(bool) = 0;
virtual void setViewportMetaMergeContentQuirk(bool) = 0;
virtual void setViewportMetaNonUserScalableQuirk(bool) = 0;
virtual void setViewportMetaZeroValuesQuirk(bool) = 0;
virtual void setVisualWordMovementEnabled(bool) = 0;
virtual void setWebAudioEnabled(bool) = 0;
virtual void setWebGLErrorsToConsoleEnabled(bool) = 0;
virtual void setWebSecurityEnabled(bool) = 0;
virtual void setWideViewportQuirkEnabled(bool) = 0;
virtual void setXSSAuditorEnabled(bool) = 0;
virtual void setFixedPositionCreatesStackingContext(bool) { }
protected:
~WebSettings() { }
};
}
#endif