mirror of
https://ark.sudovanilla.org/Korbs/electron-tabs.git
synced 2024-12-23 03:53:53 +00:00
Change tabGroup.getTabById to tabGroup.getTab
This commit is contained in:
parent
ed9e63e92f
commit
b0534b9fc7
10
index.js
10
index.js
|
@ -67,15 +67,7 @@ class TabGroup extends EventEmitter {
|
||||||
return tab;
|
return tab;
|
||||||
}
|
}
|
||||||
|
|
||||||
getTab (id, idIsPosition) {
|
getTab (id) {
|
||||||
if (idIsPosition !== true) {
|
|
||||||
return this.getTabById(id);
|
|
||||||
} else {
|
|
||||||
return this.getTabByPosition(id);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
getTabById (id) {
|
|
||||||
for (let i in this.tabs) {
|
for (let i in this.tabs) {
|
||||||
if (this.tabs[i].id === id) {
|
if (this.tabs[i].id === id) {
|
||||||
return this.tabs[i];
|
return this.tabs[i];
|
||||||
|
|
Loading…
Reference in a new issue