I had this problem as well as I wanted to constrain my game to only landscape mode. I put this in my OnLaunched handler for App.xaml:

Windows.Graphics.Display.DisplayProperties.AutoRotationPreferences=Windows.Graphics.Display.DisplayOrientations.Landscape;

However I noted that in the simulator it seemed to ignore this whereas on the hardware tablet I tested on it seemed to behave appropriately. The AutoRotationPreferences are bit flags so you can or together all the orientations you want to allow.

from : http://stackoverflow.com/questions/12614508/how-to-limit-orientation-in-metro-apps

Disable Portrait in app的更多相关文章

  1. puppeteer(五)chrome启动参数列表API

    List of Chromium Command Line Switches https://peter.sh/experiments/chromium-command-line-switches/ ...

  2. CEF 支持的命令行参数

    参考:https://peter.sh/experiments/chromium-command-line-switches/ List of Chromium Command Line Switch ...

  3. Capabilities & ChromeOptions

    https://sites.google.com/a/chromium.org/chromedriver/capabilities http://stackoverflow.com/questions ...

  4. List of Chromium Command Line Switches(命令行开关集)——官方指定命令行更新网址

    转自:http://peter.sh/experiments/chromium-command-line-switches/ There are lots of command lines which ...

  5. chromedriver中的浏览器选项

    There are lots of command lines which can be used with the Google Chrome browser. Some change behavi ...

  6. 【Bootstrap-插件使用】Jcrop+fileinput组合实现头像上传功能

    作者:Dreawer链接:https://zhuanlan.zhihu.com/p/24465742来源:知乎著作权归作者所有.商业转载请联系作者获得授权,非商业转载请注明出处. 作者:梦游的龙猫(转 ...

  7. node工具--express

    //使用supervisor  Connect是基于HTTP米快创建的:Express则是基于Connect上创建的: 绝大多数web服务器和浏览器之间的任务是通过url和method完成的,两者的组 ...

  8. Nodejs Express 4.X 中文API 1--- Application篇

    相关阅读: Express 4.X API 翻译[一] --  Application篇 Express4.XApi 翻译[二] --  Request篇 Express4.XApi 翻译[三] -- ...

  9. -fembed-bitcode is not supported on versions of iOS prior to 6.0

    -fembed-bitcode is not supported on versions of iOS prior to 6.0   说法二 错误提示 -fembed-bitcode is not s ...

随机推荐

  1. (转载整理)SAP ERP常用表

    abap 常用表 GL部分:FAGLFLEXT(FMGLFLEXT)   新总账汇总表 GLT0        旧总帐汇总表           SKA1        总账科目主记录 (科目表)   ...

  2. 转载 网页打印时设置A4大小

    最近开发项目时遇到了网页打印的问题,这是问题之二,打印宽度设置 在公制长度单位与屏幕分辨率进行换算时,必须用到一个DPI(Dot Per Inch)指标. 经过我仔细的测试,发现了网页打印中,默认采用 ...

  3. 转:PHP Composer 管理工具的介绍 这个相对清晰点

    转自:http://www.aichengxu.com/view/14872 一.PHP的一些臭历史 Dependency Manager For PHP,Composer.在Composer还没诞生 ...

  4. Java 多线程中run() 与 start() 的不同

    区别:调用start方法实现多线程,而调用run方法没有实现多线程 Start: 用start方法来启动线程,真正实现了多线程运行,这时无需等待run方法体代码执行完毕而直接继续执行下面的代码.通过调 ...

  5. spring MVC 详细入门

    移步到这里:http://www.admin10000.com/document/6436.html

  6. Android ClearEditText:输入用户名、密码错误时整体删除及输入为空时候晃动提示

    package com.lixu.clearedittext; import android.app.Activity; import android.os.Bundle; import androi ...

  7. Program B--CodeForces 492B

    Description Vanya walks late at night along a straight street of length l, lit by n lanterns. Consid ...

  8. Android 插入图片到媒体库

    今天介绍一下在Android中怎么插入图片到媒体库,下面看代码: final String titleName = Function.md5(imageUri.toLowerCase()) + &qu ...

  9. SQL语句查询所耗时间与效能的语句

    1)SQL查询所耗时间语句 原理:记录当前时间1,执行SQL语句,记录当前时间2,显示时间2与时间1的差. 由于第一次执行的所耗时间为真实时间,之后会保存在缓存中,所以第二次之后的查询所耗时间都会比第 ...

  10. SQL Server 语句整理

    1. 创建数据库 create database dbName 2. 删除数据库 drop database dbName 3. 备份sql server --- 创建 备份数据的 device US ...