1/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 2/* This Source Code Form is subject to the terms of the Mozilla Public 3 * License, v. 2.0. If a copy of the MPL was not distributed with this 4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 5 6#include "nsISupports.idl" 7#include "nsIFile.idl" 8 9[scriptable, uuid(32d35d21-181f-4630-8caa-a431e2ebad72)] 10interface mozIGeckoMediaPluginChromeService : nsISupports 11{ 12 /** 13 * Add a directory to scan for gecko media plugins. 14 * @note Main-thread API. 15 */ 16 void addPluginDirectory(in AString directory); 17 18 /** 19 * Remove a directory for gecko media plugins. 20 * @note Main-thread API. 21 */ 22 void removePluginDirectory(in AString directory); 23 24 /** 25 * Remove a directory for gecko media plugins and delete it from disk. 26 * If |defer| is true, wait until the plugin is unused before removing. 27 * @note Main-thread API. 28 */ 29 void removeAndDeletePluginDirectory(in AString directory, 30 [optional] in bool defer); 31 32 /** 33 * Clears storage data associated with the site and the originAttributes 34 * pattern in JSON format. 35 */ 36 void forgetThisSite(in AString site, 37 in AString aPattern); 38 39 /** 40 * Returns true if the given node id is allowed to store things 41 * persistently on disk. Private Browsing and local content are not 42 * allowed to store persistent data. 43 */ 44 bool isPersistentStorageAllowed(in ACString nodeId); 45 46 /** 47 * Returns the directory to use as the base for storing data about GMPs. 48 */ 49 nsIFile getStorageDir(); 50 51}; 52