Bug 1387802 - Remove [deprecated] methods from nsITaskbarPreviewController. r=jimm

MozReview-Commit-ID: 25cdKHqVLSh

--HG--
extra : rebase_source : f2dc739ad0f132cb1cc764cfa3ec11e83cbfa0c3
This commit is contained in:
Masatoshi Kimura 2017-08-06 13:35:02 +09:00
Родитель 98f202e7d8
Коммит e1f76e8883
4 изменённых файлов: 5 добавлений и 30 удалений

Просмотреть файл

@ -37,29 +37,23 @@ interface nsITaskbarPreviewController : nsISupports
{
/**
* The width of the preview image. This value is allowed to change at any
* time. See drawPreview for more information.
* time. See requestPreview for more information.
*/
readonly attribute unsigned long width;
/**
* The height of the preview image. This value is allowed to change at any
* time. See drawPreview for more information.
* time. See requestPreview for more information.
*/
readonly attribute unsigned long height;
/**
* The aspect ratio of the thumbnail - this does not need to match the ratio
* of the preview. This value is allowed to change at any time. See
* drawThumbnail for more information.
* requestThumbnail for more information.
*/
readonly attribute float thumbnailAspectRatio;
[deprecated]
boolean drawPreview(in nsISupports ctx);
[deprecated]
boolean drawThumbnail(in nsISupports ctx, in unsigned long width, in unsigned long height);
/**
* Invoked by nsITaskbarPreview when it needs to render the preview.
*
@ -70,9 +64,6 @@ interface nsITaskbarPreviewController : nsISupports
void requestPreview(in nsITaskbarPreviewCallback aCallback);
/**
* An asynchronous version of drawPreview and drawThumbnail apis
* implemented in nsITaskbarPreviewController.
*
* Note: it is guaranteed that width/height == thumbnailAspectRatio
* (modulo rounding errors)
*

Просмотреть файл

@ -20,8 +20,8 @@ interface nsITaskbarPreviewButton;
*
* By default, Windows takes care of drawing the thumbnail and preview for the
* application however if enableCustomDrawing is set to true, then the
* controller will start to receive drawPreview and drawThumbnail calls as well
* as reads on the thumbnailAspectRatio, width and height properties.
* controller will start to receive requestPreview and requestThumbnail calls
* as well as reads on the thumbnailAspectRatio, width and height properties.
*
* By default, nsITaskbarWindowPreviews are visible. When made invisible, the
* window disappears from the list of windows in the taskbar for the

Просмотреть файл

@ -50,8 +50,6 @@
width: 400,
height: 400,
thumbnailAspectRatio: 1.0,
drawThumbnail: function () { return false; },
drawPreview: function () { return false; },
get wrappedJSObject() { return this; }
}
// HACK from mconnor:

Просмотреть файл

@ -143,20 +143,6 @@ DefaultController::GetThumbnailAspectRatio(float *aThumbnailAspectRatio) {
return NS_OK;
}
// deprecated
NS_IMETHODIMP
DefaultController::DrawPreview(nsISupports *ctx, bool *rDrawFrame) {
*rDrawFrame = true;
return NS_ERROR_UNEXPECTED;
}
// deprecated
NS_IMETHODIMP
DefaultController::DrawThumbnail(nsISupports *ctx, uint32_t width, uint32_t height, bool *rDrawFrame) {
*rDrawFrame = false;
return NS_ERROR_UNEXPECTED;
}
NS_IMETHODIMP
DefaultController::RequestThumbnail(nsITaskbarPreviewCallback *aCallback, uint32_t width, uint32_t height) {
return NS_OK;