Skip to content

Commit

Permalink
Fixes for iPad
Browse files Browse the repository at this point in the history
  • Loading branch information
Björn Nilsson committed Dec 23, 2010
1 parent 76a20e1 commit 5d61bb5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 9 deletions.
9 changes: 3 additions & 6 deletions js/init.js
Expand Up @@ -200,12 +200,9 @@
orbium.pane.style.width = ""+orbium.width+"px";
orbium.pane.style.height = ""+orbium.height+"px";

// Use translate3d if webkitTransform is available
// and we are running on 4th gen iOS device.
// Chrome supports this but is unstable, so do not use yet
if (orbium.pane.style.webkitTransform !== undefined &&
orbium.Util.isUA("iPhone") &&
orbium.Util.getDevicePixelRatio() === 2) {
// Use translate3d on 4th gen iOS device and on iPad only
if ((orbium.Util.isUA("iPhone") && orbium.Util.getDevicePixelRatio() === 2) ||
orbium.Util.isUA("iPad")) {
orbium.has_transform = true;

orbium.pane.style.webkitTransform = "translate3d("+
Expand Down
2 changes: 1 addition & 1 deletion js/menu.js
Expand Up @@ -974,7 +974,7 @@
};

this.appstore = function() {
if (orbium.Util.isUA("iPhone")) {
if (orbium.Util.isUA("iPhone") || orbium.Util.isUA("iPad")) {
window.location.href = "http://itunes.apple.com/us/app/orbium/id376402382?mt=8";
} else if (orbium.Util.isUA("webOS")) {
window.location.href = "http://developer.palm.com/webChannel/index.php?packageid=se.jsway.orbium";
Expand Down
4 changes: 2 additions & 2 deletions js/player.js
Expand Up @@ -18,7 +18,7 @@
supportsMP3 = false;
supportsOGG = false;

if (orbium.Util.isPG() && orbium.Util.isUA("iPhone")) {
if (orbium.Util.isPG() && (orbium.Util.isUA("iPhone") || orbium.Util.isUA("iPad"))) {
supportsSPP = true;
} else if (orbium.Util.isPG()) {
supportsPGM = true;
Expand Down Expand Up @@ -59,7 +59,7 @@
}

// Disable sounds on certain devices and cases that are problematic
if ((orbium.Util.isUA("iPhone") && !orbium.Util.isPG()) ||
if (((orbium.Util.isUA("iPhone") || orbium.Util.isUA("iPad")) && !orbium.Util.isPG()) ||
orbium.Util.isUA("webOS") ||
orbium.Util.isUA("Android") ||
orbium.Util.isUA("MSIE") ||
Expand Down

0 comments on commit 5d61bb5

Please sign in to comment.