Time of Update: 2017-05-04
android OrmLite,androidormlite最近在使用ormlite架構進行資料庫的操作,下面簡單的寫個demo來學習下1.下載jar包這裡使用的是ormlite-core-5.0.jar 和 ormlite-android-5.0.jar將下載的jar包放到我們項目的libs檔案夾下2.建立實體類對象每一個實體類對應一張表,在我們項目中的bean目錄下建立一個Student類package com.item.jiejie.lite.db;import
Time of Update: 2017-05-04
談談App的混合開發,App混合開發一、概念App混合開發,顧名思義,是一個開發模式,指的是開發一個App一部分功能用native構建一部分功能用html5構建,英文名叫:Hybrid
Time of Update: 2017-05-04
在Android Studio上測試回合,Unity發布成Android包的環境搭建步驟,unityandroid 我用的是unity5.4.3版本,jdk是1.8.0_131版本,Android-SDK是r24.4.1版本,Android-NDK是r13b版本,作者是剛開始寫部落格,希望對在unity摸索的人有協助。以下是環境搭建步驟1下載安裝Java的JDK:
Time of Update: 2017-05-03
Android開發筆記(3)——GridLayout,androidgridlayout GirdLayout 計算機執行個體及詳盡的筆記:http://www.cnblogs.com/skywang12345/p/3154150.html 網格布局:使容器中的各組件呈M行×N列的網格狀分布。和Relative Layout\Linear
Time of Update: 2017-05-05
技術貼匯總,技術匯總打包idea匯出可執行jar包http://blog.csdn.net/aotian16/article/details/52198378aapt的常用命令http://blog.csdn.net/androidzhaoxiaogang/article/details/8246713 源碼分析Android
Time of Update: 2017-05-04
PendingIntent 顯示通知,pendingintent通知安卓顯示通知PendingIntent pendingIntent=PendingIntent.getActivity(Media.this,0, new Intent(Media.this,Media.class),0); NotificationManager manager= (NotificationManager)
Time of Update: 2017-05-03
快遞物流資訊布局,快遞物流資訊思路:就一個ListView,每個item就是一條物流資訊。然後每個item,分為左和右兩邊,左邊是一個進度條的風格,右邊是物流文字,適配器裡面判斷item,position為0 就設定為綠色,其他position就設定為灰色就行了。<?xml version="1.0" encoding="utf-8"?><LinearLayout
Time of Update: 2017-05-04
Android開發筆記(4)——MainActivity.java檔案修改&布局嵌套,androidmainactivity筆記連結:http://www.cnblogs.com/igoslly/p/6805020.html 筆記以開發名為CoffeeOrder的app活動為線索,介紹app如何從功能設計→布局設定→代碼編寫→改進,介紹java檔案修改和布局嵌套。 一、應用知識
Time of Update: 2017-05-03
Cheatsheet: 2017 04.01 ~ 04.30,cheatsheet04.30Other ReactXP - A LIBRARY FOR BUILDING CROSS-PLATFORM APPS Merging vs. Rebasing Better Git configuration Stack Overflow's Annual Developer Survey 68 Resources for Creating Programming
Time of Update: 2017-05-03
Webview記憶體流失解決辦法1,webview泄漏最近在activity嵌套webview顯示大量圖文發現APP記憶體一直在漲,沒法釋放記憶體,查了很多資料,大概是webview的一個BUG,引用了activity導致記憶體流失,所以就嘗試傳遞getApplicationContext。1.避免在xml直接寫webview控制項,這樣會引用activity,所以在xml寫一個LinearLayout,然後 linearLayout.addView(new
Time of Update: 2017-05-05
AndroidStudio下使用 RecyclerView xml檔案不顯示預覽條目並報錯類似:NoClassDefFoundError 問題解決,studiorecyclerview在項目中使用RecyclerView是很普遍的,最近工作中遇到了這種情況:RecyclerView可以正常使用 不會報錯
Time of Update: 2017-05-06
onSaveInstanceState和onRestoreInstanceState觸發的時機,onsaveinstancestate先看Application Fundamentals上的一段話: Android calls onSaveInstanceState() before the activity becomes vulnerable to being destroyed by the system, but does not bother calling
Time of Update: 2017-05-03
手動擷取判斷處理許可權,擷取判斷許可權主要用到的幾個方法://檢查許可權int checkSelfPermission(String)//申請許可權void requestPermissions(int, String...)//是否應該顯示請求許可權的說明boolean shouldShowRequestPermissionRationale(String)//處理許可權結果回調void
Time of Update: 2017-05-05
利用GridView實現單選效果,gridview實現單選1.實現的單選效果由於Android提供的選項按鈕radiobutton只能單行或單列顯示,且樣式並不美觀,故可用GridView進行改造,實現單選效果,而要實現這樣的效果重點就在GridView的適配器這塊了。首先是GridView的item的XML:<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
Time of Update: 2017-05-02
Android開發筆記(2)——ViewGroup,androidviewgroup一、ViewGroup 1、ViewGroup的意義——整合Layout多個不同View,並對其進行位置排列 2、ViewGroup種類Linear Layout 簡單直接的布局格式,只允許水平放置 / 垂直放置Relative Layout 複雜生動的布局格式,可根據父 / 子View相對位置來設定 二、LayoutAnroid
Time of Update: 2017-05-03
策略模式,java策略模式public class TravelStrategy { enum Strategy{ WALK,PLANE,SUBWAY } private Strategy strategy; public TravelStrategy(Strategy strategy){ this.strategy=strategy; } public void
Time of Update: 2017-05-01
聲明和使用許可權,聲明使用許可權AndroidManifest.xml<?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.scott.phone"
Time of Update: 2017-05-02
android 4.2 系統以後的飛航模式,android4.2Android 4.2 之後 系統不予許第三方軟體去設定飛航模式,除非你的app是系統應用,得到了root許可權//擷取當前的飛航模式狀態 需要根據不同的Android版本進行修改@SuppressWarnings("deprecation")public boolean isAirplaneModeOn() { //4.2以下 &
Time of Update: 2017-05-01
改變RadioButton的文字位置以及距離,radiobutton文字 在預設情況下,RadioButton的 文字位置和文字的距離是不變的,為了可以改變它,我們可以用以下的方法。1.改變文字的位置 android:button="@null" //取消預設的圖案android:drawableRight="@android:drawable/btn_radio" //自己選擇圖案,這裡表示文字在圖案的右邊,其他位置類推1.改變文字的距離and
Time of Update: 2017-05-01
在Android上Kotlin的單元測試(KAD22),kotlinkad22作者:Antonio Leiva時間:Apr 25,