fix width/height detection for portrait screens

This commit is contained in:
Andrew Dolgov 2012-01-05 10:36:21 +03:00
parent ebb7bc07bf
commit c784d66394
2 changed files with 7 additions and 7 deletions

View File

@ -469,11 +469,11 @@ public class MainActivity extends FragmentActivity implements OnlineServices {
int height = display.getHeight();
if (height > width) {
int tmp = height;
width = tmp;
height = width;
int tmp = width;
width = height;
height = tmp;
}
m_smallScreenMode = m_compatMode || (width < 960 || height < 720);
setContentView(R.layout.main);

View File

@ -125,9 +125,9 @@ public class OfflineActivity extends FragmentActivity implements
int height = display.getHeight();
if (height > width) {
int tmp = height;
width = tmp;
height = width;
int tmp = width;
width = height;
height = tmp;
}
m_smallScreenMode = m_compatMode || (width < 960 || height < 720);