getSelected method

  1. @Deprecated(r'Please use $(ref:tabs.query) <code>{active: true}</code>.')
Future<Tab> getSelected(
  1. int? windowId
)

Gets the tab that is selected in the specified window. windowId Defaults to the current window.

Implementation

@Deprecated(r'Please use $(ref:tabs.query) <code>{active: true}</code>.')
Future<Tab> getSelected(int? windowId) async {
  var $res =
      await promiseToFuture<$js.Tab>($js.chrome.tabs.getSelected(windowId));
  return Tab.fromJS($res);
}