FileDocCategorySizeDatePackage
PluginList.javaAPI DocAndroid 5.1 API3291Thu Mar 12 22:22:10 GMT 2015android.webkit

PluginList

public class PluginList extends Object
A simple list of initialized plugins. This list gets populated when the plugins are initialized (at browser startup, at the moment).
hide
deprecated
This interface was intended to be used by Gears. Since Gears was deprecated, so is this class.

Fields Summary
private ArrayList
mPlugins
Constructors Summary
public PluginList()
Public constructor. Initializes the list of plugins.

hide
deprecated
This interface was intended to be used by Gears. Since Gears was deprecated, so is this class.

        mPlugins = new ArrayList<Plugin>();
    
Methods Summary
public synchronized voidaddPlugin(Plugin plugin)
Adds a plugin to the list.

hide
deprecated
This interface was intended to be used by Gears. Since Gears was deprecated, so is this class.

        if (!mPlugins.contains(plugin)) {
            mPlugins.add(plugin);
        }
    
public synchronized voidclear()
Clears the plugin list.

hide
deprecated
This interface was intended to be used by Gears. Since Gears was deprecated, so is this class.

        mPlugins.clear();
    
public synchronized java.util.ListgetList()
Returns the list of plugins as a java.util.List.

hide
deprecated
This interface was intended to be used by Gears. Since Gears was deprecated, so is this class.

        return mPlugins;
    
public synchronized voidpluginClicked(android.content.Context context, int position)
Dispatches the click event to the appropriate plugin.

hide
deprecated
This interface was intended to be used by Gears. Since Gears was deprecated, so is this class.

        try {
            Plugin plugin = mPlugins.get(position);
            plugin.dispatchClickEvent(context);
        } catch (IndexOutOfBoundsException e) {
            // This can happen if the list of plugins
            // gets changed while the pref menu is up.
        }
    
public synchronized voidremovePlugin(Plugin plugin)
Removes a plugin from the list.

hide
deprecated
This interface was intended to be used by Gears. Since Gears was deprecated, so is this class.

        int location = mPlugins.indexOf(plugin);
        if (location != -1) {
            mPlugins.remove(location);
        }