set zoom mode to contentwidth after rotating screen to landscape

As most pages are portrait there is no reason to fit "portrait" page
on "landscape" screen. And "pagewidth" is used less often than "contentwidth".
So "contentwidth" is choosed to set zoom mode on landscape screen.
pull/2/merge
chrox 11 years ago
parent 9efdefb22f
commit 85dafd6e25

@ -138,6 +138,10 @@ function ReaderView:onSetScreenMode(new_mode)
Screen:setScreenMode(new_mode)
self.ui:handleEvent(Event:new("SetDimensions", Screen:getSize()))
end
if new_mode == "landscape" and self.document.info.has_pages then
self.ui:handleEvent(Event:new("SetZoomMode", "contentwidth"))
end
return true
end

Loading…
Cancel
Save