winrt: Add camera focus and focus lock controls

[ChangLog][multimedia][winrt] The winrt backend now supports camera focus
and focus lock for Windows Phone.

Task-Id: QTBUG-46120
Change-Id: Idb222798284d887a6e90a4986c69274e0ef765f5
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
This commit is contained in:
Peng Wu
2015-08-06 16:33:39 +03:00
committed by Andrew Knight
parent ef3695a009
commit 5cec451c10
10 changed files with 1003 additions and 27 deletions

View File

@@ -179,6 +179,7 @@ int QWinRTCameraImageCaptureControl::capture(const QString &fileName)
qErrnoWarning("Camera photo capture failed.");
return -1;
}
emit captureQueueChanged(false);
d->requests.insert(request.op.Get(), request);
hr = request.op->put_Completed(Callback<IAsyncActionCompletedHandler>(
@@ -199,6 +200,7 @@ void QWinRTCameraImageCaptureControl::cancelCapture()
info->Cancel();
it = d->requests.erase(it);
}
emit captureQueueChanged(true);
}
HRESULT QWinRTCameraImageCaptureControl::onCaptureCompleted(IAsyncAction *asyncInfo, AsyncStatus status)
@@ -209,7 +211,7 @@ HRESULT QWinRTCameraImageCaptureControl::onCaptureCompleted(IAsyncAction *asyncI
return S_OK;
CaptureRequest request = d->requests.take(asyncInfo);
emit captureQueueChanged(d->requests.isEmpty());
HRESULT hr;
if (status == Error) {
hr = asyncInfo->GetResults();