Time of Update: 2016-02-22
標籤:轉自:http://www.cnblogs.com/supercheng/archive/2012/12/05/2804166.html- (BOOL)isJailbroken{ BOOL jailbroken = NO; NSString *cydiaPath = @"/Applications/Cydia.app"; NSString *aptPath = @"/private/var/lib/apt/"; if
Time of Update: 2016-02-22
標籤:參考博文地址:http://my.oschina.net/u/2340880/blog/485095?fromerr=bgjLq4Mw一、粒子發射器 iOS中的粒子效果有兩部分組成,一部分為發射器,設定例子發射的宏觀屬性,另一部分是粒子單元,用於設定相應的粒子屬性。粒子發射器是基於Layer層,他的全名叫做:CAEmitterLayer。其中常用的屬性如下:@property(copy) 
Time of Update: 2016-02-22
標籤: 1 import android.app.Activity; 2 import android.content.Context; 3 import android.hardware.Sensor; 4 import android.hardware.SensorEvent; 5 import android.hardware.SensorEventListener; 6 import android.hardware.SensorManager; 7 import
Time of Update: 2016-02-22
標籤:在其它網站看到的,Mark一下1、近期開啟的應用不在近期工作清單中顯示android:excludeFromRecents="true"設定為true,則排除在近期工作清單之外,不在近期工作清單中顯示2、推斷一個一個String str
Time of Update: 2016-02-22
標籤:寫在前面本文翻譯自 Android Studio Tips by Philippe Breault,一共收集了62個 Android Studio 使用小技巧和快速鍵。 根據這些小技巧的使用情境,本文將這62個小技巧分為常用技巧(1 – 28)、編碼技巧(29 – 49)和調試技巧(50 – 62),分成三個部分。每個小技巧都配有 gif 動圖,由於原圖在 google photo
Time of Update: 2016-02-22
標籤:一、簡介二、代碼1.java(1)MainActivity.java 1 import android.app.Activity; 2 import android.content.Context; 3 import android.hardware.Sensor; 4 import android.hardware.SensorEvent; 5 import android.hardware.SensorEventListener; 6 import
Time of Update: 2016-02-22
標籤:#import <UIKit/UIKit.h> @interface ELCUIApplication : UIApplication{ NSTimer *_idleTimer; NSInteger timeCount;}@end #import "ELCUIApplication.h" @implementation ELCUIApplication-
Time of Update: 2016-02-22
標籤:關於iOS中提示框的使用在iOS8的SDK裡,已經對提示框進行了更改,現在屬於 UIAlertController,其介面如下聲明NS_CLASS_AVAILABLE_IOS(8_0) @interface UIAlertController : UIViewController,不再是一個UIView。具體的使用如下,希望對部分朋友有協助。#if __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_8_0 //判斷你當前的iOS
Time of Update: 2016-02-22
標籤:1、寫入(本地) NSArray *paths=NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); NSString *path=[paths objectAtIndex:0]; NSString *Json_path=[path
Time of Update: 2016-02-22
標籤:關於iOS含有如下宏定義的 UI_APPEARANCE_SELECTOR; 的方法 ,不知道你是否知道其真正的意義。當你給你的navigationBar設定BarTintColor時,你可以使用2種方法(當然只有在iOS7以後在有BarTintColor方法)@property(nonatomic,retain) UIColor *barTintColor NS_AVAILABLE_IOS(7_0) UI_APPEARANCE_SELECTOR; //
Time of Update: 2016-02-22
標籤:可以通過設定 VC對應的 XIB 中 View 的show attrubite inspector屬性,更改其 Orientation為 Landscape,即可預設為橫屏布局。我們可以通過3種方式設定 App介面的取向。第一種:通過全域設定// The system only calls this method if the application delegate has not// implemented the delegate equivalent. It returns
Time of Update: 2016-02-22
標籤:同一類型標識符(Uniform Type Identifier,UTI)代表IOS資訊共用的中心組件。可以把它看成下一代的MIME類型。UTI是標識資源類型(比像和文本)的字串,他們制定哪些類型的資訊將用於公用資料對象,他們不需要依賴於老式的指示符,比如副檔名,MIME類型,或者檔案類型的中繼資料,顯示了Apple的基本順應樹的一部分。這個樹上位於較低位置的任何項目都必須順應其所有父資料屬性。聲明一個父UTI意味著支援他的所有子
Time of Update: 2016-02-22
標籤:一、Android系統服務 Android提供了很多系統服務:如ActivityManger,PowerManger,WindowManger,WifiManger等等。這些服務都是系統啟動開始就一直常駐的,如果app需要使用相應的系統服務(如擷取當前wifi的狀態),則需要通過Binder去訪問系統服務。例如:WifiManager mWifiManager = (WifiManager)
Time of Update: 2016-02-22
標籤:方法一:使用百度siteapp中的js進行判斷<script src="http://siteapp.baidu.com/static/webappservice/uaredirect.js" type="text/javascript"></script><script type="text/javascript">uaredirect("需要跳轉的手機網址")</script>方法二:<script
Time of Update: 2016-02-22
標籤: 1 //開始觸摸 2 - (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event 3 { 4 NSLog(@"你觸摸了螢幕"); 5 } 6 //移動 7 - (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event 8 { 9 NSLog(@"手指移動");10 }11 //觸摸結束12 -
Time of Update: 2016-02-22
標籤:最近在想ios的安全問題,有個問題久久困擾著我,ios這樣的封閉系統是引向深淵之路,還是必經之路。 iOS 是封閉的系統,它的漏洞只能指望蘋果自己的工程師來修複。iOS 的系統版本非常集中,一般都是最新發行的 2 個大版本。另外 iPhone 機型也非常少,每年固定出一款。這使得駭客可以針對單一系統或機型挖掘出來的漏洞,得到極其方便地擴散和影響。ios和Android都各自有弱點,我們能做的,就是盡量提高安全意識,盡量小心。ios就一定比Android安全嗎
Time of Update: 2016-02-22
標籤: 作為一個web前端開發人員,網站需要在手機和平板上正常顯示已成為共識,之前一直使用AdminLTE這個模板進行開發,主要使用bootstrap的柵欄模式來保證介面在手機端的正常顯示,但是要實現多樣的需求,仍需要使用到CSS的媒體查詢。以下轉載至:http://www.ibm.com/developerworks/cn/web/wa-cssqueries/簡介現今每天都有更多的手機和平板電腦問市。消費者能夠擁有可想象到的各種規格和形狀的裝置,但是網站開發人員卻面臨一個挑戰:如何使他們的網
Time of Update: 2016-02-22
標籤:<?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p"
Time of Update: 2016-02-22
標籤:過了年來到公司 發現很多認證 都無效了。以下是解決方案。 解決方案: 1. 下載https://developer.apple.com/certificationauthority/AppleWWDRCA.cer的認證,然後雙擊安裝。 2. 在導覽列那邊,顯示-顯示已到期的認證 3. 點擊 “登入”,並且選擇 “所有項目” ,並在搜尋欄下輸入 apple
Time of Update: 2016-02-22
標籤:1,建立資料庫:sqlite3 資料庫名.db2,顯示資料庫: .database3,建立表:create table 表名(欄位名1 欄位類型,欄位名2 欄位類型,...);4,插入資料:insert into 表名(欄位1,欄位2..) values(欄位1的值,欄位2的值...);5,尋找: 1)select *from表名 --顯示所有表名的內容 2)select*from表名 where查詢條件 3)select 欄位名1,欄位名3 from 表名6,更新 update