Force proper screen orientation, that was broken in my last few commits

This commit is contained in:
pelya
2012-06-18 13:10:27 +03:00
parent e38ade1e6b
commit 0e1a4897c1
4 changed files with 8 additions and 5 deletions

View File

@@ -69,12 +69,15 @@ import android.content.pm.PackageManager;
import android.os.Handler;
import android.os.Message;
import java.util.concurrent.Semaphore;
import android.content.pm.ActivityInfo;
public class MainActivity extends Activity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setRequestedOrientation(Globals.HorizontalOrientation ? ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE : ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);
instance = this;
// fullscreen mode
requestWindowFeature(Window.FEATURE_NO_TITLE);