Skip to content

catch media stream error, set canvas height/width from offsetHeight/width#3

Open
elmarti wants to merge 3 commits into
IagoLast:masterfrom
elmarti:master
Open

catch media stream error, set canvas height/width from offsetHeight/width#3
elmarti wants to merge 3 commits into
IagoLast:masterfrom
elmarti:master

Conversation

@elmarti
Copy link
Copy Markdown

@elmarti elmarti commented Dec 8, 2016

Tested with set height/width attributes and without

@elmarti elmarti mentioned this pull request Dec 8, 2016
@elmarti
Copy link
Copy Markdown
Author

elmarti commented Dec 8, 2016

#1
#2

I messed up the actual commit
Comment thread src/qr-code.js Outdated
this._width = this._video.width;
this._height = this._video.height;
this._video = this._createVideoElement(videoSelector);
this._width = this._video.offsetWidth;
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

offsetWidth is only working on chrome, can you change this and use clientWidth instead? same for height

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, no problem, i'll update in a couple of hours

@elmarti
Copy link
Copy Markdown
Author

elmarti commented Dec 9, 2016

Resolved and tested on Firefox and Chrome

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants