Time of Update: 2018-12-04
原文地址::http://blog.csdn.net/andy_android/article/details/7242086 前言:最近開始研究Android自動化測試方法,對其中的一些工具、方法和架構做了一些簡單的整理,其中包括android測試架構、CTS、Monkey、Monkeyrunner、benchmark、其它test tool等等。因接觸時間很短,很多地方有不足之處,希望能和大家多多交流。 一、
Time of Update: 2018-12-04
原文地址::http://blog.csdn.net/andy_android/article/details/7288073 BusyBox 是一個整合了一百多個最常用linux命令和工具的軟體。BusyBox 包含了一些簡單的工具,例如ls、 cat 和 echo等等,還包含了一些更大、更複雜的工具,例如 grep、find、mount 以及 telnet。有些人將 BusyBox 稱為 Linux 工具裡的瑞士軍刀。簡單的說BusyBox就好像是個大工具箱,它整合壓縮了 Linux
Time of Update: 2018-12-04
文章目錄 一、使用SuperOneClick等軟體進行ROOT破解二、應用程式擷取ROOT許可權代碼三、補充
Time of Update: 2018-12-04
原文地址::http://blog.csdn.net/andy_android/article/details/7301814 一、Android Service介紹Android的Service分為兩種:Android Service和Native Service。Android Service:又稱為Java Service,是實現在架構層(framework)裡的Server。Android Service以Java編寫。Native Service:又稱為System Service,
Time of Update: 2018-12-04
原文地址::http://leo108.com/pid-597.asp 本程式能夠實現在android中利用system函數執行命令,並將執行結果輸出到指定的檔案中。 核心代碼: hello-jni.c複製代碼#include <jni.h> #include <string.h> JNIEXPORT jstring Java_com_example_hellojni_HelloJni_system(JNIEnv* env,jobject thiz, jstring
Time of Update: 2018-12-04
/** * 獲得屬於案頭的應用的應用程式套件名稱 * @return 返回包含所有包名的字串列表 */ private List<String> getHomes() { List<String> names = new ArrayList<String>(); PackageManager packageManager = this.getPackageManager();
Time of Update: 2018-12-04
public boolean isAction(final Context context) { ActivityManager am = (ActivityManager)context.getSystemService(Context.ACTIVITY_SERVICE); List<RunningTaskInfo> tasks = am.getRunningTasks(1); if (!tasks.isEmpty()) {
Time of Update: 2018-12-04
原文地址::http://120.132.134.205/cmdn/supesite/?uid-5358-action-viewspace-itemid-6527 GLSurfaceView是一個視圖,繼承至SurfaceView,它內嵌的surface專門負責OpenGL渲染。 GLSurfaceView提供了下列特性: 1> 管理一個surface,這個surface就是一塊特殊的記憶體,能直接排版到android的視圖view上。
Time of Update: 2018-12-04
原文地址::http://xmchang.bokee.com/6922990.html Android 文字繪製到Bitmap上 OpenGL ES中似乎不能輸出文本.將文本寫到Bitmap上,再作為貼圖,則可實現文字輸出. 文字繪製到Bitmap上的方法為: String mstrTitle = "文字渲染到Bitmap!"; Bitmap bmp = Bitmap.createBitmap(256,256, Bitmap.Config.ARGB_8888);
Time of Update: 2018-12-04
原文地址::http://wiki.impjq.net/doku.php?id=android:android-jni:android-ndk-stacktrace-analyzer 找到兩種方法一種是使用google 的stack工具,一種是使用Analyze android-ndk stack trace. 參考:
Time of Update: 2018-12-04
一.@代表引用資源1.引用自訂資源。格式:@[package:]type/nameandroid:text="@string/hello" 2.引用系統資源。格式:@android:type/name android:textColor="@android:color/opaque_red" 注意:其實@android:type/name 是@[package:]type/name 的一個子類二.@*代表引用系統的非public資源。格式:@*android:type/name 系統資
Time of Update: 2018-12-04
在檔案 packages/apps/Settings/src/com/android/settings/DeviceInfoSettings.java 中setStringSummary("build_number", Build.DISPLAY);指定了設定--關於裝置--版本號碼。Build.DISPLAY即Build類中的 DISPLAY 變數,在檔案frameworks/base/core/java/android/os/Build.java 中:public static final
Time of Update: 2018-12-04
1、下載軟體jdk-6u33-linux-i586.bineclipse-jee-juno-linux-gtk.tar.gzandroid-sdk_r20.0.1-linux.tgzADT-20.0.2.zipandroid-ndk-r8b-linux-x86.tar.bz22、在root目錄下面建立一個單獨的檔案夾dev,將以上軟體都解壓到該檔案夾3、配置環境變數修改/etc/profile檔案,加入以下內容:export
Time of Update: 2018-12-04
SDK升級到1.5以後,當文本輸入框(EditText及其子類)獲得焦點後,會彈出系統內建的軟鍵盤 為了實現一些自訂的功能,就稍微研究了下 * 當layout中有多個EditText,把每個控制項的android:singleLine的屬性都被設定成true的情況下,軟鍵盤的Enter鍵上的文字會變成“Next”,按下後下個EditText會自動獲得焦點(實現了“Next”的功能);當最後一個控制項獲得焦點的時候,Enter鍵上的文字會變成“Done”,按下後軟鍵盤會自動隱藏起來*
Time of Update: 2018-12-04
1、Drawable --> Bitmap Bitmap drawable2Bitmap(Drawable drawable) { if (drawable instanceof BitmapDrawable) { return ((BitmapDrawable) drawable).getBitmap(); } else if (drawable instanceof NinePatchDrawable) {
Time of Update: 2018-12-04
通過ubuntu等Linux系統都是通過resolve.conf檔案進行網域名稱解析的,通過man resolve.conf可以查看到: The resolver is a set of routines in the C library that provide access to the Internet Domain Name System (DNS). The resolver configuration file contains information that
Time of Update: 2018-12-04
把要替換的圖片放置到launcher2/res/drawable-nodpi目錄,在launcher2/res/layout/apps_customize_pane.xml檔案中,修改android:background="@drawable/xxx",xxx為要替換的圖片。注意要修改兩個地方:<com.android.launcher2.AppsCustomizeTabHost
Time of Update: 2018-12-04
環境:Ubuntu 12.04 LTS 32-bit命令:1、安裝依賴庫:apt-get install git-core gnupg flex bison gperf build-essential \ zip curl zlib1g-dev libc6-dev libncurses5-dev x11proto-core-dev \ libx11-dev libreadline6-dev libgl1-mesa-dev tofrodos python-markdown \
Time of Update: 2018-12-04
android4.0 休眠喚醒會出現之前介面,我們通過案頭遠程工具可以看到在休眠時候,系統已經進入解鎖介面。可是我們喚醒機器的時候,系統會閃一下之前操作的介面,再進入解鎖介面。所以判斷應該是休眠時候沒有把解鎖介面寫入framebuffer,找到寫framebuffer地方:if (LIKELY(hw.canDraw())) { // repaint the framebuffer (if needed) const int index =
Time of Update: 2018-12-04
問題:到底基於哪個版本開發好?問題來源:由於android市場的開發性,android現階段的環境比較混亂。而市面上的使用者持有手機的android系統版本低到1.6高到4.2都有不同程度的分布,這是這種混亂性體現之一。為了讓程式能夠支援更多的一使用者才產生了這樣的問題。問題分析:要解決這個問題就要考慮開發時對不同Android版本之間的相容性與適配的方式和方法。Android各個版本的不同也就是api的發生了一些改變,具體的api變動我將用表格來呈現,並且以1.6為最基礎的版本。版本Api等級