0

I have a problem with this firebase shared drawing app. Its github url is https://github.com/firebase/AndroidDrawing.

The problem is the screen horizontally isn't complete when on the Drawing Activity. I think it because of the BoardWidth in the Drawing activity java file. But am not sure and the code is too difficult to read.

Is there anyway I can fix the problem?

enter image description here

Frank van Puffelen
  • 565,676
  • 79
  • 828
  • 807
  • i didn't use it, but i think you will fix it, with, [reconnect with firebase when it lost connection], o maybe detect when app change orientation and check the connection with firesabe link: https://stackoverflow.com/questions/11351689/detect-if-firebase-connection-is-lost-regained – DarckBlezzer Jul 24 '17 at 23:38
  • the problem is not the connection, its the mBoardwidth or the width or the board..even when its connected the screen layout of the board is incomplete....but the vertical layout is. – Phulula Sibindlana Jul 24 '17 at 23:46

1 Answers1

0

The width and height of each board are determined by the device on which the board is created. When showing an existing board on a device, it is drawn to match with the width and height of the current device in its current orientation.

The board you are drawing on was created when your device (or a device with a similar aspect ratio) as in portrait mode, while you're now drawing on it in landscape mode.

For the best experience, create the board while you're hold the device in the orientation you want to use while drawing.

Frank van Puffelen
  • 565,676
  • 79
  • 828
  • 807