feat: add BrowserWindow.isTabletMode API (#25209)
This commit is contained in:
parent
2dd7ad268b
commit
c50ded2b71
7 changed files with 32 additions and 0 deletions
|
@ -622,6 +622,10 @@ bool BaseWindow::IsKiosk() {
|
|||
return window_->IsKiosk();
|
||||
}
|
||||
|
||||
bool BaseWindow::IsTabletMode() const {
|
||||
return window_->IsTabletMode();
|
||||
}
|
||||
|
||||
void BaseWindow::SetBackgroundColor(const std::string& color_name) {
|
||||
SkColor color = ParseHexColor(color_name);
|
||||
window_->SetBackgroundColor(color);
|
||||
|
@ -1160,6 +1164,7 @@ void BaseWindow::BuildPrototype(v8::Isolate* isolate,
|
|||
.SetMethod("isSimpleFullScreen", &BaseWindow::IsSimpleFullScreen)
|
||||
.SetMethod("setKiosk", &BaseWindow::SetKiosk)
|
||||
.SetMethod("isKiosk", &BaseWindow::IsKiosk)
|
||||
.SetMethod("isTabletMode", &BaseWindow::IsTabletMode)
|
||||
.SetMethod("setBackgroundColor", &BaseWindow::SetBackgroundColor)
|
||||
.SetMethod("getBackgroundColor", &BaseWindow::GetBackgroundColor)
|
||||
.SetMethod("setHasShadow", &BaseWindow::SetHasShadow)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue