For the example desktop-capture there is a function named chooseDesktopMedia which is used actually like that :
chrome.desktopCapture. chooseDesktopMedia(['screen'], callback(param))
I think this should be better if we have a future and use the function like this
chrome.desktopCapture.chooseDesktopMedia(['screen']).then((param) {
print("do something");
});