Skip to content

Commit

Permalink
Fix image jumping out of view during on-screen keyboard popup
Browse files Browse the repository at this point in the history
On Android device, when the text tool is used in the lower portion of
image, on-screen keyboard that pops up moves edited picture out of view.
Picture thus cannot be seen by the user and the text field is placed
outside the picture. This fixes this behavior.

Fix #187
  • Loading branch information
crmtestresco committed Oct 18, 2023
1 parent d202116 commit fa35d56
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion js/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -1261,7 +1261,7 @@ class PainterroProc {

adjustSizeFull() {
const ratio = this.wrapper.documentClientWidth / this.wrapper.documentClientHeight;
if (this.zoom === false) {
if (this.zoom === false && this.textTool.active === false) {
if (this.size.w > this.wrapper.documentClientWidth ||
this.size.h > this.wrapper.documentClientHeight) {
const newRelation = ratio < this.size.ratio;
Expand Down

0 comments on commit fa35d56

Please sign in to comment.