eric6.Helpviewer.WebPlugins.ClickToFlash.ClickToFlash

Module implementing the Flash blocker.

Global Attributes

None

Classes

ClickToFlash Class implementing the Flash blocker.

Functions

None


ClickToFlash

Class implementing the Flash blocker.

Derived from

QWidget, Ui_ClickToFlash

Class Attributes

_acceptedArgNames
_acceptedArgValues
_acceptedUrl

Class Methods

isAlreadyAccepted Class method to check, if the given parameter combination is being accepted.

Methods

ClickToFlash Constructor
__addToWhitelist Private slot to add the host to the whitelist.
__checkElement Private slot to check an element against the saved arguments.
__checkUrlOnElement Private slot to check the URL of an element.
__configure Private slot to configure the whitelist.
__elide Private method to elide some text.
__findElement Private method to find the element belonging to this ClickToFlash instance.
__hideAdBlocked Private slot to hide the object.
__load Private slot to load the flash content.
__removeFromWhitelist Private slot to remove the host from the whitelist.
__showContextMenu Private slot to show the context menu.
__showInfo Private slot to show information about the blocked object.
on_loadFlashButton_clicked Private slot handling the flash activation.
swapping Public method to check, if the plug-in is swapping.

Static Methods

None

ClickToFlash.isAlreadyAccepted (class method)

isAlreadyAccepted(url, argumentNames, argumentValues)

Class method to check, if the given parameter combination is being accepted.

url
URL to be checked for (QUrl)
argumentNames
argument names to be checked for (list of strings)
argumentValues
argument values to be checked for (list of strings)
Returns:
flag indicating that this was already accepted (boolean)

ClickToFlash (Constructor)

ClickToFlash(plugin, mimeType, url, argumentNames, argumentValues, parent=None)

Constructor

plugin
reference to the plug-in (ClickToFlashPlugin)
mimeType
MIME type for the plug-in (string)
url
requested URL (QUrl)
argumentNames
list of argument names (list of strings)
argumentValues
list of argument values (list of strings)
parent
reference to the parent widget (QWidget)

ClickToFlash.__addToWhitelist

__addToWhitelist()

Private slot to add the host to the whitelist.

ClickToFlash.__checkElement

__checkElement(element)

Private slot to check an element against the saved arguments.

element
reference to the element to check (QWebElement)
Returns:
flag indicating a positive result (boolean)

ClickToFlash.__checkUrlOnElement

__checkUrlOnElement(element, view)

Private slot to check the URL of an element.

element
reference to the element to check (QWebElement)
view
reference to the view object (QWebView)
Returns:
flag indicating a positive result (boolean)

ClickToFlash.__configure

__configure()

Private slot to configure the whitelist.

ClickToFlash.__elide

__elide(txt, mode=Qt.ElideMiddle, length=40)

Private method to elide some text.

txt
text to be elided (string)
mode=
elide mode (Qt.TextElideMode)
length=
amount of characters to be used (integer)
Returns:
the elided text (string)

ClickToFlash.__findElement

__findElement()

Private method to find the element belonging to this ClickToFlash instance.

ClickToFlash.__hideAdBlocked

__hideAdBlocked()

Private slot to hide the object.

ClickToFlash.__load

__load(allPlayers=False)

Private slot to load the flash content.

allPlayers
flag indicating to load all flash players (boolean)

ClickToFlash.__removeFromWhitelist

__removeFromWhitelist()

Private slot to remove the host from the whitelist.

ClickToFlash.__showContextMenu

__showContextMenu()

Private slot to show the context menu.

ClickToFlash.__showInfo

__showInfo()

Private slot to show information about the blocked object.

ClickToFlash.on_loadFlashButton_clicked

on_loadFlashButton_clicked()

Private slot handling the flash activation.

ClickToFlash.swapping

swapping()

Public method to check, if the plug-in is swapping.

Returns:
flag indicating the swapping status (boolean)
Up