fix: deprecate setLayoutZoomLevelLimits (#21296)
This commit is contained in:
parent
c7cbc2e6b1
commit
9526c5584e
14 changed files with 24 additions and 110 deletions
|
@ -2316,15 +2316,6 @@ double WebContents::GetZoomFactor() const {
|
|||
return blink::PageZoomLevelToZoomFactor(level);
|
||||
}
|
||||
|
||||
void WebContents::SetZoomLimits(double min_zoom, double max_zoom) {
|
||||
// Round the double to avoid returning incorrect minimum/maximum zoom
|
||||
// percentages.
|
||||
int minimum_percent = round(blink::PageZoomLevelToZoomFactor(min_zoom) * 100);
|
||||
int maximum_percent = round(blink::PageZoomLevelToZoomFactor(max_zoom) * 100);
|
||||
web_contents()->SetMinimumZoomPercent(minimum_percent);
|
||||
web_contents()->SetMaximumZoomPercent(maximum_percent);
|
||||
}
|
||||
|
||||
void WebContents::SetTemporaryZoomLevel(double level) {
|
||||
zoom_controller_->SetTemporaryZoomLevel(level);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue