Cygwin快速镜像站点

参考:http://lj6684.javaeye.com/blog/660665

只配置NDK目录貌似还不够,所以又准备装cygwin了,

直接下载的话太慢,

搜了一下镜像地址,结果找到了(以前看到过,记不清了又找了一次)

选择从互联网安装,在“User URL”处输入以下地址
http://mirrors.163.com/cygwin/
点击Add按钮,然后选中"http://mirrors.163.com/cygwin"点击下一步进行安装

速度挺快

NDK环境超级简单配置方式

ndk超级简单配置方法:把最新windows版的ndk包解压,然后在系统环境变量path填上解压路径,好了,完成。(其实我只想说网上一个抄一个的教程说不定就是骗人的,不是骗人的可能也是过时的,他妹的我安了两天的Cygwin,这才发现关Cygwin毛事!)

菜鸟了,见笑了

Android向桌面添加快捷方式,使其指向特定的网页


出处:http://www.cnblogs.com/wanyao/archive/2011/11/27/2265333.html




/*


          * 在桌面添加快捷方式


          * @param      icon         快捷方式图标


          * @param      name      快捷方式名称


          * @param      uri           快捷方式的intent Uri


          */


         public void addShortcut(Parcelable icon, String name, Uri uri){


                   Intent intentAddShortcut = new Intent(ACTION_ADD_SHORTCUT);


                   //添加名称


                   intentAddShortcut.putExtra(Intent.EXTRA_SHORTCUT_NAME, name);


                   //添加图标


                   intentAddShortcut.putExtra(Intent.EXTRA_SHORTCUT_ICON_RESOURCE, icon);


                   //设置Launcher的Uri数据


                   Intent intentLauncher = new Intent();


                   intentLauncher.setData(uri);


                   //添加快捷方式的启动方法


                   intentAddShortcut.putExtra(Intent.EXTRA_SHORTCUT_INTENT, intentLauncher);


                   sendBroadcast(intentAddShortcut);


         }


当然,你还需要添加一个permission


<uses-permission android:name="com.android.launcher.permission.INSTALL_SHORTCUT" />


这里第一个参数Parcelable类型的icon如何获得呢,以下举个例子从Drawable文件夹中获取图片。


Parcelable icon = Intent.ShortcutIconResource.fromContext(this, R.drawable.icon);




Android如何调用系统默认浏览器访问


一、启动android默认浏览器



Intent intent= new Intent();


  intent.setAction("android.intent.action.VIEW");


  Uri content_url = Uri.parse("http://www.cxybl.com");


  intent.setData(content_url);


  startActivity(intent);


这样子,android就可以调用起手机默认的浏览器访问。


二、指定相应的浏览器访问


1、指定android自带的浏览器访问


( “com.android.browser”:packagename   ;“com.android.browser.BrowserActivity”:启动主activity)


                Intent intent= new Intent();


                intent.setAction("android.intent.action.VIEW");


                Uri content_url = Uri.parse("http://www.cxybl.com");


                intent.setData(content_url);


                intent.setClassName("com.android.browser","com.android.browser.BrowserActivity");


                startActivity(intent);


奇葩方式打开win8.1 ahci

进安全模式的,右键点开始-运行-msconfig-引导,勾上“安全引导”,重启,进bios中改为ahci,保存退出bios,重启就进入了win8的安全模式,然后再进msconfig中勾掉“安全引导”,再重启,看看是不是能正常进去win8了?