mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
feat: emit devtools-open-url event for DevTools link selection (#36774)
* feat: emit event for DevTools link selection * chore: devtools-open-in-new-tab -> devtools-open-url
This commit is contained in:
@@ -723,7 +723,10 @@ void InspectableWebContents::SetIsDocked(DispatchCallback callback,
|
||||
std::move(callback).Run(nullptr);
|
||||
}
|
||||
|
||||
void InspectableWebContents::OpenInNewTab(const std::string& url) {}
|
||||
void InspectableWebContents::OpenInNewTab(const std::string& url) {
|
||||
if (delegate_)
|
||||
delegate_->DevToolsOpenInNewTab(url);
|
||||
}
|
||||
|
||||
void InspectableWebContents::ShowItemInFolder(
|
||||
const std::string& file_system_path) {
|
||||
|
||||
@@ -31,6 +31,7 @@ class InspectableWebContentsDelegate {
|
||||
virtual void DevToolsIndexPath(int request_id,
|
||||
const std::string& file_system_path,
|
||||
const std::string& excluded_folders) {}
|
||||
virtual void DevToolsOpenInNewTab(const std::string& url) {}
|
||||
virtual void DevToolsStopIndexing(int request_id) {}
|
||||
virtual void DevToolsSearchInPath(int request_id,
|
||||
const std::string& file_system_path,
|
||||
|
||||
Reference in New Issue
Block a user