Package org.robolectric.fakes
Class RoboWebSettings
java.lang.Object
android.webkit.WebSettings
org.robolectric.fakes.RoboWebSettings
public class RoboWebSettings extends WebSettings
Robolectric implementation of
WebSettings
.-
Nested Class Summary
Nested classes/interfaces inherited from class android.webkit.WebSettings
WebSettings.CacheMode, WebSettings.ForceDark, WebSettings.LayoutAlgorithm, WebSettings.PluginState, WebSettings.RenderPriority, WebSettings.TextSize, WebSettings.ZoomDensity
-
Field Summary
Fields inherited from class android.webkit.WebSettings
FORCE_DARK_AUTO, FORCE_DARK_OFF, FORCE_DARK_ON, LOAD_CACHE_ELSE_NETWORK, LOAD_CACHE_ONLY, LOAD_DEFAULT, LOAD_NO_CACHE, LOAD_NORMAL, MENU_ITEM_NONE, MENU_ITEM_PROCESS_TEXT, MENU_ITEM_SHARE, MENU_ITEM_WEB_SEARCH, MIXED_CONTENT_ALWAYS_ALLOW, MIXED_CONTENT_COMPATIBILITY_MODE, MIXED_CONTENT_NEVER_ALLOW
-
Constructor Summary
Constructors Constructor Description RoboWebSettings()
-
Method Summary
Methods inherited from class android.webkit.WebSettings
getDefaultUserAgent, getPluginsPath, getTextSize, getUseDoubleTree, setPluginsPath, setTextSize, setUseDoubleTree
-
Constructor Details
-
RoboWebSettings
public RoboWebSettings()
-
-
Method Details
-
getBlockNetworkImage
public boolean getBlockNetworkImage()- Specified by:
getBlockNetworkImage
in classWebSettings
-
setBlockNetworkImage
public void setBlockNetworkImage(boolean flag)- Specified by:
setBlockNetworkImage
in classWebSettings
-
getJavaScriptEnabled
public boolean getJavaScriptEnabled()- Specified by:
getJavaScriptEnabled
in classWebSettings
-
setJavaScriptEnabled
public void setJavaScriptEnabled(boolean flag)- Specified by:
setJavaScriptEnabled
in classWebSettings
-
getLightTouchEnabled
public boolean getLightTouchEnabled()- Specified by:
getLightTouchEnabled
in classWebSettings
-
setLightTouchEnabled
public void setLightTouchEnabled(boolean flag)- Specified by:
setLightTouchEnabled
in classWebSettings
-
getNeedInitialFocus
public boolean getNeedInitialFocus() -
setNeedInitialFocus
public void setNeedInitialFocus(boolean flag)- Specified by:
setNeedInitialFocus
in classWebSettings
-
setRenderPriority
- Specified by:
setRenderPriority
in classWebSettings
-
getRenderPriority
-
getPluginsEnabled
public boolean getPluginsEnabled()- Specified by:
getPluginsEnabled
in classWebSettings
-
setPluginsEnabled
public void setPluginsEnabled(boolean flag)- Specified by:
setPluginsEnabled
in classWebSettings
-
getSupportMultipleWindows
public boolean getSupportMultipleWindows() -
setSupportMultipleWindows
public void setSupportMultipleWindows(boolean support)- Specified by:
setSupportMultipleWindows
in classWebSettings
-
getSupportZoom
public boolean getSupportZoom() -
setSupportZoom
public void setSupportZoom(boolean support)- Specified by:
setSupportZoom
in classWebSettings
-
setCacheMode
public void setCacheMode(int mode)- Specified by:
setCacheMode
in classWebSettings
-
getCacheMode
public int getCacheMode()- Specified by:
getCacheMode
in classWebSettings
-
getUseWideViewPort
public boolean getUseWideViewPort()- Specified by:
getUseWideViewPort
in classWebSettings
-
setUseWideViewPort
public void setUseWideViewPort(boolean useWideViewPort)- Specified by:
setUseWideViewPort
in classWebSettings
-
getSaveFormData
public boolean getSaveFormData()- Specified by:
getSaveFormData
in classWebSettings
-
setSaveFormData
public void setSaveFormData(boolean saveFormData)- Specified by:
setSaveFormData
in classWebSettings
-
setJavaScriptCanOpenWindowsAutomatically
public void setJavaScriptCanOpenWindowsAutomatically(boolean javaScriptCanOpenWindowAutomatically)- Specified by:
setJavaScriptCanOpenWindowsAutomatically
in classWebSettings
-
getJavaScriptCanOpenWindowsAutomatically
public boolean getJavaScriptCanOpenWindowsAutomatically()- Specified by:
getJavaScriptCanOpenWindowsAutomatically
in classWebSettings
-
setLayoutAlgorithm
- Specified by:
setLayoutAlgorithm
in classWebSettings
-
getDefaultTextEncodingName
- Specified by:
getDefaultTextEncodingName
in classWebSettings
-
setDefaultTextEncodingName
- Specified by:
setDefaultTextEncodingName
in classWebSettings
-
getDefaultFontSize
public int getDefaultFontSize()- Specified by:
getDefaultFontSize
in classWebSettings
-
setDefaultFontSize
public void setDefaultFontSize(int defaultFontSize)- Specified by:
setDefaultFontSize
in classWebSettings
-
getLoadsImagesAutomatically
public boolean getLoadsImagesAutomatically()- Specified by:
getLoadsImagesAutomatically
in classWebSettings
-
setLoadsImagesAutomatically
public void setLoadsImagesAutomatically(boolean loadsImagesAutomatically)- Specified by:
setLoadsImagesAutomatically
in classWebSettings
-
getDefaultFixedFontSize
public int getDefaultFixedFontSize()- Specified by:
getDefaultFixedFontSize
in classWebSettings
-
setDefaultFixedFontSize
public void setDefaultFixedFontSize(int defaultFixedFontSize)- Specified by:
setDefaultFixedFontSize
in classWebSettings
-
getMinimumLogicalFontSize
public int getMinimumLogicalFontSize()- Specified by:
getMinimumLogicalFontSize
in classWebSettings
-
setMinimumLogicalFontSize
public void setMinimumLogicalFontSize(int minimumLogicalFontSize)- Specified by:
setMinimumLogicalFontSize
in classWebSettings
-
getMinimumFontSize
public int getMinimumFontSize()- Specified by:
getMinimumFontSize
in classWebSettings
-
setMinimumFontSize
public void setMinimumFontSize(int minimumFontSize)- Specified by:
setMinimumFontSize
in classWebSettings
-
getFantasyFontFamily
- Specified by:
getFantasyFontFamily
in classWebSettings
-
setFantasyFontFamily
- Specified by:
setFantasyFontFamily
in classWebSettings
-
getCursiveFontFamily
- Specified by:
getCursiveFontFamily
in classWebSettings
-
setCursiveFontFamily
- Specified by:
setCursiveFontFamily
in classWebSettings
-
getSerifFontFamily
- Specified by:
getSerifFontFamily
in classWebSettings
-
setSerifFontFamily
- Specified by:
setSerifFontFamily
in classWebSettings
-
getSansSerifFontFamily
- Specified by:
getSansSerifFontFamily
in classWebSettings
-
setSansSerifFontFamily
- Specified by:
setSansSerifFontFamily
in classWebSettings
-
getFixedFontFamily
- Specified by:
getFixedFontFamily
in classWebSettings
-
setFixedFontFamily
- Specified by:
setFixedFontFamily
in classWebSettings
-
getStandardFontFamily
- Specified by:
getStandardFontFamily
in classWebSettings
-
setStandardFontFamily
- Specified by:
setStandardFontFamily
in classWebSettings
-
getLayoutAlgorithm
- Specified by:
getLayoutAlgorithm
in classWebSettings
-
supportMultipleWindows
public boolean supportMultipleWindows()- Specified by:
supportMultipleWindows
in classWebSettings
-
getSavePassword
public boolean getSavePassword()- Specified by:
getSavePassword
in classWebSettings
-
setSavePassword
public void setSavePassword(boolean savePassword)- Specified by:
setSavePassword
in classWebSettings
-
supportZoom
public boolean supportZoom()- Specified by:
supportZoom
in classWebSettings
-
getUserAgent
public int getUserAgent()- Specified by:
getUserAgent
in classWebSettings
-
setUserAgent
public void setUserAgent(int userAgent)- Specified by:
setUserAgent
in classWebSettings
-
getNavDump
public boolean getNavDump()- Specified by:
getNavDump
in classWebSettings
-
setNavDump
public void setNavDump(boolean navDump)- Specified by:
setNavDump
in classWebSettings
-
getAllowFileAccess
public boolean getAllowFileAccess()- Specified by:
getAllowFileAccess
in classWebSettings
-
setAllowFileAccess
public void setAllowFileAccess(boolean allow)- Specified by:
setAllowFileAccess
in classWebSettings
-
getBuiltInZoomControls
public boolean getBuiltInZoomControls()- Specified by:
getBuiltInZoomControls
in classWebSettings
-
setBuiltInZoomControls
public void setBuiltInZoomControls(boolean enabled)- Specified by:
setBuiltInZoomControls
in classWebSettings
-
setUserAgentString
- Specified by:
setUserAgentString
in classWebSettings
-
getUserAgentString
- Specified by:
getUserAgentString
in classWebSettings
-
getDatabaseEnabled
public boolean getDatabaseEnabled()- Specified by:
getDatabaseEnabled
in classWebSettings
-
setDatabaseEnabled
public void setDatabaseEnabled(boolean flag)- Specified by:
setDatabaseEnabled
in classWebSettings
-
setDatabasePath
- Specified by:
setDatabasePath
in classWebSettings
-
getDatabasePath
- Specified by:
getDatabasePath
in classWebSettings
-
getGeolocationDatabasePath
-
setGeolocationDatabasePath
- Specified by:
setGeolocationDatabasePath
in classWebSettings
-
getGeolocationEnabled
public boolean getGeolocationEnabled() -
setGeolocationEnabled
public void setGeolocationEnabled(boolean geolocationEnabled)- Specified by:
setGeolocationEnabled
in classWebSettings
-
setDefaultZoom
- Specified by:
setDefaultZoom
in classWebSettings
-
getDefaultZoom
- Specified by:
getDefaultZoom
in classWebSettings
-
getDomStorageEnabled
public boolean getDomStorageEnabled()- Specified by:
getDomStorageEnabled
in classWebSettings
-
setDomStorageEnabled
public void setDomStorageEnabled(boolean flag)- Specified by:
setDomStorageEnabled
in classWebSettings
-
getLoadWithOverviewMode
public boolean getLoadWithOverviewMode()- Specified by:
getLoadWithOverviewMode
in classWebSettings
-
setLoadWithOverviewMode
public void setLoadWithOverviewMode(boolean flag)- Specified by:
setLoadWithOverviewMode
in classWebSettings
-
getAppCacheEnabled
public boolean getAppCacheEnabled() -
setAppCacheEnabled
public void setAppCacheEnabled(boolean appCacheEnabled)- Specified by:
setAppCacheEnabled
in classWebSettings
-
setAppCacheMaxSize
public void setAppCacheMaxSize(long appCacheMaxSize)- Specified by:
setAppCacheMaxSize
in classWebSettings
-
getAppCacheMaxSize
public long getAppCacheMaxSize() -
getAppCachePath
-
setAppCachePath
- Specified by:
setAppCachePath
in classWebSettings
-
getBlockNetworkLoads
public boolean getBlockNetworkLoads()- Specified by:
getBlockNetworkLoads
in classWebSettings
-
setBlockNetworkLoads
public void setBlockNetworkLoads(boolean flag)- Specified by:
setBlockNetworkLoads
in classWebSettings
-
getPluginState
- Specified by:
getPluginState
in classWebSettings
-
setPluginState
- Specified by:
setPluginState
in classWebSettings
-
getUseWebViewBackgroundForOverscrollBackground
public boolean getUseWebViewBackgroundForOverscrollBackground()- Specified by:
getUseWebViewBackgroundForOverscrollBackground
in classWebSettings
-
setUseWebViewBackgroundForOverscrollBackground
public void setUseWebViewBackgroundForOverscrollBackground(boolean useWebViewBackgroundForOverscrollBackground)- Specified by:
setUseWebViewBackgroundForOverscrollBackground
in classWebSettings
-
enableSmoothTransition
public boolean enableSmoothTransition()- Specified by:
enableSmoothTransition
in classWebSettings
-
setEnableSmoothTransition
public void setEnableSmoothTransition(boolean enableSmoothTransition)- Specified by:
setEnableSmoothTransition
in classWebSettings
-
setAllowContentAccess
public void setAllowContentAccess(boolean allow)- Specified by:
setAllowContentAccess
in classWebSettings
-
getAllowContentAccess
public boolean getAllowContentAccess()- Specified by:
getAllowContentAccess
in classWebSettings
-
setDisplayZoomControls
public void setDisplayZoomControls(boolean enabled)- Specified by:
setDisplayZoomControls
in classWebSettings
-
getDisplayZoomControls
public boolean getDisplayZoomControls()- Specified by:
getDisplayZoomControls
in classWebSettings
-
getTextZoom
public int getTextZoom()- Specified by:
getTextZoom
in classWebSettings
-
setTextZoom
public void setTextZoom(int textZoom)- Specified by:
setTextZoom
in classWebSettings
-
getAllowFileAccessFromFileURLs
public boolean getAllowFileAccessFromFileURLs()- Specified by:
getAllowFileAccessFromFileURLs
in classWebSettings
-
setAllowFileAccessFromFileURLs
public void setAllowFileAccessFromFileURLs(boolean allow)- Specified by:
setAllowFileAccessFromFileURLs
in classWebSettings
-
getAllowUniversalAccessFromFileURLs
public boolean getAllowUniversalAccessFromFileURLs()- Specified by:
getAllowUniversalAccessFromFileURLs
in classWebSettings
-
setAllowUniversalAccessFromFileURLs
public void setAllowUniversalAccessFromFileURLs(boolean allow)- Specified by:
setAllowUniversalAccessFromFileURLs
in classWebSettings
-
getMediaPlaybackRequiresUserGesture
public boolean getMediaPlaybackRequiresUserGesture()- Specified by:
getMediaPlaybackRequiresUserGesture
in classWebSettings
-
setMediaPlaybackRequiresUserGesture
public void setMediaPlaybackRequiresUserGesture(boolean require)- Specified by:
setMediaPlaybackRequiresUserGesture
in classWebSettings
-
setMixedContentMode
public void setMixedContentMode(int mixedContentMode)- Specified by:
setMixedContentMode
in classWebSettings
-
getMixedContentMode
public int getMixedContentMode()- Specified by:
getMixedContentMode
in classWebSettings
-
setVideoOverlayForEmbeddedEncryptedVideoEnabled
public void setVideoOverlayForEmbeddedEncryptedVideoEnabled(boolean b)- Specified by:
setVideoOverlayForEmbeddedEncryptedVideoEnabled
in classWebSettings
-
getVideoOverlayForEmbeddedEncryptedVideoEnabled
public boolean getVideoOverlayForEmbeddedEncryptedVideoEnabled()- Specified by:
getVideoOverlayForEmbeddedEncryptedVideoEnabled
in classWebSettings
-
getAcceptThirdPartyCookies
public boolean getAcceptThirdPartyCookies()- Specified by:
getAcceptThirdPartyCookies
in classWebSettings
-
setAcceptThirdPartyCookies
public void setAcceptThirdPartyCookies(boolean acceptThirdPartyCookies)- Specified by:
setAcceptThirdPartyCookies
in classWebSettings
-
setOffscreenPreRaster
public void setOffscreenPreRaster(boolean enabled)- Specified by:
setOffscreenPreRaster
in classWebSettings
-
getOffscreenPreRaster
public boolean getOffscreenPreRaster()- Specified by:
getOffscreenPreRaster
in classWebSettings
-
getDisabledActionModeMenuItems
public int getDisabledActionModeMenuItems()- Specified by:
getDisabledActionModeMenuItems
in classWebSettings
-
setDisabledActionModeMenuItems
public void setDisabledActionModeMenuItems(int menuItems)- Specified by:
setDisabledActionModeMenuItems
in classWebSettings
-
getSafeBrowsingEnabled
public boolean getSafeBrowsingEnabled()- Specified by:
getSafeBrowsingEnabled
in classWebSettings
-
setSafeBrowsingEnabled
public void setSafeBrowsingEnabled(boolean enabled)- Specified by:
setSafeBrowsingEnabled
in classWebSettings
-
getForceDark
public int getForceDark()- Overrides:
getForceDark
in classWebSettings
-
setForceDark
public void setForceDark(int forceDark)- Overrides:
setForceDark
in classWebSettings
-