зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1387802 - Remove [deprecated] methods from nsITaskbarPreviewController. r=jimm
MozReview-Commit-ID: 25cdKHqVLSh --HG-- extra : rebase_source : f2dc739ad0f132cb1cc764cfa3ec11e83cbfa0c3
This commit is contained in:
Родитель
98f202e7d8
Коммит
e1f76e8883
|
@ -37,29 +37,23 @@ interface nsITaskbarPreviewController : nsISupports
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* The width of the preview image. This value is allowed to change at any
|
* 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;
|
readonly attribute unsigned long width;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The height of the preview image. This value is allowed to change at any
|
* 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;
|
readonly attribute unsigned long height;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The aspect ratio of the thumbnail - this does not need to match the ratio
|
* 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
|
* 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;
|
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.
|
* Invoked by nsITaskbarPreview when it needs to render the preview.
|
||||||
*
|
*
|
||||||
|
@ -70,9 +64,6 @@ interface nsITaskbarPreviewController : nsISupports
|
||||||
void requestPreview(in nsITaskbarPreviewCallback aCallback);
|
void requestPreview(in nsITaskbarPreviewCallback aCallback);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* An asynchronous version of drawPreview and drawThumbnail apis
|
|
||||||
* implemented in nsITaskbarPreviewController.
|
|
||||||
*
|
|
||||||
* Note: it is guaranteed that width/height == thumbnailAspectRatio
|
* Note: it is guaranteed that width/height == thumbnailAspectRatio
|
||||||
* (modulo rounding errors)
|
* (modulo rounding errors)
|
||||||
*
|
*
|
||||||
|
|
|
@ -20,8 +20,8 @@ interface nsITaskbarPreviewButton;
|
||||||
*
|
*
|
||||||
* By default, Windows takes care of drawing the thumbnail and preview for the
|
* By default, Windows takes care of drawing the thumbnail and preview for the
|
||||||
* application however if enableCustomDrawing is set to true, then the
|
* application however if enableCustomDrawing is set to true, then the
|
||||||
* controller will start to receive drawPreview and drawThumbnail calls as well
|
* controller will start to receive requestPreview and requestThumbnail calls
|
||||||
* as reads on the thumbnailAspectRatio, width and height properties.
|
* as well as reads on the thumbnailAspectRatio, width and height properties.
|
||||||
*
|
*
|
||||||
* By default, nsITaskbarWindowPreviews are visible. When made invisible, the
|
* By default, nsITaskbarWindowPreviews are visible. When made invisible, the
|
||||||
* window disappears from the list of windows in the taskbar for the
|
* window disappears from the list of windows in the taskbar for the
|
||||||
|
|
|
@ -50,8 +50,6 @@
|
||||||
width: 400,
|
width: 400,
|
||||||
height: 400,
|
height: 400,
|
||||||
thumbnailAspectRatio: 1.0,
|
thumbnailAspectRatio: 1.0,
|
||||||
drawThumbnail: function () { return false; },
|
|
||||||
drawPreview: function () { return false; },
|
|
||||||
get wrappedJSObject() { return this; }
|
get wrappedJSObject() { return this; }
|
||||||
}
|
}
|
||||||
// HACK from mconnor:
|
// HACK from mconnor:
|
||||||
|
|
|
@ -143,20 +143,6 @@ DefaultController::GetThumbnailAspectRatio(float *aThumbnailAspectRatio) {
|
||||||
return NS_OK;
|
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
|
NS_IMETHODIMP
|
||||||
DefaultController::RequestThumbnail(nsITaskbarPreviewCallback *aCallback, uint32_t width, uint32_t height) {
|
DefaultController::RequestThumbnail(nsITaskbarPreviewCallback *aCallback, uint32_t width, uint32_t height) {
|
||||||
return NS_OK;
|
return NS_OK;
|
||||||
|
|
Загрузка…
Ссылка в новой задаче