chore: remove ancient Browser::Focus implementation on Windows (#27279)
This commit is contained in:
parent
0599487e65
commit
cd42933f41
3 changed files with 12 additions and 29 deletions
|
@ -64,6 +64,18 @@ Browser* Browser::Get() {
|
|||
return ElectronBrowserMainParts::Get()->browser();
|
||||
}
|
||||
|
||||
#if defined(OS_WIN) || defined(OS_LINUX)
|
||||
void Browser::Focus(gin::Arguments* args) {
|
||||
// Focus on the first visible window.
|
||||
for (auto* const window : WindowList::GetWindows()) {
|
||||
if (window->IsVisible()) {
|
||||
window->Focus(true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
void Browser::Quit() {
|
||||
if (is_quiting_)
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue